Wednesday, November 20, 2013

Running shell scripts on Junos

You can run a shell script in Junos.

user@R1> start shell
% su
Password:
root@R1% sh tpl.sh 
root@R1% ls
op1.txt tpl.sh
root@R1% more op1.txt 
set interfaces xe-0/0/0 description to-R4-xe-0/3/0
set interfaces xe-0/0/0 unit 0 family inet mtu 1500

root@R1% 
root@R1% more tpl.sh 
#!/sbin/sh

cli -c 'show configuration interfaces | display set' >> op1.txt
root@R1% 
root@R1% exit
exit
% exit

Saturday, November 9, 2013

Op script to disable a vc-port in a virtual chassis

A customer asked for a script to disable a vcp-port in case there were flapping issues.

There is a cli command that does this

jnpr@EX4200-VC-2> request virtual-chassis vc-port set interface vcp-0 disable member 0 
fpc0:
--------------------------------------------------------------------------

{master:0}
jnpr@EX4200-VC-2> show virtual-chassis vc-port 
fpc0:
--------------------------------------------------------------------------
Interface   Type              Trunk  Status       Speed        Neighbor
or                             ID                 (mbps)       ID  Interface
PIC / Port
vcp-0       Dedicated           1    Disabled     32000   <<<<<<<<<<<<<<<< HERE
vcp-1       Dedicated           2    Up           32000        1   vcp-0  

fpc1:
--------------------------------------------------------------------------
Interface   Type              Trunk  Status       Speed        Neighbor
or                             ID                 (mbps)       ID  Interface
PIC / Port
vcp-0       Dedicated           1    Up           32000        0   vcp-1  
vcp-1       Dedicated           2    Down         32000

jnpr@EX4200-VC-2> request virtual-chassis vc-port set interface vcp-0 member 0           
fpc0:
--------------------------------------------------------------------------

{master:0}
jnpr@EX4200-VC-2> show virtual-chassis vc-port                                    
fpc0:
--------------------------------------------------------------------------
Interface   Type              Trunk  Status       Speed        Neighbor
or                             ID                 (mbps)       ID  Interface
PIC / Port
vcp-0       Dedicated           1    Up           32000        1   vcp-1  <<<<<<<<<<< re-enabled
vcp-1       Dedicated           2    Up           32000        1   vcp-0  

fpc1:
--------------------------------------------------------------------------
Interface   Type              Trunk  Status       Speed        Neighbor
or                             ID                 (mbps)       ID  Interface
PIC / Port
vcp-0       Dedicated           1    Up           32000        0   vcp-1  
vcp-1       Dedicated           2    Up           32000        0   vcp-0  

----------------------

Demo of the script to disable vc-port

-----------------------

jnpr@EX4200-VC-2# run show virtual-chassis vc-port 
fpc0:
--------------------------------------------------------------------------
Interface   Type              Trunk  Status       Speed        Neighbor
or                             ID                 (mbps)       ID  Interface
PIC / Port
vcp-0       Dedicated           1    Up           32000        1   vcp-1  
vcp-1       Dedicated           2    Up           32000        1   vcp-0  

fpc1:
--------------------------------------------------------------------------
Interface   Type              Trunk  Status       Speed        Neighbor
or                             ID                 (mbps)       ID  Interface
PIC / Port
vcp-0       Dedicated           1    Up           32000        0   vcp-1  
vcp-1       Dedicated           2    Up           32000        0   vcp-0  

{master:0}[edit]
jnpr@EX4200-VC-2# run op vcp ?
Possible completions:
  <[Enter]>            Execute this command
  <name>               Argument name
  action               0 to enable, 1 to disable
  detail               Display detailed output
  interface            interface name.
  |                    Pipe through a command
{master:0}[edit]
jnpr@EX4200-VC-2# run op vcp interface vcp-0 action 1 

jnpr@EX4200-VC-2# run show virtual-chassis vc-port 
fpc0:
--------------------------------------------------------------------------
Interface   Type              Trunk  Status       Speed        Neighbor
or                             ID                 (mbps)       ID  Interface
PIC / Port
vcp-0       Dedicated           1    Disabled     32000
vcp-1       Dedicated           2    Up           32000        1   vcp-0  

