Congestion Management Commands


Note


All commands applicable for the Cisco NCS 5500 Series Router are also supported on the Cisco NCS 540 Series Router that is introduced from Cisco IOS XR Release 6.3.2. References to earlier releases in Command History tables apply to only the Cisco NCS 5500 Series Router.



Note


  • Starting with Cisco IOS XR Release 6.6.25, all commands applicable for the Cisco NCS 5500 Series Router are also supported on the Cisco NCS 560 Series Routers.

  • Starting with Cisco IOS XR Release 6.3.2, all commands applicable for the Cisco NCS 5500 Series Router are also supported on the Cisco NCS 540 Series Router.

  • References to releases before Cisco IOS XR Release 6.3.2 apply to only the Cisco NCS 5500 Series Router.

  • Cisco IOS XR Software Release 7.0.1 specific updates are not applicable for the following variants of Cisco NCS 540 Series Routers:

    • N540-28Z4C-SYS-A

    • N540-28Z4C-SYS-D

    • N540X-16Z4G8Q2C-A

    • N540X-16Z4G8Q2C-D

    • N540X-16Z8Q2C-D

    • N540-12Z20G-SYS-A

    • N540-12Z20G-SYS-D

    • N540X-12Z16G-SYS-A

    • N540X-12Z16G-SYS-D


This chapter describes the commands used to manage congestion.

decapsulate gre

To enable decapsulation of the Generic Routing Encapsulation (GRE) packets, use the decapsulate gre command in policy map class configuration mode. To remove a previously configured GRE decapsulation for a class, use the no form of this command.

decapsulate gre

no decapsulate gre

Command Default

No default action.

Command Modes

Policy map class configuration

Command History

Release

Modification

Release 6.0.1

This command was introduced.

Usage Guidelines

This command applies only to the incoming IPv4 packets only.

Task ID

Task ID

Operations

qos

read, write

Examples

This example shows how to configure decapsulation of the GRE packets :


RP/0/RP0/CPU0:router(config)# policy-map type pbr gre-policy
RP/0/RP0/CPU0:router(config-pmap)# class type traffic gre-class
RP/0/RP0/CPU0:router(config-pmap-c)# decapsulate gre


decapsulate gue

To enable decapsulation of the Generic UDP Encapsulation (GUE) packets, use the decapsulate gue command in policy map class configuration mode. To remove a previously configured GUE decapsulation for a class, use the no form of this command.

decapsulate gue version

no decapsulate gue version

Syntax Description

version

Specifies the variant number that can indicate the version of the GUE protocol. Supports variant 1 only.

Command Default

No default action.

Command Modes

Policy map class configuration

Command History

Release

Modification

Release 7.1.2

This command was introduced.

Usage Guidelines

Supports Generic UDP Decapsulation for variant 1 only. This command is supported only in Cisco NCS 5500 Series Routers.

Task ID

Task ID

Operations

qos

read, write

Examples

This example shows how to configure decapsulation of the GUE packets:


Router# configure
Router(config)# policy-map type pbr gue-decap
Router(config-pmap)# class type traffic gue-class
Router(config-pmap-c)# decapsulate gue

hw-module profile qos shared-policer-per-class-stats

To view individual class statistics (also called per-class mode for the shared policer feature), use the

hw-module profile qos shared-policer-per-class-stats command in the XR Config mode. To disable this feature, use the no form of this command.

hw-module profile qos shared-policer-per-class-stats

Syntax Description

shared-policer-per-class-stats

Enables the ability to view per-class statistics (also called per-class mode for the shared policer feature).

Command Default

The per-class mode is disabled by default, unless enabled by this command.

Command Modes

XR Config mode

Command History

Release Modification
Release 7.2.1

This command was introduced.

Usage Guidelines

You must reload the affected line card to enable the per-class-stats mode.

Task ID

Task ID Operation
qos read, write

Examples

The following example shows how to enable the per-class-stats mode.

RP/0/RP0/CPU0:router#config
RP/0/RP0/CPU0:router(config)#hw-module profile qos shared-policer-per-class-stats
RP/0/RP0/CPU0:router(config)#commit
RP/0/RP0/CPU0:router# reload

hw-module profile qos etm-low-rate-connector

To enable virtual flows and achieve precise shaper granularity at 0 kbps for shared shaper elements on the ETM-enabled interfaces, use the hw-module profile qos etm-low-rate-connector command in the XR Config mode to reserve system allocated low-rate connectors.

To disable this feature, use the no form of this command.

hw-module profile qos etm-low-rate-connector npu-id npu-id reserve-conn-range range location node-location

Syntax Description

npu-id

Specifies the NPU core for reserving low-rate connectors.

reserve-conn-range range

Specifies the number of low-rate connectors to reserve in the NPU core for virtual flows.

location node-location

Specifies the node location of the ETM-enabled interface.

Note

 

Use this keyword only if you have to reserve low-rate connectors for a specific line card or node in a modular router.

Command Default

By default, 2048 low-rate connectors are pre-allocated.

Command Modes

XR Config mode

Command History

Release Modification
Release 24.3.1

This command was introduced.

Usage Guidelines

  • Supported Cisco NCS 5700 line cards must operate in the native mode only.

  • By default, 2048 low-rate connectors are pre-allocated. However, you can configure to reserve the low-rate connectors based on specific QoS scale requirements.

  • A virtual flow is allocated to a shared quad shaper if the shaper value of the parent policy applied on an ETM-enabled interface is less than 500 Mbps.

  • Router must have an external TCAM.

  • H-QoS mode must be disabled.

Task ID

Task ID Operation
qos

read, write

Examples

The following example shows how to reserve low-rate connectors for all line cards in a modular router.

router(config)#hw-module profile qos etm-low-rate-connector npu-id 0 reserve-conn-range 4
router(config)#commit

