show policy


show policy [interface <ID> [in]] [<POLICY-NAME>] [commands] [configuration] [vsx-peer]

show policy [hitcounts <POLICY-NAME> [interface <ID> [in]]] [vsx-peer]


Shows various aspects of policies and their current use.

Use the show policy hitcounts command to display policy statistics.

Command context

Operator (>) or Manager (#)


All parameters are optional.

interface <ID>

Specifies limiting the display to a specific interface.


Specifies limiting the display to ingress policies


Specifies displaying information matching this policy name.


Specifies display output as CLI commands showing the configured policy entries.


Specifies display policies that have been configured, including those policies not active because of issues with the command parameters or hardware issues. This parameter is useful if there is a mismatch between the entered configuration and the previous successfully programmed (active) policies.


Specifies display policy hit counts (statistics).


Shows the output from the VSX peer switch. If the switches do not have the VSX configuration or the ISL is down, the output from the VSX peer switch is not displayed.


Operators or Administrators. Users without administrator authority can execute this command from the operator context (>) only.


Showing information for all policies:

switch# show policy
  Sequence Comment
           Class Type
        10 This is my QOS policy.
           class1 ip
                    dscp af21
        20 This is my PBR policy.

Showing policy CLI commands:

switch# show policies commands
policy MY_POLICY
       10 class ip MY_CLASS1 action dscp af21 action drop
       20 comment pbr policy string

Showing policy statistics for hit counts:

switch# show policy hitcounts MY_POLICY
Statistics for Policy MY_POLICY:
Interface 1/1/1* (in):
           Hit Count  Configuration
10 class ip MY_CLASS1 action dscp af21 action drop
                  20  10 match any any any count
* policy statistics are shared among all applied interfaces
  use 'policy NAME copy' to create a uniquely-named policy