fpc1:
--------------------------------------------------------------------------
Interface   Type              Trunk  Status       Speed        Neighbor
or                             ID                 (mbps)       ID  Interface
PIC / Port
vcp-0       Dedicated           1    Up           32000        0   vcp-1  
vcp-1       Dedicated           2    Down         32000

{master:0}[edit]
jnpr@EX4200-VC-2# run op vcp interface vcp-0 action 0    

{master:0}[edit]
jnpr@EX4200-VC-2# run show virtual-chassis vc-port       
fpc0:
--------------------------------------------------------------------------
Interface   Type              Trunk  Status       Speed        Neighbor
or                             ID                 (mbps)       ID  Interface
PIC / Port
vcp-0       Dedicated           1    Up           32000        1   vcp-1  
vcp-1       Dedicated           2    Up           32000        1   vcp-0  

fpc1:
--------------------------------------------------------------------------
Interface   Type              Trunk  Status       Speed        Neighbor
or                             ID                 (mbps)       ID  Interface
PIC / Port
vcp-0       Dedicated           1    Up           32000        0   vcp-1  
vcp-1       Dedicated           2    Up           32000        0   vcp-0  


---------------------------- 
Source code
----------------------------

jnpr@EX4200-VC-2# run file show /var/db/scripts/op/vcp.slax 
version 1.0;

ns junos= "http://xml.juniper.net/junos/*/junos";

ns xnm= "http://xml.juniper.net/xnm/1.1/xnm";

ns jcs= "http://xml.juniper.net/junos/commit-scripts/1.0";

import "../import/junos.xsl";

var $arguments = {
    <argument> {
        <name> "interface";
        <description> "interface name.";
    }
    <argument> {
        <name> "action";
        <description> "0 to enable, 1 to disable";
    }
}
param $interface;
param $action =0;

                                        
match /
{
    <event-op-results> {

        if ($action = 1) {
           var $interface-info = <command> "request virtual-chassis vc-port set interface " _ $interface _ " disable member 0";
           var $interface-result = jcs:invoke($interface-info);
        }
        if ($action = 0) {
           var $interface-info = <command> "request virtual-chassis vc-port set
interface " _ $interface _ " member 0";
           var $interface-result = jcs:invoke($interface-info);
        }

    }

}

Thursday, November 7, 2013

FEC 129 - VPLS with BGP auto-discovery using LDP

New version of JUNOS supports FEC 129 BGP auto-discovery.
You don't have to manually configure each pseudo wire. You will use BGP to auto discover the other PEs. no need for a site-ids (rsvp based) or vpls-ids (manual ldp psuedowires). 

Two commands to consider is the l2vpn-id which is similar to the vrf-target. And the auto-discovery-only command in BGP. 

Below will connect to various PEs 

user@router# show routing-instances 
VPLS {
    instance-type vpls;
    interface et-0/1/0.1;
    route-distinguisher 2.2.2.2:852;
    l2vpn-id l2vpn-id:100:1;
    vrf-target target:100:1;
    protocols {
        vpls {
            encapsulation-type ethernet-vlan;
            no-tunnel-services;
        }
    }
}

{master}[edit]
user@router# show protocols bgp 
path-selection external-router-id;
log-updown;
group RR {
    type internal;
    local-address 2.2.2.2;
    family l2vpn {
        auto-discovery-only;
    }
    neighbor 192.168.1.1;
    neighbor 192.168.1.2;
    neighbor 192.168.1.3;
    neighbor 192.168.1.4;
    neighbor 192.168.1.5;
    neighbor 192.168.1.6;               
    neighbor 192.168.1.7;
    neighbor 192.168.1.8;
    neighbor 192.168.1.10;
}

{master}[edit]
user@router# show interfaces et-0/1/0 
flexible-vlan-tagging;
encapsulation flexible-ethernet-services;
unit 1 {
    encapsulation vlan-vpls;
    vlan-id 1;
    family vpls;
}


user@router# run show ldp database session 192.168.1.1 
Input label database, 2.2.2.2:0--192.168.1.1:0
  Label     Prefix
     16      FEC129 NoCtrlWord VLAN 000a0064:00000001 c0a80101 02020202

Output label database, 2.2.2.2:0--192.168.1.1:0
  Label     Prefix
      0      2.2.2.2/32
 299920      192.168.1.1/32
 299936      192.168.1.2/32
 299952      192.168.1.3/32
 299968      192.168.1.4/32
 299984      192.168.1.5/32
 300000      192.168.1.6/32
 300016      192.168.1.7/32
 300032      192.168.1.8/32
 300048      192.168.1.9/32
 300064      192.168.1.10/32
 262145      FEC129 NoCtrlWord VLAN 000a0064:00000001 02020202 c0a80101

