Displaying TSN Statistics

Displaying TSN Statistics

Ingress Statistics

show interface tsn ingress stats
TSN_Switch # show interface Gig1/4 tsn ingress stats 1002
                   Latest         Accumulated
                   ------         ------------
Unexpected         0              0
In-Window          254476         267372
Early              0              0
Late               0              9003

Notes on Ingress counters

  • Unexpected (Unexpected packets)

    • The number of packets that matched global VLAN and DMAC

    • flow enable bit NOT set or

    • corresponding portmap bit in the flow table NOT set

  • In-Window (In Window Bin)

    • The number of packets that arrived within flow’s defined window

  • Early (Early Bin)

    • The number of packets that arrived before the flow’s defined window

  • Late (Late Bin)

    • The number of packets that arrived after the flow’s defined window


Note

Use ‘show tsn flow details’ for defined ingress window for all TSN flows.

The values under
Latest
are reset after every read.

Egress Statistics

Use this command to see per flow egress counters. This will show if there are errors on egress because of timing sync errors.

show interface tsn flow stats
TSN_Switch# show interface Gig1/5 tsn flow-stats 1001
Flow ID : 1001 (0x3E9)

Frame Type          Latest        Accumulated
———————————         ———————————   -------------
TSN Queue xmit      0             0
TSN Queue rcv       0             0
TSN xmit timing                   0
TSN Unreleased                    0

Notes on Egress counters

  • TSN Queue xmit (nTransmittedTfFrames)

    • This is a clear-on-read counter

    • This counter is increased

      • if a frame belonging to <flow-id> is a time-triggered (TT) frame AND

      • is transmitted to TXM’s output queue

  • TSN Queue rcv (nReceivedTtFrames)

    • This is a clear-on-read counter

    • This counter is increased

      • if a frame belonging to <flow-id> is a time-triggered (TT) frame AND...

        • is received correctly, frame size correct, crc correct

  • TSN xmit timing (nTimingError)

    • This is NOT a clear-on-read counter

    • This counter is increased when

      • window is closed or...

      • synchronization is not established

      • flushing of TT buffer not completed

  • TSN Unreleased (nUnreleased)

    • This is NOT a clear-on-read counter

    • This counter is increased when

      • a frame is received for a flow that is dispatched before the most recent frame is dispatched to all ports


Note

Ensure that flow ID <flow_id> exists with an egress interface


Use the following variation of the egress statistics command to see per interface egress counters. This shows all bytes and frames that have successfully egressed. This is for TSN and Best Effort Ethernet frames. No flow id required because its for all interfaces.
TSN_Switch# show interface Gig1/5 tsn egress counters
Status                Count
—————————----------   ———————————----
Number of Rx frames   0
Number of Rx bytes    0
Number of Tx frames   0
Number of Tx bytes    0

Notes on counters

  • These are counters maintained by TSN egress logic and apply to all Ethernet frames, not just TSN frames.

  • Number of frames received by the Egress logic

  • Number of bytes received by the Egress logic

  • Number of frames transmitted by the Egress logic

  • Number of bytes transmitted by the Egress logic

Use this variation to see per interface egress error counters.show int tsn egress error
#show int <intf_name><intf_num> tsn egress error

Error                                         Count          
------------------------------------------    ---------------
Traffic engineering params mismatch (drop)    0              
Broadcast frames not allowed (drop)           0              
Size error (drop)                             0              
CRC error at TSN Rx (drop)                    0              
Flow not found (drop)                         0              
Flow policing error (drop)                    296544         
Memory unavailable (drop)                     0

Notes on counters

  • These are NOT clear-on-read registers

  • Traffic engineering params mismatch (drop) (nDropNonCiscoErrors)

  • Broadcast frames not allowed (drop) (nBroadcastErrors)

  • Size error (drop) (nSizeErrors)

  • CRC error at TSN Rx (nCrcErrors)

  • Flow not found (nFlowNotFoundErrors)

  • Flow policing error (nFlowPolicingErrors)

  • Memory unavailable (nPartitionDrop)

Use this command to show TSN related egress errors on the interface.show int tsn egress details
#show int <intf_name><intf_num> tsn egress details

Port status counter               Latest         Accumulated
--------------------              ----------     ------------
Runt frames                       0              0
Start of frame delimiter error    0              0
Alignment error                   0              0
MII error                         0              0

Port status flag                     SET/UNSET
---------------------------------    ----------
Max age drop flag                    UNSET
No space in TSN queue flag           UNSET
Flow is not a TSN flow flag          UNSET
TSN time check fail flag             UNSET
Do not allow broadcast frame flag    UNSET

Notes on counters

  • Port status counter shown above are clear-on-read registers

  • Port status flag shown above are NOT clear-on-read registers. These are boolean counters that will have either SET or UNSET value.

  • Runt frames (nRuntFrames)

  • Start of frame delimiter error (nSofErrors)

  • Alignment error (nAlignmentErrors)

  • MII error (nMiiErrors)

Notes on implementation

  • No check whether the port in question is part of a TSN flow

  • These error counters are global counters and not related to any particular flow

  • These error counters are across all existing TSN flows

Clear statistics counts

clear tsn flow_stats flowsclear tsn stats interface <intf_name><intf_num>
  • When this CLI is executed reset all software accumulators for MAC-level diagnostics counters. These accumulators are per port.

Best Effort statistics

show tsn be_stats
TSN_switch1#show tsn be_stats 
Status            Latest             Accumulated        Latest             Accumulated        Latest             Accumulated    
                  (Port 1-8)         (Port 1-8)         (Port 9-16)        (Port 9-16)        (Port 17-24)       (Port 17-24)   
--------------    ---------------    ---------------    ---------------    ---------------    ---------------    ---------------
BE Rx frames      109                150                0                  0                  0                  0              
BE Tx frames      109                150                0                  0                  0                  0