Examples

The following example shows how to reserve low-rate connectors for a specific line card or node in a modular router.

router(config)#hw-module profile qos etm-low-rate-connector npu-id 0 reserve-conn-range 1 location 0/1/CPU0
router(config)#commit

hw-module profile qos lag-scheduler

To enable LAG-level scheduling for egress queuing, use the hw-module profile qos lag-scheduler command in the XR Config mode.

To disable this feature, use the no form of this command.

hw-module profile qos lag-scheduler

Command Default

No default behavior or values.

Command Modes

XR Config mode

Command History

Release

Modification

Release 24.3.1

This command was introduced.

Usage Guidelines

For modular routers, you must verify the NCS 5700 line cards are operating in the native mode.

Task ID

Task ID

Operations

qos

read, write

Examples

This example shows how to enable the LAG-level scheduling mode on a bundle interface for egress queuing.
router#config
router(config)#hw-module profile qos lag-scheduler
router(config)#commit
router#reload location all

hw-module oversubscription

To configure traffic priorities on the interface during oversubscription, use the hw-module oversubscription command in the XR Config mode.

To disable this feature, use the no form of this command.

hw-module oversubscription [ prioritize untagged interface interface-name ] [ prioritize cos cos-value interface interface-name ]

no hw-module oversubscription [ prioritize untagged interface interface-name ] [ prioritize cos cos-value interface interface-name ]

Syntax Description

oversubscription

Enables prioritization of packets using Oversubscription Buffer Management (OBM).

prioritize untagged interface interface-name

Prioritizes all the traffic on this untagged interface with interface-name.

prioritize cos cos-valueinterfaceinterface-name

Prioritizes all the traffic with the CoS value on the interface interface-name.

Command Default

By default, only CoS 6 and 7 is prioritized in case of oversubscription.

Command Modes

XR Config mode

Command History

Release Modification
Release 7.7.1

This command was introduced.

Examples

The following example shows how to configure the traffic priorities on untagged interface.

RP/0/RP0/CPU0:router#configure
RP/0/RP0/CPU0:router(config)#hw-module profile qos hqos-enable
RP/0/RP0/CPU0:router(config)#hw-module oversubscription
RP/0/RP0/CPU0:router(config-oversubscription)#prioritize untagged interface tenGigE 0/0/0/10
RP/0/RP0/CPU0:router(config-oversubscription)#commit

Examples

The following example shows how to configure the traffic priorities using CoS values on tagged interface.

Examples

RP/0/RP0/CPU0:router#configure
RP/0/RP0/CPU0:router(config)#hw-module profile qos hqos-enable
RP/0/RP0/CPU0:router(config)#hw-module oversubscription
RP/0/RP0/CPU0:router(config-oversubscription)#prioritize cos 1 interface tenGigE 0/0/0/0
RP/0/RP0/CPU0:router(config-oversubscription)#commit

police rate

To configure traffic policing and enter policy map police configuration mode, use the police rate command in policy map class configuration mode. To remove traffic policing from the configuration, use the no form of this command.

police rate {value [units] | percent percentage | rate [units] | per-thousand value | per-million value } [burst burst-size [burst-units] ] [peak-rate {value [units] | percent percentage}] [peak-burst peak-burst [burst-units] ]

no police rate {value [units] | percent percentage | rate [units] | per-thousand value | per-million value } [burst burst-size [burst-units] ] [peak-rate {value [units] | percent percentage}] [peak-burst peak-burst [burst-units] ]

Syntax Description

value

Committed information rate (CIR). Range is from 1 to 4294967295.

units

(Optional) Unit of measurement for the CIR. Values can be:

  • bps —bits per second (default)

  • gbps —gigabits per second

  • kbps —kilobits per second

  • mbps —megabits per second

  • pps —packets per second

percent percentage

Specifies the police rate as a percentage of the CIR. Range is from 1 to 100. See the Usage Guidelines for information on how to use this keyword.

per-thousand value

Specifies police rate as parts per thousand of the available bandwidth.

per-million value

Specifies police rate as parts per million of the available bandwidth.

burst burst-size

(Optional) Specifies the burst size in the specified burst-units . The default burst value is 10 milliseconds of the CIR. The maximum burst value allowed is 4194304 bytes.

burst-units

(Optional) Unit of measurement for the burst values. Values can be:

  • bytes —bytes (default)

  • gbytes —gigabytes

  • kbytes —kilobytes

  • mbytes —megabytes

  • ms —milliseconds

  • us —microseconds

  • packets —packets

peak-rate value

(Optional) Specifies the Peak Information Rate (PIR) in the specified units .

peak-burst peak-burst

(Optional) Specifies the peak burst size in the specified burst-units . The default peak burst value is 10 milliseconds of the PIR. The maximum peak-burst value allowed is 8388608 bytes. Also, the difference of the peak-burst value and burst value cannot be larger than 4194304 bytes.

Command Default

No restrictions on the flow of data are applied to any interface.

Command Modes

Policy map class configuration

Command History

Release

Modification

Release 6.0

This command was introduced.

Release 6.6.25

Added absolute rate units for policer on bundle and link aggregation (LAG) interfaces.

Release 7.4.1

Added packets per second (pps) units for policer rate.

Usage Guidelines

Policer conditional set is unsupported.

Policing can be applied only in the ingress direction.

For police rate commands, interpret the percent keyword in this way:

  • For a one-level policy, the percent keyword specifies the CIR as a percentage of the link rate. For example, the command police rate percent 35 configures the CIR as 35% of the link rate.


Note


Configured values take into account the Layer 2 encapsulation applied to traffic. This applies to ingress policing. For Ethernet transmission, the encapsulation is considered to be 14 bytes, whereas for IEEE 802.1Q, the encapsulation is 18 bytes.