{master}[edit]
user@router# run show bgp summary 
Groups: 1 Peers: 9 Down peers: 0
Table          Tot Paths  Act Paths Suppressed    History Damp State    Pending
inet.0               
                       0          0          0          0          0          0
inet6.0              
                       0          0          0          0          0          0
bgp.l2vpn.0          
                       9          9          0          0          0          0
inet.2               
                       0          0          0          0          0          0
Peer                     AS      InPkt     OutPkt    OutQ   Flaps Last Up/Dwn State|#Active/Received/Accepted/Damped...
192.168.1.1             852         18         20       0       0        8:07 Establ
  inet.0: 0/0/0/0
  inet6.0: 0/0/0/0
  bgp.l2vpn.0: 1/1/1/0
  inet.2: 0/0/0/0
  VPLS.l2vpn.0: 1/1/1/0

                                        
{master}[edit]
user@router# run show vpls connections 
Layer-2 VPN connections:

Legend for connection status (St)   
EI -- encapsulation invalid      NC -- interface encapsulation not CCC/TCC/VPLS
EM -- encapsulation mismatch     WE -- interface and instance encaps not same
VC-Dn -- Virtual circuit down    NP -- interface hardware not present 
CM -- control-word mismatch      -> -- only outbound connection is up
CN -- circuit not provisioned    <- -- only inbound connection is up
OR -- out of range               Up -- operational
OL -- no outgoing label          Dn -- down                      
LD -- local site signaled down   CF -- call admission control failure      
RD -- remote site signaled down  SC -- local and remote site ID collision
LN -- local site not designated  LM -- local site ID not minimum designated
RN -- remote site not designated RM -- remote site ID not minimum designated
XX -- unknown connection status  IL -- no incoming label
MM -- MTU mismatch               MI -- Mesh-Group ID not available
BK -- Backup connection         ST -- Standby connection
PF -- Profile parse failure      PB -- Profile busy
RS -- remote site standby SN -- Static Neighbor
LB -- Local site not best-site   RB -- Remote site not best-site
VM -- VLAN ID mismatch

Legend for interface status 
Up -- operational           
Dn -- down

Instance: VPLS
  L2vpn-id: 100:1
  Local-id: 2.2.2.2
    Remote-id                 Type  St     Time last up          # Up trans
    192.168.1.1               rmt   Up     Nov  7 20:58:18 2013           1
      Remote PE: 192.168.1.1, Negotiated control-word: No
      Incoming label: 262145, Outgoing label: 16
      Local interface: lsi.1048841, Status: Up, Encapsulation: VLAN
        Description: Intf - vpls VPLS local-id 2.2.2.2 remote-id 192.168.1.1 neighbor 192.168.1.1

Monday, October 28, 2013

Use a script to customize the snmp utility mib

Example of snmp utility mib via CLI
-----------------------

user@router> request snmp utility-mib set instance test object-type string object-value ABC
Utility mib result: successfully populated utility mib database

user@router> show snmp mib walk jnxUtil
jnxUtilStringValue.116.101.115.116 = ABC

user@router> request snmp utility-mib clear instance test object-type string
Utility mib result: successfully de-populated utility mib database


user@router> show snmp mib walk jnxUtil

------------

Now via script:
jnpr@Chef-RE0> op mib-util value "Hello World"

jnpr@Chef-RE0> show snmp mib walk jnxUtil
jnxUtilStringValue.116.101.115.116 = Hello World

Source Code:
------------







version 1.0;

ns junos = "http://xml.juniper.net/junos/*/junos";
ns xnm = "http://xml.juniper.net/xnm/1.1/xnm";
ns jcs = "http://xml.juniper.net/junos/commit-scripts/1.0";
ns ext = "http://xmlsoft.org/XSLT/namespace";

import "../import/junos.xsl";

var $arguments = <argument> {
    <name> "value";
    <description> "object value";
}
param $value;

match / {

        <op-script-results> {



                var $mibset-subs = <request-snmp-utility-mib-set> {

                    <object-type> "string";

                    <instance> "test";

                    <object-value> $value;

                }

                var $result=jcs:invoke($mibset-subs);

                }

}

