Linux操作系統上的ntpdate調整

 

通常情況下linux服務執行

 

 

 


 

  1. #ntpdate -u 210.72.145.44 

 


 
 

 

就可以進行時間同步,但突然發現服務器上的時間竟然不準確了,執行ntpdate -u 210.72.145.44命令提示如下信息:

 

  1. [leslie@standby ~]# ntpdate 210.72.145.44 

 

 


 

7 Jul 10:10:37 ntpdate[26186]: no server suitable for synchronization found

 

210.72.145.44是中國國家授時中心的官方服務器,不應該出問題的。

 

停到iptables還是不能進行同步。

man ntpdate看到如下的參數說明:
 
      -u      Direct  ntpdate  to  use  an  unprivileged port for outgoing packets. This is most useful when behind a firewall that blocks incoming traffic to privileged ports, and  you  want  to  synchronize  with  hosts 

beyond the firewall. Note that the -d option always uses unprivileged ports.

 

執行

 

  1. [leslie@standby ~]# ntpdate -u 210.72.145.44 

 

 


 

7 Jul 10:14:33 ntpdate[26462]: adjust time server 210.72.145.44 offset -0.001948 sec

 

時間同步成功。

 

不確定路由器上是否關閉了udp123端口就加上-u參數吧。

 

 

附加一下網絡上查詢到的其他的時鐘服務器

(美國
time.nist.gov 

(
復旦)(國內用戶推薦) 

ntp.fudan.edu.cn 

微軟公司授時主機(美國

time.windows.com 

臺警大授時中心(臺灣

asia.pool.ntp.org 

網通授時中心(北京

219.158.14.130 

time.twc.weather.com 

swisstime.ethz.ch 

ntp0.fau.de 

ntp3.fau.de 

time-a.nist.gov 

time-b.nist.gov 

time-nw.nist.gov 

nist1-sj.glassey.com 

NTP
服務器(上海


ntp.api.bz

 

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章