赞
踩
[switchA]clock timezone cst add 8
先设置时区
修改时间:
<52p>clock datetime 14:25:55 2024-03-04
配置NTP客户端/服务器模式
[SwitchA] ntp-service refclock-master 2
[SwitchA] undo ntp-service server disable
[swithcB]clock timezone cst add 8
先设置时区
[SwitchB] ntp-service unicast-server 10.0.0.1
[SwitchB] undo ntp-service server disable
完成上述配置后,SwitchB可以同步SwitchA的时钟。
查看SwitchB的NTP状态,可以看到时钟状态为“synchronized”,即,已经完成同步。时钟的层数为3,比SwitchA低1级。
[SwitchB] display ntp-service status
clock status: synchronized
clock stratum: 3
reference clock ID: 10.0.0.1
nominal frequency: 64.0029 Hz
actual frequency: 64.0029 Hz
clock precision: 2^7
clock offset: 0.0000 ms
root delay: 62.50 ms
root dispersion: 0.20 ms
peer dispersion: 7.81 ms
reference time: 06:52:33.465 UTC Mar 7 2006(C7B7AC31.773E89A8)
synchronization state: clock set
配置NTP对等体模式( 这种方法也可以)
[switchC]clock timezone cst add 8
先设置时区
[SwitchC] ntp-service unicast-peer 10.0.0.2
[SwitchC] undo ntp-service server disable
由于SwitchC没有配置主时钟,并且其时钟层数低于SwitchB,所以SwitchC向SwitchB同步。
[SwitchC] display ntp-service status
clock status: synchronized
clock stratum: 4
reference clock ID: 10.0.0.2
nominal frequency: 64.0029 Hz
actual frequency: 64.0029 Hz
clock precision: 2^7
clock offset: 0.0000 ms
root delay: 124.98 ms
root dispersion: 0.15 ms
peer dispersion: 10.96 ms
reference time: 06:55:50.784 UTC Mar 7 2006(C7B7ACF6.C8D002E2)
synchronization state: clock set but frequency not determined
dis ntp-service session
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。