Friday, October 25, 2013

Are the snmp index values for Mpls Tunnels persistent? And how to decode the index values.

A customer was reporting that the mplsTunnelDown SNMP Trap shows a tunnel index, but that the correlating mplsTunnelUp SNMP Trap shows a different tunnel index. We wanted to know if the indexes were persistent.


It looks like this can possibly happen if mpls has to rebuild the lsps (i.e. due to a crash), but not when there is a link flap.

user@PE-router-RE0# run show snmp mib walk mplsTunnelName.29702 
mplsTunnelName.29702.1.2870018049.2870018050 = router-to-MX-1

[edit]
user@PE-router-RE0# run restart routing 
Routing protocols process signalled but still running, waiting 8 seconds more
Routing protocols process started, pid 1707

[edit]
user@PE-router-RE0# run show snmp mib walk mplsTunnelName     |  Match router
mplsTunnelName.26096.1.2870018049.2870018050 = router-to-MX-1

[edit]
user@PE-router-RE0# run show snmp mib walk mplsTunnelName.29702    

[edit]
user@PE-router-RE0# run show snmp mib walk mplsTunnelName | match router 
mplsTunnelName.26096.1.2870018049.2870018050 = router-to-MX-1

When I flapped a link on the lsp, the tunnel index stayed the same. So something has to happen where rpd has to rebuild the lsps.

The second part is how can you decipher the snmp OID index value.

user@PE-router-RE0> show mpls lsp ingress name router-to-MX-1 
Ingress LSP: 6 sessions
To              From            State Rt P     ActivePath       LSPname
171.17.0.2      171.17.0.1      Up     0 *                      router-to-MX-1
Total 1 displayed, Up 1, Down 0

user@PE-router-RE0> show snmp mib get mplsTunnelName.26096.1.2870018049.2870018050    
mplsTunnelName.26096.1.2870018049.2870018050 = router-to-MX-1


2870018049 as an integer and convert to hex to get 0xAB110001.

Split it into 4 octets:
AB = 171
11 = 17
00 = 0
01 = 1

Which is 171.17.0.1 


Tuesday, October 22, 2013

Juniper PTP Interop between Cisco ASR 901 and Alcatel 7705 SR


I did an interop test of PTP between Juniper ACX as Boundary Clock Master and a Cisco ASR 901 and ALU 7705 SR.


GM ===== ACX2000 ====== Cisco ASR 901
                              ||
                               =========== ALU 7705 SR


It works!

---------------

Cisco Configuration - ASR 901

interface Loopback0
 ip address 192.168.112.200 255.255.255.255
!
interface GigabitEthernet0/0
 speed 1000
 duplex full
 no negotiation auto
 cdp enable
 service instance 1 ethernet
  encapsulation untagged
  bridge-domain 1
 !
!


interface Loopback0
 ip address 192.168.112.200 255.255.255.255

interface Vlan1
 ip address 192.168.112.2 255.255.255.252
!
router ospf 1
 router-id 99.99.99.99
 area 0.0.0.1 stub
 network 192.168.112.0 0.0.0.3 area 0.0.0.1
 network 192.168.112.200 0.0.0.0 area 0.0.0.1
!

ptp clock ordinary domain 17
 priority1 100
 priority2 101
 1pps-out 0 125 ms
 clock-port slave slave
  sync interval -7
  transport ipv4 unicast interface Lo0 negotiation
  clock source 192.168.112.1
!
end

asr901#show ptp clock running 



                      PTP Ordinary Clock [Domain 17]

         State          Ports          Pkts sent      Pkts rcvd      

         ACQUIRING      1              108406         208432    

                               PORT SUMMARY

Name               Tx Mode      Role         Transport    State        Sessions
slave              unicast      slave        Lo0          Slave        1

Cisco Restrictions
 The loopback address configured for PTP port can be used only for PTP functionality.
 The loopback address configured for PTP port does not respond to pings.
• A clock port once configured as master cannot change to slave dynamically, and vice versa.
 PTP boundary clock can be configured for only one domain.
asr901#show ptp clock dataset default


CLOCK [Ordinary Clock, domain 17]

  Two Step Flag: No
  Clock Identity: 0xFC:99:47:FF:FE:A6:3B:4D
  Number Of Ports: 1
  Priority1: 100
  Priority2: 101
  Domain Number: 17
  Slave Only: Yes
  Clock Quality:
    Class: 248
    Accuracy: Within 25us
    Offset (log variance): 22272

