配置1588 ATR透传时间同步示例
在同一个1588 ATR域内,客户端同时与两台远端时钟服务器建立客户端/服务器的关系,并向两台时钟服务器同时发起单播协商求,获取1588 ATR报文进行时间同步。一旦主时钟服务器故障,客户端将自动向备时钟服务器发起连接请求。
组网需求
如图13-1所示,IP RAN网络中,NodeB之间需要进行时间同步,但是第三方网络(如微波网络、交换机网络)不支持1588v2。这时可以配置1588 ATR,实现穿越第三方网络的时间同步。NE40E支持1588 ATR Server功能,可作为BC设备从上游同步时间,并作为ATR Server设备为下游NodeB提供时间同步服务。
Server1和Server2分别作为主备时钟服务器,Client同时向Server1和Server2发起1588 ATR三层单播协商请求,获取时间同步信息。如果Client与Server1的连接中断,Client向备用时钟服务器Server2发起三层单播协商请求,确保Client仍然能与时钟服务器进行时间同步。
操作步骤
- 配置Client的单播协商功能
路由器不支持作为Client设备,Client设备(ATN或基站)单播协商功能的配置请参考相关配置手册,在此不再赘述。
- 配置Server1和Server2的单播协商功能
配置Server1的单播协商功能
<Server1> system-view
[~Server1] interface loopback 0
[*Server1-Loopback0] ip address 1.1.1.1 32
[*Server1-Loopback0] commit
[~Server1-Loopback0] quit
[*Server1] ptp-adaptive enable
[*Server1] ptp-adaptive device-type server
[*Server1] ptp-adaptive time profile
[*Server1] ptp-adaptive domain 45
[*Server1] ptp-adaptive local-ip 1.1.1.1
[*Server1] ptp-adaptive atr unicast-negotiate enable
[*Server1] interface gigabitethernet 0/1/0
[*Server1-GigabitEthernet0/1/0] ptp-adaptive atr enable
[*Server1-GigabitEthernet0/1/0] commit
[*Server1-GigabitEthernet0/1/0] quit
[*Server1] commit
配置Server2的单播协商功能
<Server2> system-view
[~Server2] interface loopback 0
[*Server2-Loopback0] ip address 2.2.2.2 32
[*Server2-Loopback0] commit
[~Server2-Loopback0] quit
[*Server2] ptp-adaptive enable
[*Server2] ptp-adaptive device-type server
[*Server2] ptp-adaptive time profile
[*Server2] ptp-adaptive domain 45
[*Server2] ptp-adaptive local-ip 2.2.2.2
[*Server2] ptp-adaptive atr unicast-negotiate enable
[*Server2] interface gigabitethernet 0/1/0
[*Server2-GigabitEthernet0/1/0] ptp-adaptive atr enable
[*Server2-GigabitEthernet0/1/0] commit
[*Server2-GigabitEthernet0/1/0] quit
[*Server2] commit
- 调整Client和Server之间的三层单播协商连接参数
调整Client和Server1之间的三层单播协商连接参数
[*Server1] ptp-adaptive dscp 60
[*Server1] commit
调整Client和Server2之间的三层单播协商连接参数
[*Server2] ptp-adaptive dscp 60
[*Server2] commit
- 检查配置效果
# 查看服务器当前1588 ATR模块的所有配置信息,此处以Server1为例说明显示信息。
<Server1> display ptp-adaptive all
Device config info ------------------------------------------------------------------------------- Ptp adaptive state :enable Device type :server Sync mode :time Current state :master Packet dscp :60 Domain value :45 Local ip :1.1.1.1 Server board :3 Profile :time VPN :none Client info ID Ip Address Clock ID Mode Announce Sync Delay_resp ------------------------------------------------------------------------------- 0 0 3.3.3.3 2cab00fffec65e58 two-way 1 -7 -7 1 1 4.4.4.4 286ed4fffebcdc76 two-way 1 -7 -7
# 查看服务器端1588 ATR功能的相关配置信息,此处以Server1为例说明显示信息。
<Server1> display ptp-adaptive config
Device config info ------------------------------------------------------------------------------- Ptp adaptive state :enable Device type :server Sync mode :time Current state :master Packet dscp :60 Domain value :45 Local ip :1.1.1.1 Server board : 3 Profile :time VPN :none Port config info Name ATR enable ----------------------------------- GigabitEthernet0/1/0 true
# 查看客户端的详细信息及与客户端的报文统计信息。
<Server1> display ptp-adaptive client 0
Client id :0 IP address :3.3.3.3 Clock id :2cab00fffec65e58 Mode :two-way Announce interval :1 Announce duration :300s Sync interval :-7 Sync duration :300s Delay_resp interval :-7 Delay_resp duration :300s Receive packet statistics --------------------------------------------------------------------------- Signalling :60 Delay_req :655778 Send packet statistics --------------------------------------------------------------------------- Signalling :60 Announce :2547 Sync :655945 Delay_resp :655778 Discard packet statistics --------------------------------------------------------------------------- Signalling :0 Delay_req :0
配置文件
Server1的配置文件。
#
sysname Server1
# ptp-adaptive enable ptp-adaptive device-type server ptp-adaptive time profile ptp-adaptive domain 45 ptp-adaptive local-ip 1.1.1.1 ptp-adaptive atr unicast-negotiate enable ptp-adaptive dscp 60 # interface Loopback0 ip address 1.1.1.1 255.255.255.255 # interface gigabitethernet 0/1/0 ptp-adaptive atr enable
#
return
Server2的配置文件。
#
sysname Server2
# ptp-adaptive enable ptp-adaptive device-type server ptp-adaptive time profile ptp-adaptive domain 45 ptp-adaptive local-ip 2.2.2.2 ptp-adaptive atr unicast-negotiate enable ptp-adaptive dscp 60 # interface Loopback0 ip address 2.2.2.2 255.255.255.255 # interface gigabitethernet 0/1/0 ptp-adaptive atr enable
#
return