The documentation set for this product strives to use bias-free language. For the purposes of this documentation set, bias-free is defined as language that does not imply discrimination based on age, disability, gender, racial identity, ethnic identity, sexual orientation, socioeconomic status, and intersectionality. Exceptions may be present in the documentation due to language that is hardcoded in the user interfaces of the product software, language used based on RFP documentation, or language that is used by a referenced third-party product. Learn more about how Cisco is using Inclusive Language.
To copy a system-defined network-qos policy and modify it for use, use the qos copy policy-map command.
qos copy policy-map type { network-qos [ default-nq-4e-policy { prefix prefix | suffix suffix } | default-nq-6e-policy { prefix prefix | suffix suffix } | default-nq-7e-policy { prefix prefix | suffix suffix } | default-nq-8e-policy { prefix prefix | suffix suffix } ] | queuing [ default-4q-4e-in-policy { prefix prefix | suffix suffix } | default-4q-4e-out-policy { prefix prefix | suffix suffix } ] }
type |
Specifies the component type. |
network-qos |
Specifies a network qos policy. |
default-nq-4e-policy |
(Optional) Specifies the 4-Ethernet template. |
prefix prefix |
Specifies a prefix for the policy name. A prefix can be any alphanumeric character string. |
suffix suffix |
Specifies a suffix for the policy name. A prefix can be any alphanumeric character string. |
default-nq-6e-policy |
(Optional) Specifies the 6-Ethernet template. |
default-nq-7e-policy |
(Optional) Specifies the 7-Ethernet template. |
default-nq-8e-policy |
(Optional) Specifies the 8-Ethernet template. |
queuing |
(Optional) Specifies a queuing policy. |
default-4q-4e-in-policy |
(Optional) Specifies the default 4-Ethernet input queuing policy. |
default-4q-4e-out-policy |
(Optional) Specifies the default 4-Ethernet output queuing policy. |
None
Global configuration
Release |
Modification |
---|---|
5.1(1) |
This command was introduced. |
This command does not require a license.
This example shows how to copy a system-defined network qos policy and modify it for use:
switch# configure terminal switch(config)# qos copy policy-map type network-qos default-nq-4e-policy prefix my_ switch(config)#
Command |
Description |
---|---|
policy-map type network-qos |
Configure a policy map and enter the policy map type network qos configuration mode. |
To change the default shared buffer queue limit ratio (which is 50:50 shared:dedicated) for a specified port group, use the qos shared-buffer queue-limit command. To return to the default queue limit ratio, use the no form of this command.
qos shared-buffer queue limit percent
no qos shared-buffer queue limit percent
percent |
Sets the percent of the queue limit ratio that is shared on the port group. |
None.
Port-group configuration
Release |
Modification |
---|---|
6.2(10) |
This command was introduced. |
This command does not require a license.
You must first enable shared buffer queuing for the entire module. When enabled, the default ratio is 50:50. You must enter this command separately for each port group on which you want to change the queue limit ratio.
Note | This command is available only on F3 Series modules. |
This example shows how to configure port group 3 on module 1 for a 60-percent shared buffer queue. (This moves the dedicated queue to 40 percent for the port group.):
switch(config-port-group)# qos shared-buffer queue-limit 60 switch(config-port-group)#
Command |
Description |
---|---|
show running-config |
Displays the running configuration. |
To configure simultaneous policing of the data rates for a particular class of traffic across multiple interfaces, use the qos shared-policer command. To remove a shared policer configuration, use the no form of this command.
qos shared-policer [ type qos ] policer-name [cir] { cir-value [ bps | kbps | mbps | gbps ] | percent - percent } | [ [bc] bc-value [ bytes | kbytes | mbytes | ms | us ] ] | [ pir { pir-value [ bps | kbps | mbps | gbps ] | percent percent } [ [be] be-value [ bytes | kbytes | mbytes | ms | us ] ] ] | [ conform { transmit | set-prec-transmit precedence-value | set-dscp-transmit dscp-value | set-cos-transmit cos-val | set-discard-class-transmit discard-class-value | set-qos-transmit qos-group-value } [ exceed { drop | set dscp dscp table cir-markdown-map } ] [ violate { drop | set dscp dscp table pir-markdown-map } ] ]
no qos shared-policer [ type qos ] policer-name
type qos |
(Optional) Specifies the component type, which is quality of service (QoS) for this class. |
policer-name |
Name of a shared policer. |
cir |
(Optional) Sets the committed information rate as a bit rate or a percentage of the link rate. |
cir-value |
Committed information rate. Valid values are from 1 to 80000000000; the range of policing values that are mathematically significant is 8000 to 80 Gbps. |
bps |
(Optional) Specifies the units of bits per second. |
kbps |
(Optional) Specifies the units of kilobits per second. |
mbps |
(Optional) Specifies the units of megabits per second. |
gbps |
(Optional) Specifies the units of gigabits per second. |
percent |
Specifies the percentage of the related parameter. |
percent |
Specifies percent. Valid values are from 1 to 100. |
bc |
Sets the committed burst rate, which is how much the cir can be exceeded, either as a bit rate or an amount of time at cir. |
bc-value |
Committed burst rate. Valid values are from 1 to 536870912. The default value is 200. |
bytes |
(Optional) Specifies the units of bytes per second. |
kbytes |
(Optional) Specifies the units of kilobytes per second. |
mbytes |
(Optional) Specifies the units of megabytes per second. |
ms |
(Optional) Specifies the units of milliseconds. |
us |
(Optional) Specifies the units of microseconds. |
pir |
Sets the peak information rate. |
pir-value |
Peak information rate. Valid values are from 1 to 80000000000; the range of policing values that are mathematically significant is from 8000 to 80 Gbps. |
be |
Specifies the extended burst rate. Valid values are from 1 to 536870912. |
be-value |
Extended burst rate. If the bc value is not specified, the default is 200 milliseconds of traffic at the configured rate. The default data rate units are bytes. |
conform |
Sets the action to take when the data rate is within bounds. |
transmit |
Specifies the action of transmitting packets. |
set-prec-transmit precedence-value |
Sets the IP precedence field to the specified value and transmits the packet. Valid values are from 0 to 7. |
set-dscp-transmit dscp-value |
Sets the Differentiated Services Code Point (DSCP) field to the specified value and transmits the packet. |
set-cos-transmit cos-val |
Sets the class of service (CoS) field to the specified value and transmits the packet. Valid values are from 0 to 7. |
set-discard-class-transmit discard-class-value |
Sets the discard class field to the specified value and transmits the packet. Valid values are from 0 to 63. |
set-qos-transmit qos-group-value |
Sets the qos group field to the specified value and transmits the packet. Valid values are from 1 to 126. |
exceed |
Sets the action to take when the data rate is exceeded. The default is drop. |
drop |
Specifies the action of dropping packets. |
set dscp dscp table cir-markdown-map |
Sets the DSCP field to the corresponding value in the system-defined table map and transmits the packet. |
violate |
Sets the action to take when the data rate violates the configured rate values. The default is drop. |
set dscp dscp table pir-markdown-map |
Sets the DSCP field to the corresponding value in the system-defined table map and transmits the packet. |
type default value is qos.
bc default value is 200 milliseconds of traffic at the configured rate. The default data rate units are bytes.
be default value is 200 milliseconds of traffic at the configured rate. The default data rate units are bytes.
exceed default action is drop.
violate default action is drop.
Global configuration
Release |
Modification |
---|---|
4.0 |
This command was introduced. |
The interfaces that are attached to the shared policer must be on the same module. For an example of using a shared policer, see the police aggregate command.
This command does not require a license.
This example shows configuration of a 2-rate, 3-color shared policer that transmits and sets CoS to 5 if the data rate is within 200 milliseconds of traffic at 256000 bps, marks DSCP based on the system-defined table map cir-markdown-map if the data rate exceeds 200 milliseconds of traffic at 512 bps, and drops packets otherwise:
switch(config)# qos shared-policer my_shared_policer cir 256000 pir 512000 conform set-cos-transmit 5 exceed set dscp dscp table cir-markdown-map violate drop switch(config)#
Command |
Description |
---|---|
police aggregate |
Configures simultaneous policing of the data rates for a particular class of traffic across multiple interfaces. |
show policy-map |
Displays policy maps and statistics. |
To enable Quality of Service (QoS) statistics, use the qos statistics command. To disable QoS statistics, use the no form of this command.
qos statistics
no qos statistics
This command has no arguments or keywords.
Enabled
Global configuration
Release |
Modification |
---|---|
4.0 |
This command was introduced. |
This command does not require a license.
This example shows how to enable QoS statistics:
switch(config)# qos statistics switch(config)#
This example shows how to disable QoS statistics:
switch(config)# no qos statistics switch(config)#
Command |
Description |
---|---|
show policy-map |
Displays policy maps and statistics. |
To configure tail drop by setting queue limits on both ingress and egress queues, use the queue-limit command. To remove a queue limit, use the no form of this command.
queue-limit { cos cos-value [ packets | bytes | kbytes | mbytes | ms | us ] | percent percent-queue-size }
no queue-limit { cos cos-value [ packets | bytes | kbytes | mbytes | ms | us ] | percent percent-queue-size }
cos cos-value |
Applies the queue limit to packets with the specified CoS value. Valid values are from 0 to 7. |
packets |
(Optional) Specifies that queue size is in packets. If not specified, packets is the default units. |
bytes |
(Optional) Specifies that the queue size is in bytes. |
kbytes |
(Optional) Specifies that the queue size is in kilobytes. |
mbytes |
(Optional) Specifies that the queue size is in megabytes. |
ms |
(Optional) Specifies that the queue size is in milliseconds at the underlying interface minimum guaranteed link rate. |
us |
(Optional) Specifies that queue size is in microseconds at the underlying interface minimum guaranteed link rate. |
percent |
(Optional) Specifies the percentage of queue limit. |
percent-queue-size |
(Optional) Specifies the percentage of the buffer memory used by the queue. Valid values are from 1 to 100. |
queue-size is in packets by default.
Policy map type queuing class configuration
Release |
Modification |
---|---|
5.1(1) |
Modified the queue-limit command to include Tail drop threshold. |
4.0 |
This command was introduced. |
The system drops packets that exceed the configured queue-size threshold.
By default, the queue limit is applied to all packets with a class of service (CoS) value that is not assigned a queue limit.
The queue limit is not supported on ingress policies on the Cisco Nexus 7000 M1-Series 32-Port 10Gb Ethernet modules (N7K-M132XP-12 and N7K-M132XP-12L).
Tail drop and weighted random early detection (WRED) cannot be configured in the same class. For information about configuring WRED, see the random-detect command.
This command does not require a license.
This example shows how to assign a queue limit to a policy map queuing class that applies only to the specified CoS value:
switch(config)# policy-map type queuing match-first my_queue switch(config-pmap-que)# class type queuing 1p3q4t-out-pq1 switch(config-pmap-c-que)# queue-limit cos 3 10 mbytes switch(config-pmap-c-que)#
This example shows how to remove a queue limit from a policy map queuing class:
switch(config)# policy-map type queuing match-first my_queue switch(config-pmap-que)# class type queuing 1p3q4t-out-pq1 switch(config-pmap-c-que)# no queue-limit cos 3 10 mbytes switch(config-pmap-c-que)#
Command |
Description |
---|---|
random-detect |
Configures weighted random early detection (WRED). |
show policy-map |
Displays policy maps and statistics. |
To configure queue size on both ingress and egress queues, use the queue-limit command. To remove a queue limit, use the no form of this command.
queue-limit { queue-size [ packets | bytes | kbytes | mbytes | ms | us ] | percent percent-queue-size }
no queue-limit { queue-size [ packets | bytes | kbytes | mbytes | ms | us ] | percent percent-queue-size }
queue-size |
Queue size. Valid values are from 1 to 83886080. |
packets |
(Optional) Specifies that queue size is in packets. If not specified, packets is the default units. |
bytes |
(Optional) Specifies that the queue size is in bytes. |
kbytes |
(Optional) Specifies that the queue size is in kilobytes. |
mbytes |
(Optional) Specifies that the queue size is in megabytes. |
ms |
(Optional) Specifies that the queue size is in milliseconds at the underlying interface minimum guaranteed link rate. |
us |
(Optional) Specifies that queue size is in microseconds at the underlying interface minimum guaranteed link rate. |
percent |
(Optional) Specifies the percentage of queue limit. |
percent-queue-size |
(Optional) Specifies the percentage of the buffer memory used by the queue. Valid values are from 1 to 100. |
queue-size is in packets by default.
Policy map type queuing class configuration
Release |
Modification |
---|---|
5.1(1) |
Modified the queue-limit command to include queue size. |
4.0 |
This command was introduced. |
The system drops packets that exceed the configured queue-size threshold.
By default, the queue limit is applied to all packets with a class of service (CoS) value that is not assigned a queue limit.
The queue limit is not supported on ingress policies on the Cisco Nexus 7000 M1-Series 32-Port 10Gb Ethernet modules (N7K-M132XP-12 and N7K-M132XP-12L).
Tail drop and weighted random early detection (WRED) cannot be configured in the same class. For information about configuring WRED, see the random-detect command.
This command does not require a license.
This example shows how to assign a queue limit to a policy map queuing class that applies only to the specified CoS value:
switch(config)# policy-map type queuing match-first my_queue switch(config-pmap-que)# class type queuing 1p3q4t-out-pq1 switch(config-pmap-c-que)# queue-limit cos 3 10 mbytes switch(config-pmap-c-que)#
This example shows how to remove a queue limit from a policy map queuing class:
switch(config)# policy-map type queuing match-first my_queue switch(config-pmap-que)# class type queuing 1p3q4t-out-pq1 switch(config-pmap-c-que)# no queue-limit cos 3 10 mbytes switch(config-pmap-c-que)#
Command |
Description |
---|---|
random-detect |
Configures weighted random early detection (WRED). |
show policy-map |
Displays policy maps and statistics. |