Skip to content

Queuing

QoS queuing configuration (type queuing) controls egress scheduling on NX-OS devices. Queuing policy maps reference the system-defined queuing classes (for example c-out-q1 to c-out-q-default) and assign strict priority levels, bandwidth and remaining bandwidth percentages, minimum/maximum shaping rates, queue limits and congestion avoidance (WRED/ECN random-detect or Approximate Fair Discard afd) to each queue. A queuing policy can be applied system-wide as the output service policy, with optional statistics collection. Traffic is mapped to queues based on the QoS groups set by QoS classification policies.

Diagram
NameTypeConstraintMandatoryDefault Value
devicesListdevicesNo
device_groupsListdevice_groupsNo
globalClassglobalNo
templatesListtemplatesNo

NameTypeConstraintMandatoryDefault Value
configurationClassconfigurationNo

NameTypeConstraintMandatoryDefault Value
configurationClassconfigurationNo

NameTypeConstraintMandatoryDefault Value
configurationClassconfigurationNo

NameTypeConstraintMandatoryDefault Value
configurationClassconfigurationNo

NameTypeConstraintMandatoryDefault Value
qosClassqosNo

NameTypeConstraintMandatoryDefault Value
queuing_policy_mapsListqueuing_policy_mapsNo
system_service_policy_queuing_outputStringNo
system_service_policy_queuing_output_statisticsBooleantrue, falseNo

queuing_policy_maps (nxos.devices.configuration.qos)

Section titled “queuing_policy_maps (nxos.devices.configuration.qos)”
NameTypeConstraintMandatoryDefault Value
nameStringYes
match_typeChoicematch-any, match-all, match-firstNo
classesListclassesNo

classes (nxos.devices.configuration.qos.queuing_policy_maps)

Section titled “classes (nxos.devices.configuration.qos.queuing_policy_maps)”
NameTypeConstraintMandatoryDefault Value
nameStringYes
priority_levelIntegermin: 1, max: 8No
bandwidth_percentIntegermin: 0, max: 100No
bandwidth_remaining_percentIntegermin: 0, max: 100No
shape_minIntegermin: 0, max: 400000000000No
shape_min_unitChoicebps, kbps, mbps, gbps, pps, percentNo
shape_maxIntegermin: 0, max: 400000000000No
shape_max_unitChoicebps, kbps, mbps, gbps, pps, percentNo
queue_limitIntegermin: 0, max: 12582913No
queue_limit_unitChoicebytes, kbytes, mbytesNo
queue_limit_dynamicIntegermin: 0, max: 10No
random_detectClassrandom_detectNo
afdClassafdNo

random_detect (nxos.devices.configuration.qos.queuing_policy_maps.classes)

Section titled “random_detect (nxos.devices.configuration.qos.queuing_policy_maps.classes)”
NameTypeConstraintMandatoryDefault Value
minimum_thresholdIntegermin: 0, max: 52428800No
minimum_threshold_unitChoicepackets, bytes, kbytes, mbytesNo
maximum_thresholdIntegermin: 0, max: 52428800No
maximum_threshold_unitChoicepackets, bytes, kbytes, mbytesNo
drop_probabilityIntegermin: 0, max: 100No
weightIntegermin: 0, max: 15No
cap_averageBooleantrue, falseNo
thresholdChoiceburst-optimized, mesh-optimizedNo
ecnBooleantrue, falseNo

afd (nxos.devices.configuration.qos.queuing_policy_maps.classes)

Section titled “afd (nxos.devices.configuration.qos.queuing_policy_maps.classes)”
NameTypeConstraintMandatoryDefault Value
queue_desiredIntegermin: 1, max: 52428800No
queue_desired_unitChoicebytes, kbytes, mbytesNo
ecnBooleantrue, falseNo

Example 1: Egress queuing policy with priority and bandwidth remaining allocation, applied system-wide

nxos:
devices:
- name: SPINE1
configuration:
qos:
system_service_policy_queuing_output: QM-FABRIC-EGRESS
system_service_policy_queuing_output_statistics: true
queuing_policy_maps:
- name: QM-FABRIC-EGRESS
match_type: match-first
classes:
- name: c-out-q1
priority_level: 1
- name: c-out-q2
bandwidth_remaining_percent: 30
- name: c-out-q-default
bandwidth_remaining_percent: 70

Example 2: Egress queuing policy with WRED/ECN congestion avoidance

nxos:
devices:
- name: LEAF1
configuration:
qos:
system_service_policy_queuing_output: QM-WRED-EGRESS
queuing_policy_maps:
- name: QM-WRED-EGRESS
classes:
- name: c-out-q1
priority_level: 1
- name: c-out-q2
bandwidth_remaining_percent: 50
random_detect:
minimum_threshold: 150
minimum_threshold_unit: kbytes
maximum_threshold: 3000
maximum_threshold_unit: kbytes
drop_probability: 7
weight: 5
cap_average: true
ecn: true
- name: c-out-q-default
bandwidth_remaining_percent: 50
random_detect:
threshold: mesh-optimized
ecn: true

Example 3: Egress queuing policy applied to individual Ethernet and port-channel interfaces

nxos:
devices:
- name: LEAF1
configuration:
qos:
queuing_policy_maps:
- name: QM-UPLINK-EGRESS
classes:
- name: c-out-q3
priority_level: 1
- name: c-out-q2
bandwidth_remaining_percent: 40
- name: c-out-q1
bandwidth_remaining_percent: 30
- name: c-out-q-default
bandwidth_remaining_percent: 30
interfaces:
ethernets:
- id: 1/49
service_policy_type_queuing_output: QM-UPLINK-EGRESS
service_policy_type_queuing_output_statistics: true
port_channels:
- id: 10
service_policy_type_queuing_output: QM-UPLINK-EGRESS

Example 4: Egress queuing policy with guaranteed bandwidth, shaping and queue limits

nxos:
devices:
- name: LEAF1
configuration:
qos:
system_service_policy_queuing_output: QM-SHAPED-EGRESS
queuing_policy_maps:
- name: QM-SHAPED-EGRESS
classes:
- name: c-out-q1
bandwidth_percent: 20
shape_min: 1000
shape_min_unit: mbps
shape_max: 2000
shape_max_unit: mbps
queue_limit: 1000
queue_limit_unit: kbytes
- name: c-out-q-default
bandwidth_percent: 80
queue_limit_dynamic: 5