For more information, see the Committed Bursts and Excess Bursts section in the Modular QoS Configuration Guide for Cisco NCS 5500 Series Routers.

Task ID

Task ID

Operations

qos

read, write

Examples

In this example for MPLS, traffic policing is configured with the average rate at 250 kbps, and the normal burst size at 50 bytes for all packets leaving HundredGigE interface 0/1/0/0:


RP/0/RP0/CPU0:router(config)# class-map class1            
RP/0/RP0/CPU0:router(config-cmap)# match mpls experimental topmost 0
RP/0/RP0/CPU0:router(config-cmap)# exit

RP/0/RP0/CPU0:router(config)# policy-map policy1
RP/0/RP0/CPU0:router(config-pmap)# class class1
RP/0/RP0/CPU0:router(config-pmap-c)# police rate 250 kbps burst 50
RP/0/RP0/CPU0:router(config-pmap-c)# exit
RP/0/RP0/CPU0:router(config-pmap)# exit

RP/0/RP0/CPU0:router(config)# HundredGigE interface 0/1/0/0
RP/0/RP0/CPU0:router(config-if) service-policy input policy1
  

policy-map

To create or modify a policy map that can be attached to one or more interfaces to specify a service policy, use the policy-map command in XR Config mode. To delete a policy map, use the no form of this command.

policy-map [type qos] policy-name

no policy-map [type qos] policy-name

Syntax Description

type qos

(Optional) Specifies type of the service policy.

qos

(Optional) Specifies a quality-of-service (QoS) policy map.

policy-name

Name of the policy map.

Command Default

A policy map does not exist until one is configured. Because a policy map is applied to an interface, no restrictions on the flow of data are applied to any interface until a policy map is created.

Type is QoS when not specified.

Command Modes

XR Config mode

Command History

Release

Modification

Release 6.0

This command was introduced.

Usage Guidelines

Use the policy-map command to specify the name of the policy map to be created, added to, or modified before you can configure policies for classes whose match criteria are defined in a class map. Entering the policy-map command enables policy map configuration mode in which you can configure or modify the class policies for that policy map.

You can configure class policies in a policy map only if the classes have match criteria defined for them. Use the class-map and match commands to configure the match criteria for a class.

A single policy map can be attached to multiple interfaces concurrently.

The number of classes per policy-map supported in the egress direction is 8 and ingress direction is 32.

For egress classification, in order to see statistics on all 8 CoSQs, you are recommended to configure all 8 classes including class-default.

Task ID

Task ID

Operations

qos

read, write

Examples

These examples show how to create a policy map called policy1 and configures two class policies included in that policy map. The policy map is defined to contain policy specification for class1 and the default class (called class-default) to which packets that do not satisfy configured match criteria are directed. Class1 specifies policy for traffic that matches access control list 136.


RP/0/RP0/CPU0:router(config)# class-map class1
RP/0/RP0/CPU0:router(config-cmap)# match access-group ipv4 136

RP/0/RP0/CPU0:router(config)# policy-map policy1
RP/0/RP0/CPU0:router(config-pmap)# class class1
RP/0/RP0/CPU0:router(config-pmap-c)# set precedence 3
RP/0/RP0/CPU0:router(config-pmap-c)# exit

RP/0/RP0/CPU0:router(config-pmap)# class class-default
RP/0/RP0/CPU0:router(config-pmap-c)# queue-limit  1000000 bytes
  

priority (QoS)

To assign priority to a traffic class based on the amount of available bandwidth within a traffic policy, use the priority command in policy map class configuration mode. To remove a previously specified priority for a class, use the no form of this command.

priority [level priority-level]

no priority

Syntax Description

level priority-level

(Optional) Sets multiple levels of priority to a traffic class. Level 1 through 7. Default level is 1. Level 1 traffic has higher priority.

Command Default

No default action.

Command Modes

Policy map class configuration

Command History

Release

Modification

Release 6.0

This command was introduced.

Usage Guidelines

The priority command configures low-latency queueing (LLQ), providing strict priority queueing (PQ). Strict PQ allows delay-sensitive data such as voice to be dequeued and sent before packets in other queues are dequeued. The priority command is supported only in the egress direction. No policer is allowed with a priority class. To limit the priority traffic use the shape average command.

The priority command sets up classes based on a variety of criteria (not just User Datagram Protocol [UDP] ports) and assigns a priority to them.

The bandwidth and priority commands cannot be used in the same class, within the same policy map. These commands can be used together in the same policy map.

Task ID

Task ID

Operations

qos

read, write

Examples

This example shows how to configure priority queuing for the policy map named policy1 :


RP/0/RP0/CPU0:router(config)# policy-map policy1
RP/0/RP0/CPU0:router(config-pmap)# class class1
RP/0/RP0/CPU0:router(config-pmap-c)# priority level 1


vrf-policy

To apply a policy on a per VPN routing and forwarding (VRF) basis, use the vrf-policy command in global configuration mode. To remove the association of the policy on a VRF, use the no form of this command.

vrf-policy vrf vrf-name address-family {ipv4 | ipv6 } policy type pbr input policy-name

no vrf-policy vrf vrf-name address-family {ipv4 | ipv6 } policy type pbr input policy-name

Syntax Description

vrf vrf-name

Sets the VRF name.

policy type pbr input policy-name

Sets the policy name.

Command Default

No default action.

Command Modes

Policy map class configuration

Command History

Release

Modification

Release 6.0.1

This command was introduced.

Usage Guidelines

This command is supported with sub-mode. This command applies only to the incoming IPv4 packets only.

Use this command to apply a PBR policy on a per VRF basis during the classification and decapsulation of GRE packets.

Task ID

Task ID

