Configuring Generalized Precision Time Protocol

Information About Generalized Precision Time Protocol

Generalized precision time protocol (PTP) is an IEEE 802.1AS standard that provides a mechanism to synchronize the clocks of the bridges and end-point devices in a network. Generalized PTP defines the mechanism to elect the grandmaster clock (using Best Master Clock Algorithm [BMCA]) among the time-aware bridges and the talker and listener. The grandmaster is the root of the timing hierarchy that gets established in a time-aware network and distributes time to the nodes below to enable synchronization.

Time synchronization also requires determining the link delay and switch delays in the network nodes. A generalized PTP switch is an IEEE 1588 boundary clock, which also determines the link delay using the peer-to-peer delay mechanism. The delays that are computed are included in the correction field of the PTP messages and relayed to the endpoints. The talker and listener use this generalized PTP time as a shared clock reference, which is used to relay and recover the media clock. Generalized PTP currently defines only domain 0, which is what the generalized PTP switch supports.

The peer-to-peer delay mechanism runs on Spanning Tree Protocol-blocked (STP-blocked) ports as well. No other PTP messages are sent over blocked ports.

In a PTP domain, BMCA organizes clocks and ports in an hierarchical fashion, which includes clocks and port states:

Clocks

  • Grandmaster (GM or GMC)

  • Boundary Clock (BC)

Port States

  • Master (M)

  • Slave (S)

  • Passive (P)

How to Configure Generalized Precision Time Protocol

This section describes the various configurations available for generalized PTP.

Enabling Generalized Precision Time Protocol

To enable generalized PTP on a device, perform this procedure.

Procedure

  Command or Action Purpose

Step 1

enable

Example:

Device> enable

Enables privileged EXEC mode.

Enter your password, if prompted.

Step 2

configure terminal

Example:

Device# configure terminal

Enters global configuration mode.

Step 3

[no]ptp profile dot1as

Example:

Device(config)# ptp profile dot1as

Generalized PTP is enabled globally. Use the no form of this command to disable generalized PTP globally.

Step 4

end

Example:

Device(config)# end

Returns to privileged EXEC mode.

Enabling Generalized Precision Time Protocol on an Interface

To enable generalized PTP on an interface, perform this procedure.

Procedure
  Command or Action Purpose

Step 1

enable

Example:
Device> enable

Enables privileged EXEC mode.

Enter your password, if prompted.

Step 2

configure terminal

Example:
Device# configure terminal

Enters global configuration mode.

Step 3

interface interface-id

Example:
Device(config)# interface te1/1/1

Defines the interface to be configured as a trunk, and enters interface configuration mode. The interface that you specify can be a part of an EtherChannel.

Step 4

ptp enable

Example:
Device(config-if)# ptp enable

Enables generalized PTP on all the interfaces.

To disable generalized PTP on a port, use the no form of this command:
Device(config-if)# no ptp enable

Step 5

end

Example:
Device(config-if)# end

Returns to privileged EXEC mode.

Configuring the Values of Precision Time Protocol Clocks

Follow these steps to configure the values of PTP clocks, priority1 and priority2:

Procedure

  Command or Action Purpose

Step 1

enable

Example:

Device> enable

Enables privileged EXEC mode.

Enter your password, if prompted.

Step 2

configure terminal

Example:

Device# configure terminal

Enters global configuration mode.

Step 3

ptp priority1 value

Example:

Device(config)# ptp priority1 120

Sets the value of PTP clock priority1. The range is from 0 to 255. The default value is 128.

Note

 

If the value of priority1 is configured as 255, the clock cannot be considered as grandmaster.

Step 4

ptp priority2 value

Example:

Device(config)# ptp priority2 120

Sets the value of PTP clock priority2. The range is from 0 to 255. The default value is 128.

Step 5

exit

Example:

Device(config)# exit

Returns to global configuration mode.

Monitoring Generalized Precision Time Protocol

Use the following commands in privileged EXEC mode to monitor generalized PTP.

Table 1. Commands to Monitor Generalized Precision Time Protocol

Command

Purpose

show ptp brief

Displays the brief status of PTP on all interfaces.

