我有两个系统。 一个充当主/主动并且具有因特网连接并从NTP服务器获得时间。 第二个系统是次要的/被动的,与外部世界没有任何联系。
主用和备用连接在专用networking接口eth1 。 小学有
中学有
主要有以下ntp.confconfiguration
driftfile /var/lib/ntp/ntp.drift 统计信息loopstats peerstats clockstats filegen loopstats文件loopstatstypes日启用 filegen peerstats文件peerstats键入day enable filegen clockstats文件clockstats键入date启用 服务器192.168.101.25 限制-4默认值kod notrap nomodify nopeer noquery 限制-6默认值kod notrap nomodify nopeer noquery 限制127.0.0.1 restrict :: 1 限制169.254.10.0掩码255.255.255.248 广播169.254.10.15 禁用身份validation broadcastclient
我只用ntpdate在Secondary上同步时间,不要在Secondary上运行ntpd守护进程。 在第二台上运行ntpdate -b -t 4 -p 4 -u 169.254.10.10 (主接口IP)并且Ntpd服务器在上述configuration的Primary上运行。
Secondary上的时间没有更新,并且抛出错误ntpdate[3636]: no server suitable for synchronization found
谢谢
ntpdate不读取ntp.conf文件。
要一次性同步,请在命令行上传递服务器的IP地址:
ntpdate 169.254.10.10