Operations

qos

read, write

Examples

This example shows how to apply an already configured policy on a per VRF basis:


/* Configuring a VRF */
RP/0/RP0/CPU0:router(config)# vrf gre-vrf address-family ipv4 unicast
...
/* Configuring a policy */
RP/0/RP0/CPU0:router(config)# policy-map type pbr gre-policy
...
/* Applying the policy on the VRF */
RP/0/RP0/CPU0:router(config)# vrf-policy vrf gre-vrf address-family ipv4 policy type pbr input gre-policy

show qos interface

To display QoS information for a specific interface, use the show qos interface command in the XR EXEC mode.

show qos interface interface-name {input | output} [location node-id]

Syntax Description

interface-name

Interface name. For more information about the syntax for the router, use the question mark (?) online help function.

Note

 

Use the show interfaces command to see a list of all interfaces currently configured on the router.

input

Attaches the specified policy map to the input interface.

output

Attaches the specified policy map to the output interface.

location node-id

(Optional) Displays detailed QoS information for the designated node. The node-id argument is entered in the rack/slot/module notation.

Command Default

No default behavior or values

Command Modes

XR EXEC mode

Command History

Release

Modification

Release 6.0

This command was introduced.

Usage Guidelines

The show qos interface command displays configuration for all classes in the service policy that is attached to an interface.

Use this command to check the actual values programmed in the hardware from the action keywords in the police rate command.

Task ID

Task ID

Operations

qos

read

Examples

This is the sample output shows the QoS information on a interface hundredGigE 0/6/0/18 that are in the input direction:
RP/0/RP0/CPU0:router# show qos interface hundredGigE 0/6/0/18 input

Wed Dec  2 22:34:20.241 UTC
NOTE:- Configured values are displayed within parentheses
Interface HundredGigE0/6/0/18 ifh 0x3000210  -- input policy
NPU Id:                        3
Total number of classes:       28
Interface Bandwidth:           100000000 kbps
Accounting Type:               Layer1 (Include Layer 1 encapsulation and above)
------------------------------------------------------------------------------
Level1 Class                             =   exp-classifier-af1
New topmost exp                          =   7

Default Policer Bucket ID                =   0x102a0
Default Policer Stats Handle             =   0x8b304d98
Policer not configured for this class

Level1 Class                             =   exp-classifier-af2
New topmost exp                          =   6

Default Policer Bucket ID                =   0x102a1
Default Policer Stats Handle             =   0x8b304b48
Policer not configured for this class

Level1 Class                             =   exp-classifier-af3
New topmost exp                          =   5

Default Policer Bucket ID                =   0x102a2
Default Policer Stats Handle             =   0x8b3048f8
Policer not configured for this class

Level1 Class                             =   exp-classifier-af4
New topmost exp                          =   3

Default Policer Bucket ID                =   0x102a3
Default Policer Stats Handle             =   0x8b3046a8
Policer not configured for this class

Level1 Class                             =   exp-classifier-be1
New topmost exp                          =   4

Default Policer Bucket ID                =   0x102a4
Default Policer Stats Handle             =   0x8b304458
Policer not configured for this class

Level1 Class                             =   inet4-classifier-af1
New qos group                            =   1

Default Policer Bucket ID                =   0x102a5
Default Policer Stats Handle             =   0x8b304208
Policer not configured for this class

Level1 Class                             =   inet4-classifier-af2
New qos group                            =   2

Default Policer Bucket ID                =   0x102a6
Default Policer Stats Handle             =   0x8b303fb8
Policer not configured for this class

Level1 Class                             =   inet4-classifier-af3
New qos group                            =   3

Default Policer Bucket ID                =   0x102a7
Default Policer Stats Handle             =   0x8b303d68
Policer not configured for this class

Level1 Class                             =   inet4-classifier-af4
New qos group                            =   4

Default Policer Bucket ID                =   0x102a8
Default Policer Stats Handle             =   0x8b303b18
Policer not configured for this class

Level1 Class                             =   inet4-classifier-be1
New qos group                            =   5

Default Policer Bucket ID                =   0x102a9
Default Policer Stats Handle             =   0x8b3038c8
Policer not configured for this class

Level1 Class                             =   inet4-classifier-nc1
New qos group                            =   6

Default Policer Bucket ID                =   0x102aa
Default Policer Stats Handle             =   0x8b303678
Policer not configured for this class

Level1 Class                             =   inet6-classifier-af1
New qos group                            =   1

Default Policer Bucket ID                =   0x102ab
Default Policer Stats Handle             =   0x8b303428
Policer not configured for this class

Level1 Class                             =   inet6-classifier-af2
New qos group                            =   2

Default Policer Bucket ID                =   0x102ac
Default Policer Stats Handle             =   0x8b3031d8
Policer not configured for this class

Level1 Class                             =   inet6-classifier-af3
New qos group                            =   3

Default Policer Bucket ID                =   0x102ad
Default Policer Stats Handle             =   0x8b302f88
Policer not configured for this class

Level1 Class                             =   inet6-classifier-af4
New qos group                            =   4

Default Policer Bucket ID                =   0x102ae
Default Policer Stats Handle             =   0x8b302d38
Policer not configured for this class

Level1 Class                             =   inet6-classifier-be1
New qos group                            =   5

Default Policer Bucket ID                =   0x102af
Default Policer Stats Handle             =   0x8b302ae8
Policer not configured for this class

Level1 Class                             =   inet6-classifier-nc1
New qos group                            =   6

Default Policer Bucket ID                =   0x102b0
Default Policer Stats Handle             =   0x8b302898
Policer not configured for this class

Level1 Class                             =   inet-classifier-ipv6-af1
New qos group                            =   1

