主頁(yè) > 知識(shí)庫(kù) > 完美解決ntp的錯(cuò)誤問(wèn)題no server suitable for synchronization fo

完美解決ntp的錯(cuò)誤問(wèn)題no server suitable for synchronization fo

熱門(mén)標(biāo)簽:怎么用百度地圖標(biāo)注坐標(biāo) 上海機(jī)器人外呼系統(tǒng)哪家好 地圖標(biāo)注人員分布 400的電話(huà)一般從哪里辦理 益陽(yáng)400電話(huà)申請(qǐng)辦理流程 昆明電銷(xiāo)機(jī)器人價(jià)格 春運(yùn)地圖標(biāo)注app 梧州防封電銷(xiāo)卡 江西全自動(dòng)外呼系統(tǒng)報(bào)價(jià)

當(dāng)用ntpdate -d 來(lái)查詢(xún)時(shí)會(huì)發(fā)現(xiàn)導(dǎo)致 no server suitable for synchronization found 的錯(cuò)誤的信息有以下2個(gè): 

錯(cuò)誤1.Server dropped: Strata too high

在ntp客戶(hù)端運(yùn)行ntpdate serverIP,出現(xiàn)no server suitable for synchronization found的錯(cuò)誤。

在ntp客戶(hù)端用ntpdate –d serverIP查看,發(fā)現(xiàn)有“Server dropped: strata too high”的錯(cuò)誤,并且顯示“stratum 16”。而正常情況下stratum這個(gè)值得范圍是“0~15”。

這是因?yàn)镹TP server還沒(méi)有和其自身或者它的server同步上。

以下的定義是讓NTP Server和其自身保持同步,如果在/ntp.conf中定義的server都不可用時(shí),將使用local時(shí)間作為ntp服務(wù)提供給ntp客戶(hù)端。

server 127.127.1.0fudge

127.127.1.0 stratum 8 

 

在ntp server上重新啟動(dòng)ntp服務(wù)后,ntp server自身或者與其server的同步的需要一個(gè)時(shí)間段,這個(gè)過(guò)程可能是5分鐘,在這個(gè)時(shí)間之內(nèi)在客戶(hù)端運(yùn)行ntpdate命令時(shí)會(huì)產(chǎn)生no server suitable for synchronization found的錯(cuò)誤。

那么如何知道何時(shí)ntp server完成了和自身同步的過(guò)程呢?

在ntp server上使用命令:

 

# watch ntpq -p


出現(xiàn)畫(huà)面:

 

Every 2.0s: ntpq -p                                   Thu Jul 10 02:28:32 2008

     remote           refid      st t when poll reach   delay   offset jitter

=======================================================

 192.168.30.22   LOCAL(0)         8 u   22   64    1    2.113 179133.   0.001

 LOCAL(0)        LOCAL(0)        10 l   21   64    1    0.000   0.000  0.001

 

注意LOCAL的這個(gè)就是與自身同步的ntp server。

注意reach這個(gè)值,在啟動(dòng)ntp server服務(wù)后,這個(gè)值就從0開(kāi)始不斷增加,當(dāng)增加到17的時(shí)候,從0到17是5次的變更,每一次是poll的值的秒數(shù),是64秒*5=320秒的時(shí)間。

如果之后從ntp客戶(hù)端同步ntp server還失敗的話(huà),用ntpdate –d來(lái)查詢(xún)?cè)敿?xì)錯(cuò)誤信息,再做判斷。


錯(cuò)誤2.Server dropped: no data
從客戶(hù)端執(zhí)行netdate –d時(shí)有錯(cuò)誤信息如下:

transmit(192.168.30.22)

transmit(192.168.30.22)

transmit(192.168.30.22)

transmit(192.168.30.22)

transmit(192.168.30.22)

192.168.30.22: Server dropped: no data

server 192.168.30.22, port 123

.....
28 Jul 17:42:24 ntpdate[14148]: no server suitable for synchronization found

出現(xiàn)這個(gè)問(wèn)題的原因可能有2:

 

1。檢查ntp的版本,如果你使用的是ntp4.2(包括4.2)之后的版本,在restrict的定義中使用了notrust的話(huà),會(huì)導(dǎo)致以上錯(cuò)誤。

使用以下命令檢查ntp的版本:

# ntpq -c version

下面是來(lái)自ntp官方網(wǎng)站的說(shuō)明:

The behavior of notrust changed between versions 4.1 and 4.2.

In 4.1 (and earlier) notrust meant "Don't trust this host/subnet for time".

In 4.2 (and later) notrust means "Ignore all NTP packets that are not cryptographically authenticated." This forces remote time servers to authenticate themselves to your (client) ntpd

解決:

把notrust去掉。

2。檢查ntp server的防火墻??赡苁莝erver的防火墻屏蔽了upd 123端口。

可以用命令

#service iptables stop

來(lái)關(guān)掉iptables服務(wù)后再?lài)L試從ntp客戶(hù)端的同步,如果成功,證明是防火墻的問(wèn)題,需要更改iptables的設(shè)置。

以上這篇完美解決ntp的錯(cuò)誤問(wèn)題no server suitable for synchronization fo就是小編分享給大家的全部?jī)?nèi)容了,希望能給大家一個(gè)參考,也希望大家多多支持腳本之家。

標(biāo)簽:懷化 新疆 贛州 惠州 亳州 北京 河南 九江

巨人網(wǎng)絡(luò)通訊聲明:本文標(biāo)題《完美解決ntp的錯(cuò)誤問(wèn)題no server suitable for synchronization fo》,本文關(guān)鍵詞  完美,解決,ntp,的,錯(cuò)誤,問(wèn)題,;如發(fā)現(xiàn)本文內(nèi)容存在版權(quán)問(wèn)題,煩請(qǐng)?zhí)峁┫嚓P(guān)信息告之我們,我們將及時(shí)溝通與處理。本站內(nèi)容系統(tǒng)采集于網(wǎng)絡(luò),涉及言論、版權(quán)與本站無(wú)關(guān)。
  • 相關(guān)文章
  • 下面列出與本文章《完美解決ntp的錯(cuò)誤問(wèn)題no server suitable for synchronization fo》相關(guān)的同類(lèi)信息!
  • 本頁(yè)收集關(guān)于完美解決ntp的錯(cuò)誤問(wèn)題no server suitable for synchronization fo的相關(guān)信息資訊供網(wǎng)民參考!
  • 企业400电话

    智能AI客服机器人
    15000

    在线订购

    合计11份范本:公司章程+合伙协议+出资协议+合作协议+股权转让协议+增资扩股协议+股权激励+股东会决议+董事会决议

    推薦文章