当用ntpdate -d 来查询时会发现导致 no server suitable for synchronization found 的错误的信息有以下2个:

错误1.Server dropped: Strata too high

在ntp客户端运行ntpdate serverIP,出现no server suitable for synchronization found的错误。

在ntp客户端用ntpdate –d serverIP查看,发现有“Server dropped: strata too high”的错误,并且显示“stratum 16”。而正常情况下stratum这个值得范围是“0~15”。

这是因为NTP server还没有和其自身或者它的server同步上。

以下的定义是让NTP Server和其自身保持同步,如果在/ntp.conf中定义的server都不可用时,将使用local时间作为ntp服务提供给ntp客户端。

127.127.1.0
fudge 127.127.1.0 stratum 8 

在ntp server上重新启动ntp服务后,ntp server自身或者与其server的同步的需要一个时间段,这个过程可能是5分钟,在这个时间之内在客户端运行ntpdate命令时会产生no server suitable for synchronization found的错误。

那么如何知道何时ntp server完成了和自身同步的过程呢?

在ntp server上使用命令:

# watch ntpq -p

出现画面:

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的这个就是与自身同步的ntp server。

注意reach这个值,在启动ntp server服务后,这个值就从0开始不断增加,当增加到17的时候,从0到17是5次的变更,每一次是poll的值的秒数,是64秒*5=320秒的时间。

如果之后从ntp客户端同步ntp server还失败的话,用ntpdate –d来查询详细错误信息,再做判断。

错误2.Server dropped: no data

从客户端执行netdate –d时有错误信息如下:

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

出现这个问题的原因可能有2:

1。检查ntp的版本,如果你使用的是ntp4.2(包括4.2)之后的版本,在restrict的定义中使用了notrust的话,会导致以上错误。

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

# ntpq -c version

下面是来自ntp官方网站的说明:
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的防火墙。可能是server的防火墙屏蔽了upd 123端口。

可以用命令

#service iptables stop

来关掉iptables服务后再尝试从ntp客户端的同步,如果成功,证明是防火墙的问题,需要更改iptables的设置。

解决ntp的错误 no server suitable for synchronization found的更多相关文章

  1. NTP-ntpdate:no server suitable for synchronization found

    NTP-ntpdate 问题处理 解决ntp的错误 no server suitable for synchronization found 当用ntpdate -d 来查询时会发现导致 no ser ...

  2. 解决虚拟机中使用ntpdate报错:ntpdate[46700]: no server suitable for synchronization found

    在使用ntpdate同步时间时出现上述错误: ntpdate[46700]: no server suitable for synchronization found 没有找到好的解决方案,只能换另外 ...

  3. CentOS 6.9:ntpdate[3115]: no server suitable for synchronization found

    在做一个集群实验,克隆的虚拟机,然后使用ntpdate就抛出了错误.机器之间可以互相ping通,selinux和iptables都已经关闭. [root@Server_2 ~]# service nt ...

  4. ntpdate:no server suitable for synchronization found

    Question: 在使用ntpdate同步时间时,出现了no server suitable for synchronization found的报错. 通过ntpdate -d s2m.time. ...

  5. 解决ntp的错误:no server can be used,exiting

    台湾地区一台机器进行时间同步时,出现下面的错误.很显然,它提示的是不能找到主机time.stdtime.gov.tw. 所以我初步猜测是由于dns解析的问题   1 2 3 4 #  /usr/sbi ...

  6. 解决Jenkins的错误“The Server rejected the connection: None of the protocols were accepted”

    1. 配置节点,配置好节点后,在节点机上运行已下载文件,双击执行,提示"The Server rejected the connection: None of the protocols w ...

  7. 虚拟机时间同步14 Aug 04:09:18 ntpdate[2941]: no server suitable for synchronization found

    因为虚拟机经常挂起,所以需要时间同步 [root@slave1 /root]$ cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime cp: over ...

  8. spring boot 连接mysql 错误The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecognized or represents more than one

    1.spring boot 整合mybatis 连接mysql时错误 The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecognized or repr ...

  9. 解决mybatis foreach 错误: Parameter '__frch_item_0' not found

    解决mybatis foreach 错误: Parameter '__frch_item_0' not found 在遍历对象的属性(是ArrayList对象)时报错: org.mybatis.spr ...

随机推荐

  1. 每天一个linux命令(26):du 命令

    Linux du命令也是查看使用空间的,但是与df命令不同的是Linux du命令是对文件和目录磁盘使用的空间的查看,还是和df命令有一些区别的. 1.命令格式: du [选项][文件] 2.命令功能 ...

  2. popupwindow与软键盘的问题

    1.软键盘弹出时不会改变布局(覆盖页面的效果)android:windowSoftInputMode="adjustPan" 2.软键盘弹出时不会覆盖popuwindowsetSo ...

  3. SSH框架整合配置所需JAR包(SSH整合)

    转载于:http://www.cnblogs.com/kaige123/p/5719662.html Hibernate Jar: 1.hibernate3.jar,这个是hibernate3.0的核 ...

  4. 【BZOJ 3674】可持久化并查集加强版&【BZOJ 3673】可持久化并查集 by zky 用可持久化线段树破之

    最后还是去掉异或顺手A了3673,,, 并查集其实就是fa数组,我们只需要维护这个fa数组,用可持久化线段树就行啦 1:判断是否属于同一集合,我加了路径压缩. 2:直接把跟的值指向root[k]的值破 ...

  5. Myeclipse-导入spring

    1.导入spring事物管理类库(spring 2.0(*) AOP) 点击项目右键->Build Path->Add librarys: 打开Add Libraries对话框,然后选定 ...

  6. Git环境的搭建及使用

    管理工具 1. Git环境的搭建 a.下载Git installer,地址:http://git-scm.com/downloads a1.参考文档地址:http://www.open-open.co ...

  7. 【kAri OJ】621. 廖神的树

    时间限制 3000 ms 内存限制 65536 KB 题目描述 廖神和男神在植树节的时候准备玩一个奇怪的游戏,他们现在有一个被分割成n*n个格子的矩形土地,他们现在准备往这个地里种树,但这个种树游戏必 ...

  8. NOIP 2014 Day1 T3飞扬的小鸟

    题目描述:http://codevs.cn/problem/3729/ 表示各种shabi的我编和调了半天,思路大体就是一个完全背包的模型,不过会多一些额外的转移(因为题目限制高度之类的),不过值得注 ...

  9. BZOJ3229 石子合并

    Description 在一个操场上摆放着一排N堆石子.现要将石子有次序地合并成一堆.规定每次只能选相邻的2堆石子合并成新的一堆,并将新的一堆石子数记为该次合并的得分. 试设计一个算法,计算出将N堆石 ...

  10. JAVA-封装

    1.什么是封装? 顾名思义,封装就是装起来,圈起来的意思,用于类与对象中来讲,就是在一个类中把对象拥有的属性和隐藏信息(条件)进行封装,不允许外部程序直接访问,而必须要通过该类提供的方法来实现对隐藏信 ...