Default Policer Bucket ID                =   0x102b1
Default Policer Stats Handle             =   0x8b302648
Policer not configured for this class

Level1 Class                             =   inet-classifier-ipv6-af2
New qos group                            =   2

Default Policer Bucket ID                =   0x102b2
Default Policer Stats Handle             =   0x8b3023f8
Policer not configured for this class

Level1 Class                             =   inet-classifier-ipv6-af3
New qos group                            =   3

Default Policer Bucket ID                =   0x102b3
Default Policer Stats Handle             =   0x8b3021a8
Policer not configured for this class

Level1 Class                             =   inet-classifier-ipv6-af4
New qos group                            =   4

Default Policer Bucket ID                =   0x102b4
Default Policer Stats Handle             =   0x8b301f58
Policer not configured for this class

Level1 Class                             =   inet-classifier-ipv6-af5
New qos group                            =   5

Default Policer Bucket ID                =   0x102b5
Default Policer Stats Handle             =   0x8b301d08
Policer not configured for this class

Level1 Class                             =   inet-classifier-ipv6-af6
New qos group                            =   6

Default Policer Bucket ID                =   0x102b6
Default Policer Stats Handle             =   0x8b301ab8
Policer not configured for this class

Level1 Class                             =   inet-management-classifier-af4
New qos group                            =   7

Default Policer Bucket ID                =   0x102b7
Default Policer Stats Handle             =   0x8b301868
Policer not configured for this class

Level1 Class                             =   exp-classifier-nc1
New qos group                            =   6
New topmost exp                          =   2

Default Policer Bucket ID                =   0x102b8
Default Policer Stats Handle             =   0x8b301618
Policer not configured for this class

Level1 Class                             =   inet-management-classifier-nc1
New prec                                 =   6
New qos group                            =   5

Default Policer Bucket ID                =   0x102b9
Default Policer Stats Handle             =   0x8b3013c8
Policer not configured for this class

Level1 Class                             =   inet6-management-classifier-nc1
New qos group                            =   4

Default Policer Bucket ID                =   0x102ba
Default Policer Stats Handle             =   0x8b301178
Policer not configured for this class

Level1 Class                             =   class-default

Default Policer Bucket ID                =   0x102bb
Default Policer Stats Handle             =   0x8b3074e8
Policer not configured for this class
This is the sample output shows the QoS information on a interface hundredGigE 0/6/0/18 that are in the output direction:
RP/0/RP0/CPU0:router# show qos interface hundredGigE 0/6/0/18 output
Wed Dec  2 22:34:25.476 UTC
NOTE:- Configured values are displayed within parentheses
Interface HundredGigE0/6/0/18 ifh 0x3000210  -- output policy
NPU Id:                        3
Total number of classes:       3
Interface Bandwidth:           100000000 kbps
VOQ Base:                      11176
VOQ Stats Handle:              0x887a6e18
Accounting Type:               Layer1 (Include Layer 1 encapsulation and above)
------------------------------------------------------------------------------
Level1 Class (HP7)                       =   qos-1
Egressq Queue ID                         =   11177 (HP7 queue)
Queue Max. BW.                           =   0 kbps (default)
TailDrop Threshold                       =   125304832 bytes / 10 ms (default)
WRED not configured for this class

Level1 Class (HP6)                       =   qos-2
Egressq Queue ID                         =   11178 (HP6 queue)
Queue Max. BW.                           =   0 kbps (default)
TailDrop Threshold                       =   125304832 bytes / 10 ms (default)
WRED not configured for this class

Level1 Class                             =   class-default
Egressq Queue ID                         =   11176 (Default LP queue)
Queue Max. BW.                           =   101803495 kbps (default)
Queue Min. BW.                           =   0 kbps (default)
Inverse Weight / Weight                  =   1 / (BWR not configured)
TailDrop Threshold                       =   1253376 bytes / 10 ms (default)
WRED not configured for this class

This table describes the significant fields shown in the display.

Table 1. show QoS interface Field Descriptions

Field

Description

Level 1 class

Level 1 class identifier in decimal format.

Policer Bucket ID

Policer bucket identifier.

Policer Stats Handle

Policer statistics handle for this class.

Queue ID

VOQ number of the packet in this class.

Queue Max. BW

Maximum bandwidth of the queue.

Queue Min. BW

Minimum bandwidth of the queue.

Inverse Weight / Weight

Remaining bandwidth weight.

Note

 

The hardware weight is expressed in inverse value.

TailDrop Threshold

Number of bytes taildropped for this queue and the default/user-configured queue-limit expressed in milliseconds/user-configured unit.

The following example shows how to verify the virtual flow is configured and active.
router#show qos int hu0/0/0/25 output 
Fri May 31 16:03:46.130 UTC
NOTE:- Configured values are displayed within parentheses
Interface HundredGigE0/0/0/25 ifh 0x228  -- output policy
NPU Id:                        0
Total number of classes:       6
Interface Bandwidth:           100000000 kbps
Policy Name:                   egr
SPI Id:                        0x0
VOQ Base:                      2048
PFC enabled:                   0
Accounting Type:               Layer1 (Include Layer 1 encapsulation and above)
------------------------------------------------------------------------------
Level1 Class                             =   qos-1
Queue Max. BW.                           =   453125 kbps (450 mbits/sec)
Queue Min. BW.                           =   453125 kbps (default)
Inverse Weight / Weight                  =   1 / (BWR not configured)
Virtual Flow ID                          =   98304

   Level2 Class (HP2)                       =   ETC2
   New traffic class                        =   2
   Egressq Queue ID                         =   2050 (HP2 queue)
   Queue Max. BW.                           =   no max (default)
   Peak burst                               =   36864 bytes (default)
   TailDrop Threshold                       =   562432 bytes / 10 ms (default)

show policy-map interface