show ptp clock

Displays PTP clock information.

show ptp parent

Displays the parent clock information.

show ptp port

Displays the PTP port information.

show platform software fed switch active ptp if-id {interface-id}

Displays details about the PTP status on a port.

Example: Verifying Generalized Precision Time Protocol

The following is a sample output of the show ptp brief command:

Device# show ptp brief 
Interface                       Domain    PTP State
FortyGigabitEthernet1/1/1       0         FAULTY          
FortyGigabitEthernet1/1/2       0         SLAVE           
GigabitEthernet1/1/1            0         FAULTY          
GigabitEthernet1/1/2            0         FAULTY          
GigabitEthernet1/1/3            0         FAULTY          
GigabitEthernet1/1/4            0         FAULTY          
TenGigabitEthernet1/0/1         0         FAULTY          
TenGigabitEthernet1/0/2         0         FAULTY          
TenGigabitEthernet1/0/3         0         MASTER          
TenGigabitEthernet1/0/4         0         FAULTY          
TenGigabitEthernet1/0/5         0         FAULTY          
TenGigabitEthernet1/0/6         0         FAULTY          
TenGigabitEthernet1/0/7         0         MASTER          
TenGigabitEthernet1/0/8         0         FAULTY          
TenGigabitEthernet1/0/9         0         FAULTY          
TenGigabitEthernet1/0/10        0         FAULTY          
TenGigabitEthernet1/0/11        0         MASTER          
TenGigabitEthernet1/0/12        0         FAULTY          
TenGigabitEthernet1/0/13        0         FAULTY          
TenGigabitEthernet1/0/14        0         FAULTY          
TenGigabitEthernet1/0/15        0         FAULTY          
TenGigabitEthernet1/0/16        0         FAULTY          
TenGigabitEthernet1/0/17        0         FAULTY          
TenGigabitEthernet1/0/18        0         FAULTY          
TenGigabitEthernet1/0/19        0         MASTER          
TenGigabitEthernet1/0/20        0         FAULTY          
TenGigabitEthernet1/0/21        0         FAULTY          
TenGigabitEthernet1/0/22        0         FAULTY          
TenGigabitEthernet1/0/23        0         FAULTY          
TenGigabitEthernet1/0/24        0         FAULTY          
TenGigabitEthernet1/1/1         0         FAULTY          
TenGigabitEthernet1/1/2         0         FAULTY          
TenGigabitEthernet1/1/3         0         FAULTY          
TenGigabitEthernet1/1/4         0         FAULTY          
TenGigabitEthernet1/1/5         0         FAULTY          
TenGigabitEthernet1/1/6         0         FAULTY          
TenGigabitEthernet1/1/7         0         FAULTY          
TenGigabitEthernet1/1/8         0         FAULTY

The following is a sample output of the show ptp clock command:

Device# show ptp clock 
 PTP CLOCK INFO
  PTP Device Type: Boundary clock
  PTP Device Profile: IEEE 802/1AS Profile
  Clock Identity: 0x4:6C:9D:FF:FE:4F:95:0
  Clock Domain: 0
  Number of PTP ports: 38
  PTP Packet priority: 4
  Priority1: 128
  Priority2: 128
  Clock Quality:
        Class: 248
        Accuracy: Unknown
        Offset (log variance): 16640
  Offset From Master(ns): 0
  Mean Path Delay(ns): 0
  Steps Removed: 3
  Local clock time: 00:12:13 UTC Jan 1 1970

The following is a sample output of the show ptp parent command:

Device# show ptp parent 
 PTP PARENT PROPERTIES
  Parent Clock:
  Parent Clock Identity: 0xB0:7D:47:FF:FE:9E:B6:80
  Parent Port Number: 3
  Observed Parent Offset (log variance): 16640
  Observed Parent Clock Phase Change Rate: N/A

  Grandmaster Clock:
  Grandmaster Clock Identity: 0x4:6C:9D:FF:FE:67:3A:80
  Grandmaster Clock Quality:
        Class: 248
        Accuracy: Unknown
        Offset (log variance): 16640
        Priority1: 0
        Priority2: 128

