s5700-si系统时区不同于UTC时区导致NTP同步失败

发布时间:  2015-02-03 浏览次数:  305 下载次数:  0
问题描述

设备:S5700-SI

版本:V200R003COOSPC300

组网:S5700----S7706----FW-----时钟服务器

配置脚本:

#
ntp-service unicast-server 10.0.0.17
#

故障现象:S5700与FW通过NTP进行时钟同步,时钟同步配置完成后查看时间年/月/日同步成功,但是时/分/秒为同步成功;

 <nmdj_10F02>dis clock
2015-02-03 04:40:25-05:13         #
时钟与北京时间慢5个多小时
Tuesday

处理过程

1、采集配置信息:ntp-service unicast-server 10.0.0.17 ,配置正确;

2、通过display clock查看当前时间

<nmdj_10F02>dis clock
2015-02-03 04:40:25-05:13         #
时钟与北京时间慢5个多小时
Tuesday
Time Zone(Indian Standard Time) : UTC-05:13  #
当前时区是印度时区,比UTC时间慢5小时13分


<nmdj_10F02>dis clock  utc  #UTC时间是较准确的北京时间
2015-02-03 09:54:09
Tuesday

3、删除印度时区: undo clock timezone 

4、再次查看时间:

<nmdj_10F02>dis clock          

2015-02-03 09:54:51    #时钟恢复为UTC时间
Tuesday
Time Zone(DefaultZoneName) : UTC

5、 为了证明NTP协议正在运行,故意修改此交换机的系统时钟比主时钟快1小时,几秒钟后,被主时钟同步

 <nmdj_10F02>dis ntp-service status  #查看NTP同步状态
 clock status: synchronized
 clock stratum: 9
 reference clock ID: 10.0.0.17
 nominal frequency: 60.0002 Hz
 actual frequency: 60.0000 Hz
 clock precision: 2^17
 clock offset: -1.2019 ms
 root delay: 16.85 ms
 root dispersion: 265.42 ms
 peer dispersion: 10.99 ms
 reference time: 09:55:27.054 UTC Feb 3 2015(D87B198F.0DDB76B3)
 synchronization state: clock synchronized
<nmdj_10F02>
<nmdj_10F02>dis ntp-service event clock-unsync
  1. Clock source   : 10.0.0.17
     Session type   : client, configured
     Unsync reason  : Clock selection failed - No selectable clock
     Unsync time    : 2015-02-02 06:07:36-05:13

  2. Clock source   : 10.0.0.17
     Session type   : client, configured
     Unsync reason  : Clock selection failed - No selectable clock
     Unsync time    : 2015-02-02 08:22:43-05:13

  3. Clock source   : 10.0.0.17
     Session type   : client, configured
     Unsync reason  : Clock selection failed - No selectable clock
     Unsync time    : 2015-02-02 10:35:31-05:13

  4. Clock source   : 10.0.0.17
     Session type   : client, configured
     Unsync reason  : Clock selection failed - No selectable clock
     Unsync time    : 2015-02-02 13:08:24-05:13

  5. Clock source   : 10.0.0.17
     Session type   : client, configured
     Unsync reason  : Clock selection failed - No selectable clock
     Unsync time    : 2015-02-02 13:17:02-05:13
                                         
  6. Clock source   : 10.0.0.17
     Session type   : client, configured
     Unsync reason  : Clock selection failed - No selectable clock
     Unsync time    : 2015-02-02 15:22:36-05:13

  7. Clock source   : 10.0.0.17
     Session type   : client, configured
     Unsync reason  : Clock selection failed - No selectable clock
     Unsync time    : 2015-02-02 17:07:23-05:13

  8. Clock source   : 10.0.0.17
     Session type   : client, configured
     Unsync reason  : Peer clock unsynchronized/unselectable
     Unsync time    : 2015-02-03 01:16:21-05:13

  9. Clock source   : 10.0.0.17
     Session type   : client, configured
     Unsync reason  : Clock selection failed - No selectable clock
     Unsync time    : 2015-02-03 02:22:42-05:13

 10. Clock source   : 10.0.0.17
     Session type   : client, configured
     Unsync reason  : Clock selection failed - No selectable clock
     Unsync time    : 2015-02-03 03:49:40-05:13
<nmdj_10F02>    
<nmdj_10F02>
<nmdj_10F02>     dis ntp-service statistics packet
 NTP IPv4 Packet Statistical Information
 ---------------------------------------
 Sent                                  : 5758
    Send failures                      : 0
 Received                              : 5758
    Processed                          : 5747
    Dropped                            : 11
       Validity test failures          : 11
          Authentication failures      : 0
       Invalid packets                 : 0
       Access denied                   : 0
       Rate-limited                    : 0
       Processing delay                : 0
       Interface disabled              : 0
       Max dynamic association reached : 0
       Server disabled                 : 0
       Others                          : 0

6、故障解决

根因
由于设备当前系统时区是印度时区不与UTC时区同步导致故障,删除系统本地时区后故障解决。
解决方案
undo clock timezone   #删除印度时区

建议与总结

对应NTP不同步的问题,建议客户通过以下命令查看设备本身的系统时区是否和UTC的时区同步;

1、display clock;

2、display clock UTC

END