To display policy information and statistics for all classes configured for all service policies on the specified interface, use the show policy-map interface command in XR EXEC mode.

show policy-map[ interface {interface type | all} interface-path-id] [input | output ]

Syntax Description

interface type

Interface type. For more information, use the question mark (?) online help function.

all

Specifies all interfaces.

interface-path-id

Physical interface or virtual interface.

Note

 

Use the show interfaces command to see a list of all interfaces currently configured on the router.

For more information about the syntax for the router, use the question mark (?) online help function.

input

(Optional) Displays per class statistics on inbound traffic for the specified policy map and interface.

output

(Optional) Displays per class statistics on outbound traffic for the specified policy map and interface.

Command Default

None

Command Modes

XR EXEC mode

Command History

Release

Modification

Release 6.0

This command was introduced.

Release 7.1.1

The output for this command is enhanced to display the statistics for particular WRED profiles when Random Early Detection (RED) is configured on the policy-map for Cisco NCS 560 Series Routers.

Release 7.7.1

QoS support was added for classifying ingress IPv6 and IPv4 traffic based on its packet length. The command output is enhanced to display the corresponding configuration information.

Usage Guidelines

The show policy-map interface command displays the statistics for classes in the service policy attached to an interface.

The show policy-map interface command does not display the statistics and counters for the egress marking policy.

The per-class statistics for a shaper action do not reflect the Layer 1 header and the overhead bytes (if any configured) even though the shaper includes them in the rate calculation.

Task ID

Task ID

Operations

qos

read

Examples

This sample output shows how to display policy statistics information for all classes on the interface hundredGigE 0/6/0/18 that are in the input direction:

RP/0/RP0/CPU0:router# show policy-map interface hundredGigE 0/6/0/18 input

Mon Nov 30 17:10:29.065 UTC

HundredGigE0/6/0/18 input: 32-classmaps

Class exp-classifier-af1
  Classification statistics          (packets/bytes)     (rate - kbps)
    Matched             :               53186/54090162             3769
    Transmitted         :               53186/54090162             3769
    Total Dropped       :                   0/0                    0
Class exp-classifier-af2
  Classification statistics          (packets/bytes)     (rate - kbps)
    Matched             :               54279/55201743             7483
    Transmitted         :               54279/55201743             7483
    Total Dropped       :                   0/0                    0
Class exp-classifier-af3
  Classification statistics          (packets/bytes)     (rate - kbps)
    Matched             :               56710/57674070             7898
    Transmitted         :               56710/57674070             7898
    Total Dropped       :                   0/0                    0
Class exp-classifier-af4
  Classification statistics          (packets/bytes)     (rate - kbps)
    Matched             :              110405/112281885            11584
    Transmitted         :              110405/112281885            11584
    Total Dropped       :                   0/0                    0
Class exp-classifier-be1
  Classification statistics          (packets/bytes)     (rate - kbps)
    Matched             :               52753/53649801             3756
    Transmitted         :               52753/53649801             3756
    Total Dropped       :                   0/0                    0
Class inet4-classifier-af1
  Classification statistics          (packets/bytes)     (rate - kbps)
    Matched             :            38796901/14695393569          1580677
    Transmitted         :            38796901/14695393569          1580677
    Total Dropped       :                   0/0                    0
Class inet4-classifier-af2
  Classification statistics          (packets/bytes)     (rate - kbps)
    Matched             :            38850080/14715510334          1589124
    Transmitted         :            38850080/14715510334          1589124
    Total Dropped       :                   0/0                    0
Class inet4-classifier-af3
  Classification statistics          (packets/bytes)     (rate - kbps)
    Matched             :            38757080/14679867944          1580632
    Transmitted         :            38757080/14679867944          1580632
    Total Dropped       :                   0/0                    0
Class inet4-classifier-af4
  Classification statistics          (packets/bytes)     (rate - kbps)
    Matched             :            77228177/29251757855          3137985
    Transmitted         :            77228177/29251757855          3137985
    Total Dropped       :                   0/0                    0
Class inet4-classifier-be1
  Classification statistics          (packets/bytes)     (rate - kbps)
    Matched             :            38921394/14742645566          1588557
    Transmitted         :            38921394/14742645566          1588557
    Total Dropped       :                   0/0                    0
Class inet4-classifier-nc1
  Classification statistics          (packets/bytes)     (rate - kbps)
    Matched             :            77088116/29199136824          3144053
    Transmitted         :            77088116/29199136824          3144053
    Total Dropped       :                   0/0                    0
Class inet6-classifier-af1
  Classification statistics          (packets/bytes)     (rate - kbps)
    Matched             :            21953707/22326920019          1237979
    Transmitted         :            21953707/22326920019          1237979
    Total Dropped       :                   0/0                    0
Class inet6-classifier-af2
  Classification statistics          (packets/bytes)     (rate - kbps)
    Matched             :            21701336/22070258712          1208262
    Transmitted         :            21701336/22070258712          1208262
    Total Dropped       :                   0/0                    0
Class inet6-classifier-af3
  Classification statistics          (packets/bytes)     (rate - kbps)
    Matched             :            21715705/22084871985          1210060
    Transmitted         :            21715705/22084871985          1210060
    Total Dropped       :                   0/0                    0
Class inet6-classifier-af4
  Classification statistics          (packets/bytes)     (rate - kbps)
    Matched             :            43418446/44156559582          2413245
    Transmitted         :            43418446/44156559582          2413245
    Total Dropped       :                   0/0                    0
Class inet6-classifier-be1
  Classification statistics          (packets/bytes)     (rate - kbps)
    Matched             :            21958845/22332119845          1236894
    Transmitted         :            21958845/22332119845          1236894
    Total Dropped       :                   0/0                    0
