22.3.15. timesource
timesource kickstart 命令是可选的。使用它来设置提供时间数据的 NTP、NTS 服务器和池,以及控制系统上是否启用或禁用 NTP 服务。
- 语法
timesource [--ntp-server NTP_SERVER | --ntp-pool NTP_POOL | --ntp-disable] [--nts]- 必填选项
在使用
timesource命令时,必须指定以下选项之一:-
--ntp-server- 添加一个 NTP 服务器作为时间源.这个选项只能添加到单个命令中,以添加一个 NTP 时间源服务器。要添加多个源,每次都使用单个 --ntp-server 或 --ntp-pool 选项添加多个 timesource 命令。例如,为 Europe 时区添加多个源
timezone Europe timesource --ntp-server 0.rhel.pool.ntp.org timesource --ntp-server 1.rhel.pool.ntp.org timesource --ntp-server 2.rhel.pool.ntp.org-
--ntp-pool- 添加 NTP 服务器池作为时间源.这个选项只能添加一次,以添加单个 NTP 时间源池。重复 timesource 命令,以添加多个源。 -
--ntp-disable- 禁用已安装系统的 NTP 时间源。
-
- 可选选项
-
--ntp-disable此命令添加的服务器或池使用 NTS 协议。请注意,即使使用 --ntp-disable,也可以添加这个选项,但它无效。
-