asr901#show ptp clock dataset parent domain

CLOCK [Ordinary Clock, domain 17]

  Parent Stats: No
  Observed Parent Offset (log variance): 0
  Observed Parent Clock Phase Change Rate: 0

  Grandmaster Clock:
    Identity: 0xF8:C0:1:FF:FE:8:C1:8E
    Priority1: 0
    Priority2: 0
    Clock Quality:
      Class: 52
      Accuracy: Unknown
      Offset (log variance): 11952

asr901# show ptp clock dataset default


CLOCK [Ordinary Clock, domain 17]

  Two Step Flag: No
  Clock Identity: 0xFC:99:47:FF:FE:A6:3B:4D
  Number Of Ports: 1
  Priority1: 100
  Priority2: 101
  Domain Number: 17
  Slave Only: Yes
  Clock Quality:
    Class: 248
    Accuracy: Within 25us
    Offset (log variance): 22272

 show ptp clock runn dom 17



                      PTP Ordinary Clock [Domain 17]

         State          Ports          Pkts sent      Pkts rcvd      

         PHASE_ALIGNED  1              131863         279178    

                               PORT SUMMARY

Name               Tx Mode      Role         Transport    State        Sessions

slave              unicast      slave        Lo0          Slave        1


                             SESSION INFORMATION

slave [Lo0] [Sessions 1]

 Peer addr          Pkts in    Pkts out   In Errs    Out Errs  

 192.168.112.1      130314     47461      0          0      

asr901#show platform ptp state
FLL State                     : 3 (Normal Loop)
FLL Status Duration           : 118 (sec)

Forward Flow Weight           : 0.0
Forward Flow Transient-Free   : 900 (900 sec Window)
Forward Flow Transient-Free   : 3600 (3600 sec Window)
Forward Flow Transactions Used: 199.0 (%)
Forward Flow Oper. Min TDEV   : 638.0 (nsec)
Forward Mafie                 : 0.0
Forward Flow Min Cluster Width: 433.0 (nsec)
Forward Flow Mode Width       : 1000.0 (nsec)

Reverse Flow Weight           : 100.0
Reverse Flow Transient-Free   : 900 (900 sec Window)
Reverse Flow Transient-Free   : 3600 (3600 sec Window)
Reverse Flow Transactions Used: 199.0 (%)
Reverse Flow Oper. Min TDEV   : 637.0 (nsec)
Reverse Mafie                 : 0.0
Reverse Flow Min Cluster Width: 433.0 (nsec)
Reverse Flow Mode Width       : 1000.0 (nsec)

Frequency Correction          : 33.290 (ppb)
Phase Correction              : 0.0 (ppb)

Output TDEV Estimate          : 637.0 (nsec)
Output MDEV Estimate          : 1.0 (ppb)

Residual Phase Error          : -14.64 (nsec)
Min. Roundtrip Delay          : 14.0 (nsec)

Sync Packet Rate*             : 64 (pkts/sec)
Delay Packet Rate*            : 66 (pkts/sec)

Forward IPDV % Below Threshold: 0.0
Forward Maximum IPDV          : 0.0 (usec)
Forward Interpacket Jitter    : 0.0 (usec)

Reverse IPDV % Below Threshold: 0.0
Reverse Maximum IPDV          : 0.0 (usec)
Reverse Interpacket Jitter    : 0.0 (usec)
Note: The maximum rates for Sync and Delay packets will be approximately 64 pps.

asr901#show platform ptp stats
Statistics for PTP clock 0
###############################
Number of ports : 1
Pkts Sent       : 143257
Pkts Rcvd       : 313459
Pkts Discarded  : 0
Statistics for PTP clock port 1
##################################
Pkts Sent        : 58854
Pkts Rcvd        : 164592
Pkts Discarded   : 0
Signals Rejected : 0
Statistics for peer 0
########################
IP addr   : 192.168.112.1
Pkts Sent : 58854
Pkts Rcvd : 164592

----------- 
ALU 7705

*A:7705>show# system sync-if-timing 

===============================================================================
System Interface Timing Operational Info
===============================================================================
System Status CSM A                : Master Locked
    Reference Input Mode           : Revertive
    Quality Level Selection        : Disabled