Class inet6-classifier-nc1
  Classification statistics          (packets/bytes)     (rate - kbps)
    Matched             :            43428930/44167221810          2415137
    Transmitted         :            43428930/44167221810          2415137
    Total Dropped       :                   0/0                    0
Class inet-classifier-ipv6-af1
  Classification statistics          (packets/bytes)     (rate - kbps)
    Matched             :                   0/0                    0
    Transmitted         :                   0/0                    0
    Total Dropped       :                   0/0                    0
Class inet-classifier-ipv6-af2
  Classification statistics          (packets/bytes)     (rate - kbps)
    Matched             :                   0/0                    0
    Transmitted         :                   0/0                    0
    Total Dropped       :                   0/0                    0
Class inet-classifier-ipv6-af3
  Classification statistics          (packets/bytes)     (rate - kbps)
    Matched             :                   0/0                    0
    Transmitted         :                   0/0                    0
    Total Dropped       :                   0/0                    0
Class inet-classifier-ipv6-af4
  Classification statistics          (packets/bytes)     (rate - kbps)
    Matched             :                   0/0                    0
    Transmitted         :                   0/0                    0
    Total Dropped       :                   0/0                    0
Class inet-classifier-ipv6-af5
  Classification statistics          (packets/bytes)     (rate - kbps)
    Matched             :                   0/0                    0
    Transmitted         :                   0/0                    0
    Total Dropped       :                   0/0                    0
Class inet-classifier-ipv6-af6
  Classification statistics          (packets/bytes)     (rate - kbps)
    Matched             :                   0/0                    0
    Transmitted         :                   0/0                    0
    Total Dropped       :                   0/0                    0
Class inet-management-classifier-af4
  Classification statistics          (packets/bytes)     (rate - kbps)
    Matched             :                   0/0                    0
    Transmitted         :                   0/0                    0
    Total Dropped       :                   0/0                    0
Class exp-classifier-nc1
  Classification statistics          (packets/bytes)     (rate - kbps)
    Matched             :               57115/58085955             7953
    Transmitted         :               57115/58085955             7953
    Total Dropped       :                   0/0                    0
  Policing statistics                (packets/bytes)     (rate - kbps)
    Policed(conform)    :               57115/58085955             7953
    Policed(exceed)     :                   0/0                    0
    Policed(violate)    :                   0/0                    0
    Policed and dropped :                   0/0
Class class-default
  Classification statistics          (packets/bytes)     (rate - kbps)
    Matched             :                   0/0                    0
    Transmitted         :                   0/0                    0
    Total Dropped       :                   0/0                    0
This sample output shows how to display policy statistics information for all classes on the interface hundredGigE 0/6/0/0 that are in the output direction:

RP/0/RP0/CPU0:router# show policy-map interface hundredGigE 0/6/0/0 output

Wed Dec  9 16:18:10.179 UTC
HundredGigE0/6/0/0 output: test-pol-out

Class tc2
  Classification statistics          (packets/bytes)     (rate - kbps)
    Matched             :          3080542734/394309469952         4808049
    Transmitted         :          3080542734/394309469952         4808049
    Total Dropped       :                   0/0                    0
  Queueing statistics
    Queue ID                             : 1026
    Taildropped(packets/bytes)           : 0/0
    RED random drops(packets/bytes)      : 0/0
 
    WRED profile for Discard Class 0
    RED Transmitted (packets/bytes)            : 1562482674/199997782272
    RED random drops(packets/bytes)            : 0/0
    RED maxthreshold drops(packets/bytes)      : N/A
    RED ecn marked & transmitted(packets/bytes): N/A
    WRED profile for Discard Class 1
    RED Transmitted (packets/bytes)            : 0/0
    RED random drops(packets/bytes)            : 0/0
    RED maxthreshold drops(packets/bytes)      : N/A
    RED ecn marked & transmitted(packets/bytes): N/A
    WRED profile for Discard Class 2
    RED Transmitted (packets/bytes)            : 1518060060/194311687680
    RED random drops(packets/bytes)            : 0/0
    RED maxthreshold drops(packets/bytes)      : N/A
    RED ecn marked & transmitted(packets/bytes): N/A
Class tc1
  Classification statistics          (packets/bytes)     (rate - kbps)
    Matched             :          1562482674/199997782272         2883014
    Transmitted         :          1434402692/183603544576         2646687
    Total Dropped       :           128079982/16394237696          236327
  Queueing statistics
    Queue ID                             : 1025
    Taildropped(packets/bytes)           : 128079982/16394237696
    RED random drops(packets/bytes)      : 0/0
 
    WRED profile for Discard Class 1
    RED Transmitted (packets/bytes)            : 1434402692/183603544576
    RED random drops(packets/bytes)            : 128079982/16394237696
    RED maxthreshold drops(packets/bytes)      : N/A
    RED ecn marked & transmitted(packets/bytes): N/A
Class class-default
  Classification statistics          (packets/bytes)     (rate - kbps)
    Matched             :                   0/0                    0
    Transmitted         :                   0/0                    0
    Total Dropped       :                   0/0                    0
  Queueing statistics
    Queue ID                             : 1024
    Taildropped(packets/bytes)           : 0/0
Policy Bag Stats time: 1557231345776  [Local Time: 05/07/19 12:15:45.776]

Note


Statistics for WRED profiles are displayed when Random Early Detection (RED) is configured on the policy-map for Cisco NCS 560 Series Routers.


This table describes the significant fields shown in the display.

Table 2. show policy-map interface Field Descriptions

Field

Description

Classification statistics

Matched

Number of packets or bytes that matched this class.

Transmitted

Number of packets or bytes transmitted for this class.

Total Dropped

Number of packets or bytes dropped for this class.

Policing statistics

Policed(conform)