The following is a sample output of the show ptp port command:

Device# show ptp port 
PTP PORT DATASET: FortyGigabitEthernet1/1/1
  Port identity: clock identity: 0x4:6C:9D:FF:FE:4E:3A:80
  Port identity: port number: 1
  PTP version: 2
  Port state: FAULTY
  Delay request interval(log mean): 5
  Announce receipt time out: 3
  Peer mean path delay(ns): 0
  Announce interval(log mean): 1
  Sync interval(log mean): 0
  Delay Mechanism: End to End
  Peer delay request interval(log mean): 0
  Sync fault limit: 500000000

 PTP PORT DATASET: FortyGigabitEthernet1/1/2
  Port identity: clock identity: 0x4:6C:9D:FF:FE:4E:3A:80
  Port identity: port number: 2
  PTP version: 2
  Port state: FAULTY
  Delay request interval(log mean): 5
  Announce receipt time out: 3
  Peer mean path delay(ns): 0
  Announce interval(log mean): 1
 --More—

The following is a sample output of the show ptp port command for an interface:

Device# show ptp port gi1/0/26 
PTP PORT DATASET: GigabitEthernet1/0/26
  Port identity: clock identity: 0x4:6C:9D:FF:FE:4E:3A:80
  Port identity: port number: 28
  PTP version: 2
  Port state: MASTER
  Delay request interval(log mean): 5
  Announce receipt time out: 3
  Peer mean path delay(ns): 0
  Announce interval(log mean): 1
  Sync interval(log mean): 0
  Delay Mechanism: Peer to Peer
  Peer delay request interval(log mean): 0
  Sync fault limit: 500000000

The following is a sample output of the show platform software fed switch active ptp if-id command for an interface:

Device# show platform software fed switch active ptp if-id 0x20 
Displaying port data for if_id 20
=======================================

Port Mac Address 04:6C:9D:4E:3A:9A
Port Clock Identity 04:6C:9D:FF:FE:4E:3A:80
Port number 28
PTP Version 2
domain_value 0
dot1as capable: FALSE
sync_recpt_timeout_time_interval 375000000 nanoseconds
sync_interval 125000000 nanoseconds
neighbor_rate_ratio 0.000000
neighbor_prop_delay 0 nanoseconds
compute_neighbor_rate_ratio: TRUE
compute_neighbor_prop_delay: TRUE
port_enabled: TRUE
ptt_port_enabled: TRUE
current_log_pdelay_req_interval 0
pdelay_req_interval 0 nanoseconds
allowed_lost_responses 3
neighbor_prop_delay_threshold 2000 nanoseconds
is_measuring_delay : FALSE
Port state: : MASTER
sync_seq_num 22023
delay_req_seq_num 23857
num sync messages transmitted  0
num sync messages received  0
num followup messages transmitted  0
num followup messages received  0
num pdelay requests transmitted  285695
num pdelay requests received  0
num pdelay responses transmitted  0
num pdelay responses received 0
num pdelay followup responses transmitted  0
num pdelay followup responses received  0

Feature History for Generalized Precision Time Protocol

This table provides release and related information for the features explained in this module.

These features are available in all the releases subsequent to the one they were introduced in, unless noted otherwise.

Release

Feature

Feature Information

Cisco IOS XE Fuji 16.8.1a

Generalized Precision Time Protocol

Generalized Precision Time Protocol (PTP) is an IEEE 802.1AS standard that provides a mechanism to synchronize the clocks of the bridges and end-point devices in a network.

Cisco IOS XE Amsterdam 17.2.1

IEEE802.1AS (gPTP) support on EtherChannel Interfaces

From this release the interface on which you configure generalized PTP can be part of an EtherChannel.

Cisco IOS XE Bengaluru 17.5.1

Generalized Precision Time Protocol over Layer 3 Unicast

Generalized PTP over Layer 3 Unicast feature allows message-based synchronization across non-PTP-enabled devices and with unicast PTP configured on Layer 3 devices.

Use the Cisco Feature Navigator to find information about platform and software image support. To access Cisco Feature Navigator, go to http://www.cisco.com/go/cfn.