Clear MACsec Statistics

About this task

You have the option to clear MACsec statistics for all ports, or clear MACsec statistics for a specific port. Clearing MACsec statistics can be useful for debugging purposes.

Procedure

  1. Enter Global Configuration mode:

    enable

    configure terminal

  2. Clear all MACsec statistics:

    macsec clear-stats

  3. Optional: Clear MACsec statistics for a specific port:

    macsec clear-stats port {slot/port[/sub-port] [-slot/port[/sub-port]] [,...]}

Example

Clear all MACsec statistics:

Switch:1>enable
Switch:1#configure terminal
Enter configuration commands, one per line.  End with CNTL/Z.
Switch:1(config)#macsec clear-stats

Clear MACsec statistics for a specific port:

Switch:1>enable
Switch:1#configure terminal
Enter configuration commands, one per line.  End with CNTL/Z.
Switch:1(config)#macsec clear-stats port 1/3

Variable Definitions

Use the data in the following table to use the clear macsec-stats command.

Table 1.
Variable Value
port {slot/port[/sub-port] [-slot/port[/sub-port]] [,...]}

Identifies the slot and port in one of the following formats: a single slot and port (slot/port), a range of slots and ports (slot/port-slot/port), or a series of slots and ports (slot/port,slot/port,slot/port). If the platform supports channelization and the port is channelized, you must also specify the sub-port in the format slot/port/sub-port.