Monitoring QoS Statistics

About QoS Statistics

You can display various QoS statistics for the device. By default, statistics are enabled, but you can disable this feature. For more information, see the Configuration Examples For Monitoring QoS Statistics section.

Prerequisites for Monitoring QoS Statistics

Monitoring QoS statistics has the following prerequisites:

  • You must be familiar with using modular QoS CLI.

  • You are logged on to the device.

Guidelines and Limitations for Monitoring QoS Statistics

Monitoring QoS statistics has the following guidelines and limitations:

  • show commands with the internal keyword are not supported.

  • In 64 bit architecture:

    • The queuing tabular output will retain same value of 15 seconds.

    • The tabular output after clear statistics, will hold zero statistics for maximum of 15 seconds.

  • The show queuing interface command can display information about internal interfaces.

    The command format for this information is specified as ii x/y/z . Where x is the module number, y is the value 1, and z is the internal interface number within the module.


    Note


    The number of internal interfaces within a module varies based on the type of the line card.



    Note


    Alternatively, you can display information about internal interfaces by providing the module number in the show queuing command. By including the module number, queuing information for both front-panel and internal interfaces of the module are displayed together.


    Example:

    
    switch# show queuing interface ii 4/1/2
    
    slot  4
    =======
    
    
    Egress Queuing for ii4/1/2 [System]
    ------------------------------------------------------------------
    QoS-Group# Bandwidth% PrioLevel                Shape
                                       Min          Max        Units
    ------------------------------------------------------------------
          3             -         1           -            -     -
          2             0         -           -            -     -
          1             0         -           -            -     -
          0           100         -           -            -     -
    +-------------------------------------------------------------------+
    |                              QOS GROUP 0                          |
    +-------------------------------------------------------------------+
    |                |  Unicast       | OOBFC Unicast  |  Multicast     |
    +-------------------------------------------------------------------+
    |        Tx Pkts |               0|               0|          235775|
    |        Tx Byts |               0|               0|        22634400|
    |   Dropped Pkts |               0|               0|               0|
    |   Dropped Byts |               0|               0|               0|
    |   Q Depth Byts |               0|               0|               0|
    +-------------------------------------------------------------------+
    |                              QOS GROUP 1                          |
    +-------------------------------------------------------------------+
    |                |  Unicast       | OOBFC Unicast  |  Multicast     |
    +-------------------------------------------------------------------+
    |        Tx Pkts |               0|               0|               0|
    |        Tx Byts |               0|               0|               0|
    |   Dropped Pkts |               0|               0|               0|
    |   Dropped Byts |               0|               0|               0|
    |   Q Depth Byts |               0|               0|               0|
    +-------------------------------------------------------------------+
    |                              QOS GROUP 2                          |
    +-------------------------------------------------------------------+
    |                |  Unicast       | OOBFC Unicast  |  Multicast     |
    +-------------------------------------------------------------------+
    |        Tx Pkts |               0|               0|               0|
    |        Tx Byts |               0|               0|               0|
    |   Dropped Pkts |               0|               0|               0|
    |   Dropped Byts |               0|               0|               0|
    |   Q Depth Byts |               0|               0|               0|
    +-------------------------------------------------------------------+
    |                              QOS GROUP 3                          |
    +-------------------------------------------------------------------+
    |                |  Unicast       | OOBFC Unicast  |  Multicast     |
    +-------------------------------------------------------------------+
    |        Tx Pkts |               0|               0|               0|
    |        Tx Byts |               0|               0|               0|
    |   Dropped Pkts |               0|               0|               0|
    |   Dropped Byts |               0|               0|               0|
    |   Q Depth Byts |               0|               0|               0|
    +-------------------------------------------------------------------+
    |                      CONTROL QOS GROUP                            |
    +-------------------------------------------------------------------+
    |                |  Unicast       | OOBFC Unicast  |  Multicast     |
    +-------------------------------------------------------------------+
    |        Tx Pkts |               0|               0|               0|
    |        Tx Byts |               0|               0|               0|
    |   Dropped Pkts |               0|               0|               0|
    |   Dropped Byts |               0|               0|               0|
    |   Q Depth Byts |               0|               0|               0|
    +-------------------------------------------------------------------+
    |                         SPAN QOS GROUP                            |
    +-------------------------------------------------------------------+
    |                |  Unicast       | OOBFC Unicast  |  Multicast     |
    +-------------------------------------------------------------------+
    |        Tx Pkts |               0|               0|               0|
    |        Tx Byts |               0|               0|               0|
    |   Dropped Pkts |               0|               0|               0|
    |   Dropped Byts |               0|               0|               0|
    |   Q Depth Byts |               0|               0|               0|
    +-------------------------------------------------------------------+
    Cannot get ingress statistics for if_index: 0x4a180001 Error 0xe
    
    Port Egress Statistics
    --------------------------------------------------------
    WRED Drop Pkts                              0
    
    PFC Statistics
    ----------------------------------------------------------------------------
    TxPPP:                    0, RxPPP:                    0
    ----------------------------------------------------------------------------
    COS QOS Group        PG   TxPause   TxCount         RxPause         RxCount
       0         -         -  Inactive         0        Inactive               0
       1         -         -  Inactive         0        Inactive               0
       2         -         -  Inactive         0        Inactive               0
       3         -         -  Inactive         0        Inactive               0
       4         -         -  Inactive         0        Inactive               0
       5         -         -  Inactive         0        Inactive               0
       6         -         -  Inactive         0        Inactive               0
       7         -         -  Inactive         0        Inactive               0
    ----------------------------------------------------------------------------
    
    