Number of packets or bytes that conformed to the police rate for this class.

Policed(exceed)

Number of packets or bytes that exceeded the police rate for this class.

Policed(violate)

Number of packets or bytes that violated the police rate for this class.

Policed and dropped

Number of packets or bytes dropped by the policer of this class.

Queuing statistics

Queue ID

VOQ number of the packet in this class.

Taildropped (bytes)

Number of bytes taildropped for this queue.

This sample output displays policy information for the QoS Classification Based on Packet Length feature. With this feature, you can add an ingress QoS policy on an ACL that filters IPv6 and IPv4 traffic based on its packet length. The ACL specifies packet length criteria such as equal to, lesser than, greater than, and so on, and the QoS policy specifies the forwarding decision. The ACL provides an additional QoS match criteria for IP traffic, enhancing the overall network security.

Router# show policy-map interface hundredGigE 0/0/0/0 input 

HundredGigE0/0/0/0 input: p_pktlen

Class c_pktlen
  Classification statistics          (packets/bytes)     (rate - kbps)
    Matched             :             53186/54090162         3769
    Transmitted         :             53186/54090162         3769
    Total Dropped       :                   0/0                    0

Class class-default
  Classification statistics          (packets/bytes)     (rate - kbps)
    Matched             :                   0/0                    0
    Transmitted         :                   0/0                    0
    Total Dropped       :                   0/0                    0

Policy Bag Stats time: 1657119549887  [Local Time: 07/06/22 14:59:09.887]

show policy-map targets

To display information about the interfaces on which policy maps are applied, use the show policy-map targets command in XR EXEC mode.

show policy-map targets [location node-id | pmap-name name | type qos [location node-id | pmap-name name]]

Syntax Description

location node-id

(Optional) Displays information about the interfaces on which policy maps are applied for the specified location. The node-id argument is entered in the rack/slot/module notation.

pmap-name name

(Optional) Displays information about the interfaces on which the specified policy map is applied.

type qos

(Optional) Displays information about the interfaces on which QoS policy maps are applied. This is the default type.

Command Default

The default QoS policy type is QoS.

Command Modes

XR EXEC mode

Command History

Release

Modification

Release 6.0

This command was introduced.

Usage Guidelines

For a short period of time while a QoS policy is being modified, there might not be any policy in effect on the interfaces in which the modified policy is used. For this reason, modify QoS policies that affect the fewest number of interfaces at a time. Use the show policy-map targets command to identify the number of interfaces that will be affected during policy map modification.

Task ID

Task ID

Operations

qos

read

Examples

In this example, the TenGigabit Ethernet interface 4/0/10/0 has one policy map attached as a main policy. Outgoing traffic on this interface will be affected if the policy is modified:
RP/0/RP0/CPU0:router# show policy-map targets

Wed Dec  2 22:35:13.993 UTC
1) Policymap: test-qlimit    Type: qos
     Targets (applied as main policy):
       TenGigE0/4/0/10/0 output
       TenGigE0/6/0/30/1 output
     Total targets: 2

     Targets (applied as child policy):
     Total targets: 0


2) Policymap: test-priority    Type: qos
     Targets (applied as main policy):
       HundredGigE0/6/0/35 output
       HundredGigE0/6/0/34 output
       HundredGigE0/6/0/33 output
       HundredGigE0/6/0/32 output
       HundredGigE0/6/0/31 output
       HundredGigE0/6/0/29 output
       HundredGigE0/6/0/28 output
       HundredGigE0/6/0/27 output
       HundredGigE0/6/0/25 output
       HundredGigE0/6/0/24 output
       HundredGigE0/6/0/23 output
       HundredGigE0/6/0/22 output
       HundredGigE0/6/0/21 output
       HundredGigE0/6/0/20 output
       HundredGigE0/6/0/19 output
       HundredGigE0/6/0/1 output
       HundredGigE0/6/0/3 output
       HundredGigE0/6/0/4 output
       HundredGigE0/6/0/5 output
       HundredGigE0/6/0/6 output
       HundredGigE0/6/0/7 output
       HundredGigE0/6/0/8 output
       HundredGigE0/6/0/9 output
       HundredGigE0/6/0/10 output
       HundredGigE0/6/0/11 output
       HundredGigE0/6/0/13 output
       HundredGigE0/6/0/14 output
       HundredGigE0/6/0/15 output
       HundredGigE0/6/0/16 output
       HundredGigE0/6/0/17 output
     Total targets: 30

     Targets (applied as child policy):
     Total targets: 0

show policy-map type pbr

To view details of the configured PBR policy and related statistics, use the show policy-map type pbr vrf vrf-name addr-family ipv4 statistics command in XR EXEC mode.

show policy-map type pbr vrf vrf-name addr-family {ipv4 | ipv6 } statistics

Syntax Description

vrf vrf-name

Sets the VRF name.

Command Default

No default action.

Command Modes

XR EXEC mode

Command History

Release

Modification

Release 6.0.1

This command was introduced.

Usage Guidelines

This command applies only to the incoming IPv4 packets only.

Task ID

Task ID

Operations

qos

read

Examples

This example shows how to view details of the configured PBR policy and related statistics:


/* Configuring a VRF */
RP/0/RP0/CPU0:router(config)# vrf gre-vrf address-family ipv4 unicast
...
/* Configuring a policy */
RP/0/RP0/CPU0:router(config)# policy-map type pbr gre-policy
...
/* Applying the policy on the VRF */
RP/0/RP0/CPU0:router(config)# vrf-policy vrf gre-vrf address-family ipv4 policy type pbr input gre-policy

/* Displaying policy details and statistics */
RP/0/RP0/CPU0:router# show policy-map type pbr vrf gre-vrf addr-family ipv4 policy type pbr input gre-policy