This article contains a list of what to collect to investigate and troubleshoot issues related to the Precision Time Protocol (PTP), which would help in reducing resolution time.
Perform the following:
-
Check the lock state of the local device by using show ptp lock-status detail
.
#show ptp lock-status detail
Lock Status:
Lock State : 5 (PHASE ALIGNED)
Phase offset : 0.000000020 sec
Note: Lock State should ideally be PHASE ALIGNED.
-
Verify reachability to the primary device. Verify that the route is present.
#show ptp master detail
PTP Master Interface Details:
Interface : irb.100
Status : Master, Active
Clock Info :
Local Address: 101.1.1.1 Status: Configured, Master, Active
Remote Address: 101.1.1.2 Status: Configured, Slave, Active
Total Remote Slaves: 1
ping 101.1.1.2 source 101.1.1.1
show route 101.1.1.2
show route 101.1.1.2 extensive
show route forwarding-table destination 101.1.1.2 extensive
-
Verify PTP packet statistics and that the Transmitted and Received Count values are incrementing.
Streams 0 to 3 are reserved for local backup devices that are connected to the primary device.
#show ptp statistics detail
Oct 20 14:03:42
Local Clock Remote Clock Role Stream Received Transmitted
et-0/0/50.0 fec0:abcd:1000:c::2 Slave 0 600 774
et-0/0/51.0 fec0:abcd:1000:d::2 Slave 1 600 774
#show ptp statistics
Oct 20 14:03:54
Local Clock Remote Clock Role Stream Received Transmitted
et-0/0/50.0 fec0:abcd:1000:c::2 Slave 0 602 776 <<<<<< Incrementing
et-0/0/51.0 fec0:abcd:1000:d::2 Slave 1 602 776 <<<<<< Incrementing
-
Configure a dynamic firewall filter on the local egress interface and match the PTP packets.
General Firewall Filter to Verify all PTP Packets
# set firewall family inet filter ptp-to-GM interface-specific
# set firewall family inet filter ptp-to-GM term 1 from destination-prefix-list ptp-GM
# set firewall family inet filter ptp-to-GM term 1 from next-header udp
# set firewall family inet filter ptp-to-GM term 1 from source-port 319
# set firewall family inet filter ptp-to-GM term 1 from source-port 320
# set firewall family inet filter ptp-to-GM term 1 then count ptp-in
# set firewall family inet filter ptp-to-GM term 1 then accept
# set firewall family inet filter ptp-to-GM term others then count others
# set policy-options prefix-list ptp-GM <GM address 1>
# set policy-options prefix-list ptp-GM <GM address 2>
# set interfaces <> unit 0 family inet filter input ptp-to-GM
Check the counter for show firewall filter ptp-to-GM
.
Flexible Firewall Filter to Verify Announce Packets
#set firewall family inet filter PTP-announce term Packet-Announce from flexible-match-range match-start layer-3
#set firewall family inet filter PTP-announce term Packet-Announce from flexible-match-range byte-offset 48
#set firewall family inet filter PTP-announce term Packet-Announce from flexible-match-range bit-length 8
#set firewall family inet filter PTP-announce term Packet-Announce from flexible-match-range range 0x0b
#set firewall family inet filter PTP-announce term Packet-Announce then log
#set firewall family inet filter PTP-announce term Packet-Announce then count Announce-pkt
#set firewall family inet filter PTP-announce term Packet-Announce then accept
#set firewall family inet filter PTP-announce term others then count others
#set firewall family inet filter PTP-announce term others then accept
#set interfaces <> unit 0 family inet filter input PTP-block
Check the counter for show firewall filter Packet-block
.
Flexible Firewall Filter to Verify Sync Packets
#set firewall family inet filter PTP-syn term Packet-syn from flexible-match-range match-start layer-3
#set firewall family inet filter PTP-syn term Packet-syn from flexible-match-range byte-offset 48
#set firewall family inet filter PTP-syn term Packet-syn from flexible-match-range bit-length 8
#set firewall family inet filter PTP-syn term Packet-syn from flexible-match-range range 0x0
#set firewall family inet filter PTP-syn term Packet-syn then accept
#set firewall family inet filter PTP-syn term Packet-syn then count sync
#set firewall family inet filter PTP-syn term Packet-syn then log
#set firewall family inet filter PTP-syn term others then count others
#set firewall family inet filter PTP-syn term others then accept
#set interfaces <> unit 0 family inet filter input PTP-syn
Check the counter for show firewall filter Packet-syn
.
-
If you are still unable to isolate the issue, disable the backup interfaces, restart the clock syncd service by using the following command, enable the backup interfaces again, and then check the results.
restart clksyncd-service immediately
-
Use reboot as the last option.
If the PTP issue still persists, collect the following CLI command output and contact Support:
-
set cli timestamp
-
show ptp lock-status
-
show ptp lock-status detail
-
show ptp global-information
-
show ptp clock detail
-
show ptp clock detail
-
show ptp slave detail
-
show ptp master detail
-
show ptp port detail
-
show ptp statistics detail
-
show ptp slave interface <> detail
-
show ptp slave interface <> detail
-
show interfaces terse
-
show chassis fpc
-
show chassis fpc detail
-
show system processes extensive | no-more