Enabling Statistics

You can enable or disable QoS statistics for all interfaces on the device. By default, QoS statistics are enabled.

SUMMARY STEPS

  1. configure terminal
  2. Enable or disable QoS statistics:
    • Enable QoS statistics:

      qos statistics

    • Disable QoS statistics:

      no qos statistics

  3. show policy-map interface
  4. (Optional) show policy-map interface brief
  5. copy running-config startup-config

DETAILED STEPS

  Command or Action Purpose

Step 1

configure terminal

Example:

switch# configure terminal
switch(config)#

Enters global configuration mode.

Step 2

Enable or disable QoS statistics:

  • Enable QoS statistics:

    qos statistics

  • Disable QoS statistics:

    no qos statistics

Example:

  • Enable QoS statistics:

    switch(config)# qos statistics
  • Disable QoS statistics:

    switch(config)# no qos statistics
  • Enable QoS statistics:

    Enables QoS statistics on all interfaces.

  • Disable QoS statistics:

    Disables QoS statistics on all interfaces.

Step 3

show policy-map interface

Example:

switch(config)# show policy-map interface

(Optional) Displays the statistics status and the configured policy maps on all interfaces.

Step 4

(Optional) show policy-map interface brief

Example:

switch(config)# show policy-map interface brief
(Optional)

Displays brief output of all policies and policy-name only in brief output displays maximum of 25 character length for easy understandability.

Step 5

copy running-config startup-config

Example:

switch(config)# copy running-config
startup-config

(Optional) Saves the running configuration to the startup configuration.

Monitoring the Statistics

You can display QoS statistics for all interfaces or a selected interface, data direction, or a QoS type.

SUMMARY STEPS

  1. show policy-map [policy-map-name] [interface [input | output]] [type {control-plane | network-qos | qos | queuing}]

DETAILED STEPS

Command or Action Purpose

show policy-map [policy-map-name] [interface [input | output]] [type {control-plane | network-qos | qos | queuing}]

Example:

switch# show policy-map interface ethernet 2/1

Displays statistics and the configured policy maps on all interfaces, the specified interface, or on a specified data direction or QoS type.

Clearing Statistics

You can clear QoS statistics for all interfaces or a selected interface, data direction, or QoS type.

SUMMARY STEPS

  1. clear qos statistics [interface [input | output] [type {qos | queuing}]]

DETAILED STEPS

Command or Action Purpose

clear qos statistics [interface [input | output] [type {qos | queuing}]]

Example:

switch# clear qos statistics type qos

Clears statistics and the configured policy maps on all interfaces or the specified interface or on a specified data direction or QoS type.

Configuration Examples For Monitoring QoS Statistics

The following example shows how to display the QoS statistics:


Global statistics status :   enabled

Ethernet6/1
          Service-policy (queuing) output:   default-out-policy 

            Class-map (queuing):   c-out-q3 (match-any)
              priority level 1

            Class-map (queuing):   c-out-q2 (match-any)
              bandwidth remaining percent 0

            Class-map (queuing):   c-out-q1 (match-any)
              bandwidth remaining percent 0

            Class-map (queuing):   c-out-q-default (match-any)
              bandwidth remaining percent 100

The following example shows how to obtain information about queuing and PFC related counters:


switch(config-vlan-config)# show queuing interface ethernet 2/1

Egress Queuing for Ethernet2/1 [System]
------------------------------------------------------------------
QoS-Group# Bandwidth% PrioLevel                Shape     
                                   Min          Max        Units
------------------------------------------------------------------
      3             -         1           -            -     -
      2             0         -           -            -     -
      1             0         -           -            -     -
      0           100         -           -            -     -
+-------------------------------------------------------------------+
|                              QOS GROUP 0                          |
+-------------------------------------------------------------------+
|        Tx Pkts |               0|   Dropped Pkts |               0|
+-------------------------------------------------------------------+
|                              QOS GROUP 1                          |
+-------------------------------------------------------------------+
|        Tx Pkts |               0|   Dropped Pkts |               0|
+-------------------------------------------------------------------+
|                              QOS GROUP 2                          |
+-------------------------------------------------------------------+
|        Tx Pkts |               0|   Dropped Pkts |               0|
+-------------------------------------------------------------------+
|                              QOS GROUP 3                          |
+-------------------------------------------------------------------+
|        Tx Pkts |               0|   Dropped Pkts |               0|
+-------------------------------------------------------------------+
|                      CONTROL QOS GROUP 4                          |
+-------------------------------------------------------------------+
|        Tx Pkts |              58|   Dropped Pkts |               0|
+-------------------------------------------------------------------+
|                         SPAN QOS GROUP 5                          |
+-------------------------------------------------------------------+
|        Tx Pkts |               0|   Dropped Pkts |             948|
+-------------------------------------------------------------------+