Configuring PTP

This document describes the Precision Time Protocol (PTP) feature and configuration steps to implement PTP.

Prerequisites for Configuring PTP

  • NID must be added to the controller.

  • NID must be accessible from the controller.

Information About PTP

PTP, as defined in the IEEE 1588 standard, synchronizes with nanosecond accuracy the real-time clocks of the devices in a network. The clocks are organized into a master-member hierarchy. PTP identifies the switch port that is connected to a device with the most precise clock. This clock is referred to as the master clock. All the other devices on the network synchronize their clocks with the master and are referred to as members. Constantly exchanged timing messages ensure continued synchronization.

How to Provision PTP

Configuring Slave IPv4

To configure slave IPv4, unicast, one step on VLAN 7 with domain number 0, perform the following steps:

     Command or ActionPurpose
    Step 1ConfigureNID


    Example:
    UCS# Configure NID 1
     
    Opens a new session for NID 1.  
    Step 2PTPPortType


    Example:
    UCS# PTPPortType
     
    Enters the PTPPortType mode.  
    Step 3setPTPclockInstance_v3 ptpClkConfig {clk_inst_domain | clk_slave | clock_enable | clock_instance clock_instance_number |dscp | mode {boundary | e2etransparent | master | p2ptransparent | slave} | two_step_flag | one_way | protocol {disable ethernet | unicast_ipv4 | multicast_ipv4} |servo | slave-cfg | vlan {disable | vlan_id vlan_id_number} | pcp {disable | pcp_value} | enabled_ports {port1 | port2 | port3 | port4 | port5 | port6} | filter | ho | identifier | localpriority | priority1 | priority2 { profile | disable | g8265dot1 | g8275dot1 | ieee1588} | clock_domain clock_domain_number}


    Example:
    UCS(PTPPortType)# setPTPclockInstance_v3 ptp_clock_config clock_instance 1 
    UCS(PTPPortType)# setPTPclockInstance_v3 ptp_clock_config clock_domain 0 
    UCS(PTPPortType)# setPTPclockInstance_v3 ptp_clock_config clock_enable enable 
    UCS(PTPPortType)# setPTPclockInstance_v3 ptp_clock_config mode slave 
    UCS(PTPPortType)# setPTPclockInstance_v3 ptp_clock_config one_way disable 
    UCS(PTPPortType)# setPTPclockInstance_v3 ptp_clock_config protocol unicast_ipv4 
    UCS(PTPPortType)# setPTPclockInstance_v3 ptp_clock_config two_step_flag disable 
    UCS(PTPPortType)# setPTPclockInstance_v3 ptp_clock_config vlan vlan_id 7 
     
    Configures slave IPV4, unicast, one step on VLAN 7 with domain number 0.
    • clk_inst_domain—HW based or SW based Clock domain.
    • clk_slave—Set PTP slave clock options.
    • clock_enable—Enables or disables clock.
    • clock_instance— Specifies PTP clock instance.
    • clock_instance_number— Clock instance number.
    • dscp— Dscp value.
    • mode—Specifies clock mode.
    • boundary—Specifies ordinary boundary clock.
    • e2etransparent— Specifies end to end transparent clock.
    • master—Specifies master only clock.
    • p2ptransparent—Specifies peer to peer transparent clock.
    • slave— Specifies slave only clock.
    • two_step_flag—Specifies two step flag.
    • one_way—Specifies one way.
    • protocol— Specifies the protocol.
    • servo— Set servo parameters.
    • slave_cfg— Specifies Unicast Slave configuration Entry.
    • disable—Disables protocol.
    • ethernet—Specifies EPS Ethernet protocol.
    • unicast_ipv4—Specifies unicast protocol.
    • multicast_ipv4— Specifies multicast protocol.
    • vlan—Specifies the VLAN ID.
    • disable—Disables VLAN tag.
    • vlan_id— Specifies the VLAN tag.
    • vlan_id_number— VLAN tag number.
    • pcp—Specifies VLAN PCP.
    • disable—Disables VLAN PCP.
    • pcp_value—Specifies the PCP value.
    • enabled_ports—Specifies UNI ports.
    • port1— Specifies physical port 1.
    • port2—Specifies physical port 2.
    • port3—Specifies physical port 3.
    • port4— Specifies physical port 4.
    • port5—Specifies physical port 5.
    • port6—Specifies physical port 6.
    • filter—Specifies filter parameters.
    • ho— Set PTP Servo holdover parameters.
    • identifier— Defines PTP clock instance identifier.
    • localpriority— Set Local priority for the port.
    • priority1—Specifies clock priority 1 for PTP BMC algorithm, 0 is highest priority.
    • priority2—Specifies clock priority 2 for PTP BMC algorithm.
    • profile— Specifies Clock's associated profile.
    • clock_domain—Specifies PTP domain.
    • clock_domain_number—PTP domain number.
     
    Step 4setPTPclockInstance_v3 review


    Example:
    UCS(PTPPortType)# setPTPclockInstance_v3 review
     
    Displays the configuration.  
    Step 5setPTPclockInstance_v3 commit


    Example:
    UCS(PTPPortType)# setPTPclockInstance_v3 commit
     
    Sends the configuration to NID.  
    Step 6exit


    Example:
    UCS(PTPPortType)# exit
     
    Exits from the PTPPortType mode.  

    Configuration Example

    The example shows how to configure slave IPv4, unicast, one step on VLAN 7 with domain number 0:

    UCS(PTPPortType)# setPTPclockInstance_v3 ptp_clock_config clock_instance 1 
    UCS(PTPPortType)# setPTPclockInstance_v3 ptp_clock_config clock_domain 0 
    UCS(PTPPortType)# setPTPclockInstance_v3 ptp_clock_config clock_enable enable 
    UCS(PTPPortType)# setPTPclockInstance_v3 ptp_clock_config mode slave 
    UCS(PTPPortType)# setPTPclockInstance_v3 ptp_clock_config one_way disable 
    UCS(PTPPortType)# setPTPclockInstance_v3 ptp_clock_config protocol unicast_ipv4 
    UCS(PTPPortType)# setPTPclockInstance_v3 ptp_clock_config two_step_flag disable 
    UCS(PTPPortType)# setPTPclockInstance_v3 ptp_clock_config vlan vlan_id 7
    
    UCS(PTPPortType)# setPTPclockInstance_v3 review 
    UCS(PTPPortType)# setPTPclockInstance_v3 commit
    UCS(PTPPortType)# exit
    

    Enabling PTP on a Port

    To enable PTP on port 1/4 with PTP instance 1, perform the following steps:

       Command or ActionPurpose
      Step 1ConfigureNID


      Example:
      UCS# Configure NID 1
       
      Opens a new session for NID 1.  
      Step 2PTPPortType


      Example:
      UCS# PTPPortType
       
      Enters the PTPPortType mode.  
      Step 3setPTPportProperties ptp_port_conf {ptp_run | clock_inst clock_inst_number | port_id port_id_number | announce_interval {disable | value} | announce_timeout {disable | value} | delay_asymmetry {disable | value} | delay_mechanism {disable | e2e | p2p} | delay_req {disable | interval interval_value } | egress_latency {disable | value} | ingress_latency {disable | value} | internal | sync_interval {disable | value value}}


      Example:
      UCS(PTPPortType)# setPTPportProperties ptp_port_conf port_id 4
      UCS(PTPPortType)# setPTPportProperties ptp_port_conf clock_inst 1
      UCS(PTPPortType)# setPTPportProperties ptp_port_conf sync_interval value -4
      UCS(PTPPortType)# setPTPportProperties ptp_port_conf delay_req interval -6
      UCS(PTPPortType)# setPTPportProperties ptp_port_conf ptp_run enable 
       
      Enables PTP on port 1/4, instance: 1.
      • ptp_run—Enables PTP on the specified port.
      • clock_inst— Specifies the PTP clock number.
      • clock_inst_number— PTP clock number.
      • port_id—Specifies the physical port number.
      • port_id_number—Physical port number.
      • announce_interval—Specifies the time interval for sending announce messages.
      • disable— Disables announce interval.
      • value—Specifies announce interval value.
      • announce_timeout—Sets announce timeout.
      • disable— Disables announce timeout.
      • value—Specifies announce timeout value.
      • delay_asymmetry—Sets path delay asymmetry.
      • disable— Disables delay asymmetry.
      • value—Specifies delay asymmetry in nano seconds.
      • delay_mechanism—Sets delay mechanism.
      • disable— Disables delay mechanism.
      • e2e—Specifies end to end delay mechanism.
      • p2p—Specifies peer to peer delay mechanism.
      • delay_req—Sets delay request interval.
      • disable— Disables delay request mechanism.
      • interval—Specifies peer to peer delay mechanism.
      • interval_value—Peer to peer delay value.
      • egress_latency—Sets port egress latency.
      • disable— Disables delay asymmetry.
      • value— Specifies egress latency in nano seconds.
      • ingress_latency—Sets port ingress latency.
      • disable— Disables delay asymmetry.
      • value— Specifies ingress latency in nano seconds.
      • internal— Enables as an internal interface.
      • sync_interval—Sets sync interval.
      • disable— Disables sync interval.
      • value— Specifies sync interval value.
      • value—Sync interval value.
       
      Step 4setPTPportProperties review


      Example:
      UCS(PTPPortType)# setPTPportProperties review
       
      Displays the configuration.  
      Step 5setPTPportProperties commit


      Example:
      UCS(PTPPortType)# setPTPportProperties commit
       
      Sends the configuration to NID.  
      Step 6exit


      Example:
      UCS(PTPPortType)# exit
       
      Exits from the PTPPortType mode.  

      Configuration Example

      The following example shows how to enable PTP on a port.

      UCS(PTPPortType)# setPTPportProperties ptp_port_conf port_id 4
      UCS(PTPPortType)# setPTPportProperties ptp_port_conf clock_inst 1
      UCS(PTPPortType)# setPTPportProperties ptp_port_conf sync_interval value -4
      UCS(PTPPortType)# setPTPportProperties ptp_port_conf delay_req interval -6
      UCS(PTPPortType)# setPTPportProperties ptp_port_conf ptp_run enable
      
      UCS(PTPPortType)# setPTPportProperties review
      UCS(PTPPortType)# setPTPportProperties commit
      UCS(PTPPortType)# exit

      Note


      For G.8275.1 profile, there are a few additional parameters that have been added under setPTPportProperties_v2. In addition to the available parameters for setPTPportProperties, the following are the new parameters available:
      • localpriority - Sets Local priority for the port.

      • mcast_dest - Sets multicast destination address type for the port for G.8275.1 profile.

      • not_slave - Sets not_slave attribute for the port for G8275.1 BMC algorithm.


      The following example shows how to enable PTP on a port using setPTPportProperties_v2.

      UCS(PTPPortType)# setPTPportProperties_v2 ptp_port_config ptp_run enable
      UCS(PTPPortType)# setPTPportProperties_v2 ptp_port_config clock_inst 1
      UCS(PTPPortType)# setPTPportProperties_v2 ptp_port_config port_id 2
      UCS(PTPPortType)# setPTPportProperties_v2 ptp_port_config localpriority value 12
      UCS(PTPPortType)# setPTPportProperties_v2 ptp_port_config not_slave enable
      UCS(PTPPortType)# setPTPportProperties_v2 ptp_port_config mcast_dest default
      UCS(PTPPortType)# setPTPportProperties_v2 ptp_port_config sync_interval value -4
      UCS(PTPPortType)# setPTPportProperties_v2 ptp_port_config delay_req interval -6
      
      UCS(PTPPortType)# setPTPportProperties_v2 review 
      
      Commands in queue:
              setPTPportProperties_v2 ptp_port_config ptp_run enable
              setPTPportProperties_v2 ptp_port_config clock_inst 1
              setPTPportProperties_v2 ptp_port_config port_id 2
              setPTPportProperties_v2 ptp_port_config localpriority value 12
              setPTPportProperties_v2 ptp_port_config not_slave enable
              setPTPportProperties_v2 ptp_port_config mcast_dest default
      setPTPportProperties_v2 ptp_port_config sync_interval value -4
      setPTPportProperties_v2 ptp_port_config delay_req interval -6
      
      UCS(PTPPortType)# setPTPportProperties_v2 commit
      UCS(PTPPortType)# exit

      Enabling or Disabling Microsemi APR

      To enable or disable Microsemi APR, perform the following steps:

         Command or ActionPurpose
        Step 1ConfigureNID


        Example:
        UCS# Configure NID 1
         
        Opens a new session for NID 1.  
        Step 2PTPPortType


        Example:
        UCS# PTPPortType
         
        Enters the PTPPortType mode.  
        Step 3setPTPexternalProperties ptp_external_conf {clock_output_freq | one_pps_output | one_pps_input | vcxo_freq_control | algorithm {enable | one_hertz | min_phase}}


        Example:
        UCS(PTPPortType)# setPTPexternalProperties ptp_external_conf algorithm enable enable 
        UCS(PTPPortType)# setPTPexternalProperties ptp_external_conf algorithm one_hertz enable
         
        Enables Microsemi APR.
        • clock_output_freq—Specifies external clock output frequency in Hz.
        • one_pps_output— Enables 1PPS output.
        • one_pps_input— Enables 1PPS input.
        • vcxo_freq_control—Specifies APR settings.
        • enable—Enables or disables the APR.
        • one_hertz— Enables or disables 1 Hz.
        • min_phase—Specifies phase correction begin threshold.
         
        Step 4setPTPexternalProperties ptp_external_conf {clock_output_freq | one_pps_output | one_pps_input | vcxo_freq_control | algorithm {enable | one_hertz | min_phase}}


        Example:
        UCS(PTPPortType)# setPTPexternalProperties ptp_external_conf algorithm enable disable 
        
         
        Disables Microsemi APR and returns to default VTSS APR.
        • clock_output_freq—Specifies external clock output frequency in Hz.
        • one_pps_output— Enables 1PPS output.
        • one_pps_input— Enables 1PPS input.
        • vcxo_freq_control—Specifies APR settings.
        • enable—Enables or disables the APR.
        • one_hertz— Enables or disables 1 Hz.
        • min_phase—Specifies phase correction begin threshold.
         
        Step 5setPTPexternalProperties review


        Example:
        UCS(PTPPortType)# setPTPexternalProperties review
         
        Displays the configuration.  
        Step 6setPTPclockInstance commit


        Example:
        UCS(PTPPortType)# setPTPexternalProperties commit
         
        Sends the configuration to NID.  
        Step 7exit


        Example:
        UCS(PTPPortType)# exit
         
        Exits from the PTPPortType mode.  

        Configuration Example

        The following example shows how to enable Microsemi APR.

        UCS(PTPPortType)# setPTPexternalProperties ptp_external_conf algorithm enable enable
        UCS(PTPPortType)# setPTPexternalProperties ptp_external_conf algorithm one_hertz enable
        
        UCS(PTPPortType)# setPTPexternalProperties review 
        UCS(PTPPortType)# setPTPexternalProperties commit
        UCS(PTPPortType)# exit
        

        The following example shows how to disable Microsemi APR and return to default VTSS APR.

        UCS(PTPPortType)# setPTPexternalProperties ptp_external_conf algorithm enable disable
        
        UCS(PTPPortType)# setPTPexternalProperties review 
        UCS(PTPPortType)# setPTPexternalProperties commit
        UCS(PTPPortType)# exit
        

        Note


        For G.8275.1 profile, there are a few additional parameters that have been added under setPTPexternalProperties_v2. In addition to the available parameters for setPTPexternalProperties, the following are the new parameters available:
        • ho_spec - Holdover specification for G.8275 PTP clocks.

        • adjustment_method - Adjustment method.


        The following example shows how to set holdover specification and adjustment method for G.8275.1 profile.

        UCS(PTPPortType)# setPTPexternalProperties_v2 ptp_external_config ho_spec enable enable
        UCS(PTPPortType)# setPTPexternalProperties_v2 ptp_external_config ho_spec cat1_value 11
        UCS(PTPPortType)# setPTPexternalProperties_v2 ptp_external_config ho_spec cat2_value 12
        UCS(PTPPortType)# setPTPexternalProperties_v2 ptp_external_config ho_spec cat3_value 13
        UCS(PTPPortType)# setPTPexternalProperties_v2 ptp_external_config one_pps_mode one_pps_input enable
        UCS(PTPPortType)# setPTPexternalProperties_v2 ptp_external_config adjustment_method ltc_phase enable
        
        UCS(PTPPortType)# setPTPexternalProperties_v2 review
        
        Commands in queue:
                setPTPexternalProperties_v2 ptp_external_config ho_spec enable enable
                setPTPexternalProperties_v2 ptp_external_config ho_spec cat1_value 11
                setPTPexternalProperties_v2 ptp_external_config ho_spec cat2_value 12
                setPTPexternalProperties_v2 ptp_external_config ho_spec cat3_value 13
                setPTPexternalProperties_v2 ptp_external_config one_pps_mode one_pps_input enable
                setPTPexternalProperties_v2 ptp_external_config adjustment_method ltc_phase enable
        
        UCS(PTPPortType)# setPTPexternalProperties_v2 commit
        UCS(PTPPortType)# exit

        Verifying PTP

        Use the following commands to verify the PTP status on the controller:

        Switch(config-controller-PTPPortType)# showPTPall ptp_show_req 1
        Switch(config-controller-PTPPortType)# showPTPall commit
        
        
        This command displays the PTP configuration status on the NID.

        Note


        To view the values of the parameters that have been added as part of G.8275.1 profile, use the showPTPall_v2 command.


        The following is a sample output from the showPTPall command:

        ShowPTPall_Output.ptp_show_response[0].local_current_time.ptp_time = 'local time not implemented for clk_inst = 1 '
        ShowPTPall_Output.ptp_show_response[0].local_current_time.clock_adjustment_method.t = 4
        ShowPTPall_Output.ptp_show_response[0].local_current_time.clock_adjustment_method.u.software = ''
        ShowPTPall_Output.ptp_show_response[0].clock_default_dataset.clock_id = 1
        ShowPTPall_Output.ptp_show_response[0].clock_default_dataset.mode.t = 5
        ShowPTPall_Output.ptp_show_response[0].clock_default_dataset.mode.u.slave = ''
        ShowPTPall_Output.ptp_show_response[0].clock_default_dataset.two_step_flag = false
        ShowPTPall_Output.ptp_show_response[0].clock_default_dataset.ports = '255'
        ShowPTPall_Output.ptp_show_response[0].clock_default_dataset.clock_identity = '4348018d07000075'
        ShowPTPall_Output.ptp_show_response[0].clock_default_dataset.clock_quality = 'Cl:255 Ac:128 Va:00004'
        ShowPTPall_Output.ptp_show_response[0].clock_default_dataset.properties.priority1 = 0
        ShowPTPall_Output.ptp_show_response[0].clock_default_dataset.properties.priority2 = 0
        ShowPTPall_Output.ptp_show_response[0].clock_default_dataset.properties.clock_domain = 127
        ShowPTPall_Output.ptp_show_response[0].clock_default_dataset.protocol.t = 1
        ShowPTPall_Output.ptp_show_response[0].clock_default_dataset.protocol.u.ethernet = ''
        ShowPTPall_Output.ptp_show_response[0].clock_default_dataset.one_way = true
        ShowPTPall_Output.ptp_show_response[0].clock_default_dataset.vlan.t = 1
        ShowPTPall_Output.ptp_show_response[0].clock_default_dataset.vlan.u.disable = ''
        ShowPTPall_Output.ptp_show_response[0].clock_default_dataset.pcp.t = 1
        ShowPTPall_Output.ptp_show_response[0].clock_default_dataset.pcp.u.disable = ''
        ShowPTPall_Output.ptp_show_response[0].time_property.UTC_offset.t = 2
        ShowPTPall_Output.ptp_show_response[0].time_property.UTC_offset.u.value = 34
        ShowPTPall_Output.ptp_show_response[0].time_property.frequency_traceable = true
        ShowPTPall_Output.ptp_show_response[0].time_property.leap59 = true
        ShowPTPall_Output.ptp_show_response[0].time_property.leap61 = true
        ShowPTPall_Output.ptp_show_response[0].time_property.timing_traceable = true
        ShowPTPall_Output.ptp_show_response[0].time_property.ptp_timescale = true
        ShowPTPall_Output.ptp_show_response[0].time_property.ptp_timesource = 0
        ShowPTPall_Output.ptp_show_response[0].clock_parent_dataset = 'ParentPortIdentity port Pstat Var ChangeRate d0c282fffe17dfbf 1 0 65170-8207664
        
        GrandmasterIdentity GrandmasterClockQuality Pri1 Pri2fe17dfbf68fe70cd Cl:128 Ac:128 Va:33914 92 145
        '
        ShowPTPall_Output.ptp_show_response[0].clock_current_dataset.stpRm = 1
        ShowPTPall_Output.ptp_show_response[0].clock_current_dataset.offset_from_master = ' 0.000.000.003'
        ShowPTPall_Output.ptp_show_response[0].clock_current_dataset.mean_path_delay = ' 0.000.000.067'
        ShowPTPall_Output.ptp_show_response[0].clock_current_dataset.slave_port = 4
        ShowPTPall_Output.ptp_show_response[0].clock_current_dataset.slave_state.t = 4
        ShowPTPall_Output.ptp_show_response[0].clock_current_dataset.slave_state.u.LOCKED = ''
        ShowPTPall_Output.ptp_show_response[0].clock_current_dataset.holdover = 'TRUE -368.3
        '
        ShowPTPall_Output.ptp_show_response[0].slave_cfg[0].index_ = 0
        ShowPTPall_Output.ptp_show_response[0].slave_cfg[0].duration = 100
        ShowPTPall_Output.ptp_show_response[0].slave_cfg[0].peer_ip_addr = '7.7.7.7'
        ShowPTPall_Output.ptp_show_response[0].slave_cfg[1].index_ = 1
        ShowPTPall_Output.ptp_show_response[0].slave_cfg[1].duration = 100
        ShowPTPall_Output.ptp_show_response[0].slave_cfg[1].peer_ip_addr = '0.0.0.0'
        ShowPTPall_Output.ptp_show_response[0].slave_cfg[2].index_ = 2
        ShowPTPall_Output.ptp_show_response[0].slave_cfg[2].duration = 100
        ShowPTPall_Output.ptp_show_response[0].slave_cfg[2].peer_ip_addr = '0.0.0.0'
        ShowPTPall_Output.ptp_show_response[0].slave_cfg[3].index_ = 3
        ShowPTPall_Output.ptp_show_response[0].slave_cfg[3].duration = 100
        ShowPTPall_Output.ptp_show_response[0].slave_cfg[3].peer_ip_addr = '0.0.0.0'
        ShowPTPall_Output.ptp_show_response[0].slave_cfg4.index_ = 4
        ShowPTPall_Output.ptp_show_response[0].slave_cfg4.duration = 100
        ShowPTPall_Output.ptp_show_response[0].slave_cfg4.peer_ip_addr = '0.0.0.0'
        
        ShowPTPall Commit Success!!!

        Additional References

        Related Documents

        Related Topic Document Title

        Cisco ME 3800x and ME 3600x Switches Software Configuration Guide, Cisco IOS Release 15.4(1)S

        http:/​/​www.cisco.com/​c/​en/​us/​td/​docs/​switches/​metro/​me3600x_3800x/​software/​release/​15-4_1_S/​configuration/​guide/​3800x3600xscg.html

        MIBs

        MIB MIBs Link

        MIBs Supporting Cisco IOS

        To locate and download MIBs for selected platforms, Cisco IOS releases, and feature sets, use Cisco MIB Locator found at the following URL:

        http:/​/​www.cisco.com/​go/​mibs

        Technical Assistance

        Description Link

        The Cisco Support website provides extensive online resources, including documentation and tools for troubleshooting and resolving technical issues with Cisco products and technologies.

        To receive security and technical information about your products, you can subscribe to various services, such as the Product Alert Tool (accessed from Field Notices), the Cisco Technical Services Newsletter, and Really Simple Syndication (RSS) Feeds.

        Access to most tools on the Cisco Support website requires a Cisco.com user ID and password.

        http:/​/​www.cisco.com/​support