Reference Order                    : ref1 ref2 external

Reference Input 1   
    Admin Status                   : up
    Configured Quality Level       : none
    Rx Quality Level               : dnu
    Qualified For Use              : Yes
    Selected For Use               : Yes
    Source Port                    : None
    Source PTP Clock               : 1

Reference Input 2      
    Admin Status                   : down
    Configured Quality Level       : none
    Rx Quality Level               : unknown
    Qualified For Use              : No
        Not Qualified Due To       : disabled
    Selected For Use               : No
        Not Selected Due To        : disabled
    Source Port                    : None

External Reference Input   
    Admin Status                   : down
    Configured Quality Level       : stu
    Qualified For Use              : No
        Not Qualified Due To       : disabled
    Selected For Use               : No
        Not Selected Due To        : disabled
    Type                           : 2048Khz-G703
    Impedance                      : 50-Ohm

External Reference Output   
    Type                           : 2048Khz-G703
===============================================================================

System Name            : 7705-ci
System Type            : 7705 SAR-F
System Version         : B-5.0.R1

*A:7705>config>system# info 
----------------------------------------------
#--------------------------------------------------
echo "System Configuration"
#--------------------------------------------------
        name "7705"
        sync-if-timing
            ref-order ref1 ref2 external
            ref1
                source-ptp-clock 1
                no shutdown
            exit
            ref2
                shutdown
            exit
            external
                input-interface
                    shutdown
                exit
            exit
            revert
        exit
        snmp                          
        exit
        login-control
            idle-timeout disable
        exit
        ptp
            clock 1 create
                source-interface "to-ACX2K"
                clock-mda 1/2
                domain 17
                priority1 100
                priority2 101
                ptp-port 1
                    log-sync-interval -7
                    peer 1
                        description "To-ACX2K"
                        ip-address 192.168.113.1
                    exit
                    peer 2
                    exit
                    no shutdown
                exit
                no shutdown           
            exit
        exit
        time
            ntp
                server 172.17.27.46 
                no shutdown
            exit
            sntp
                shutdown
            exit
            zone PST 
        exit
        thresholds
            rmon
            exit
        exit


-------------- 
Juniper configuration
[edit]
user@ACX2000# show chassis 
fpc 0 {
    pic 0 {
        framing e1;
    }
}
synchronization {
    network-option option-1;
    esmc-transmit {
        interfaces all;
    }
}

user@ACX2000# show protocols ptp 
clock-mode boundary;
priority1 1;
priority2 2;
domain 17;
unicast-negotiation;
slave {
    convert-clock-class-to-quality-level;
    interface ge-0/2/0.0 {
        unicast-mode {
            transport ipv4;
            clock-source 200.200.3.2 local-ip-address 200.200.3.1;
        }
    }
}
master {
    interface ge-0/1/0.0 {
        unicast-mode {
            transport ipv4;             
            clock-client 192.168.112.200/32 local-ip-address 192.168.112.1;
        }
    }
    interface ge-0/1/1.0 {
        unicast-mode {
            transport ipv4;
            clock-client 192.168.113.2/32 local-ip-address 192.168.113.1;
        }
    }
}

[edit]
user@ACX2000# run show ptp port 
PTP port-data:
Local IP          : 192.168.112.1  Remote IP         : 192.168.112.200
Clock Stream      : 4              Clock Identity    : 84:18:88:ff:fe:c0:81:00  
Port State        : Master         Delay Req Interval: -6 
Announce Interval : 1              Announce Timeout  : 3  
Sync Interval     : -7             Delay Mechanism   : End-to-end
Port Number       : 5              Operating Mode    : Slave

Local IP          : 192.168.113.1  Remote IP         : 192.168.113.2
Clock Stream      : 5              Clock Identity    : 84:18:88:ff:fe:c0:81:00  
Port State        : Master         Delay Req Interval: -7 
Announce Interval : 1              Announce Timeout  : 3  
Sync Interval     : -7             Delay Mechanism   : End-to-end
Port Number       : 6              Operating Mode    : Slave



[edit]
user@ACX2000# run show ptp statistics 
Local Address    Remote Address     Role  Stream      Received  Transmitted
200.200.3.1      200.200.3.2       Slave       0      36819732     18332374
192.168.112.1    192.168.112.200  Master       4          8097     51867879
192.168.113.1    192.168.113.2    Master       5          7989     51865182