OcNOS-DC : Quality of Service Guide : Quality of Service Configuration Guide : Scheduling Configuration
Scheduling Configuration
This chapter contains a complete sample of configuring weight, strict priority on queues and weight between uc and mc queue.
Topology
Simple configuration of Priority
Configuring Weight on L2 /L3 Interface
 
#configure terminal
Enter configure mode.
(config)#qos enable
Enable QoS globally.
(config)#qos statistics
Enable QoS statistics.
(config)#policy-map type queuing default default-out-policy
Enter policy-map type queueing default.
(config-pmap-que-def)#class type queuing default q0
Enter policy-class-map mode.
(config-pmap-c-que-def)#wrr-queue weight 2
Modify strict queue to wrr-queue with weight 2.
(config-pmap-c-que-def)#exit
Exit from policy-class-map mode.
(config-pmap-que-def)#exit
Exit from policy-map mode.
(config)#exit
Exit configure mode.
Validation
Enter the commands listed in the sections below to confirm the configurations.
#show policy-map type queuing
 
Type queuing policy-maps
========================
 
policy-map type queuing default default-out-policy
class type queuing default q0
wrr-queue weight 2
class type queuing default q1
priority
class type queuing default q2
priority
class type queuing default q3
priority
class type queuing default q4
priority
class type queuing default q5
priority
class type queuing default q6
priority
class type queuing default q7
priority
 
Configuring Strict priority on L2 /L3 Interface
#configure terminal
Enter configure mode.
(config)#qos enable
Enable QoS globally.
(config)#qos statistics
Enable QoS statistics.
(config)#policy-map type queuing default p3
Enter policy-map type queueing default.
(config-pmap-que-def)#class type queuing default q0
Enter policy-class-map mode.
(config-pmap-c-que-def)#priority
Configure priority for q0.
(config-pmap-c-que-def)#exit
Exit from policy-class-map mode.
(config-pmap-que-def)#exit
Exit from policy-map mode.
(config)#interface xe2
Enter interface mode.
(config-if)#service-policy type queuing output p3
Attach policy-map of type queuing on egress interface
(config)#exit
Exit configure mode.
Validation
Enter the commands listed in the sections below to confirm the configurations.
# show running-config qos
qos enable
qos statistics
!
!
policy-map type queuing default p3
class type queuing default q0
priority
exit
!
interface xe2
service-policy type queuing output p3
!
 
# show policy-map type queuing
 
Type queuing policy-maps
========================
 
policy-map type queuing default default-out-policy
class type queuing default q0
priority
class type queuing default q1
priority
class type queuing default q2
priority
class type queuing default q3
priority
class type queuing default q4
priority
class type queuing default q5
priority
class type queuing default q6
priority
class type queuing default q7
priority
 
policy-map type queuing default p3
class type queuing default q0
priority
class type queuing default q1
priority
class type queuing default q2
priority
class type queuing default q3
priority
class type queuing default q4
priority
class type queuing default q5
priority
class type queuing default q6
priority
class type queuing default q7
priority
 
OcNOS#
Configuring weight between unicast and multicast queues
Use the following configuration to set weights between unicast and multicast traffic of same traffic class.
#configure terminal
Enter configure mode.
(config)#qos enable
Enable QoS globally.
(config)#qos statistics
Enable QoS statistics.
(config)# set qos wrr uc 3 non-uc 1
Schedule unicast and multicast traffic in 3:1
(config)#exit
Exit configure mode.
Note: Unicast weight should be always higher than multicast weight (except on Trident+ platforms). Between unicast and multicast traffic of different traffic class, scheduling will be as per configuration given in the queuing policy-map attached on the interface.

This hardware limitation is for Trident3 platform which is scheduled between unicast and multicast that requires the unicast weight to be higher than the multicast queues weights.
Validation
Enter the commands listed in the sections below to confirm the configurations.
#sh run qos
qos enable
qos statistics
set qos wrr uc 3 non-uc 1
!
 
#show int cou queue-stats
E - Egress, I - Ingress, Q-Size is in bytes
* indicates monitor is active
+-------------+--------------------+--------+-----------------+-------------------+-----------------+-------------------+
| Interface | Queue/Class-map | Q-Size | Tx pkts | Tx bytes | Dropped pkts | Dropped bytes |
+-------------+--------------------+--------+-----------------+-------------------+-----------------+-------------------+
ce1/1 q1 (E) 373152 1256 1256000 15245 15241000
ce1/1 mc-q1 (E) 92352 418 418000 16048 16045000
ce24/1 pg-q0 (I) 419536 NA NA NA NA
ce24/1 pg-q1 (I) 468000 NA NA NA NA
 
Validation
Enter the commands listed in the sections below to confirm the configurations.
#show policy-map type queuing default default-out-policy Type queuing policy-maps
========================
 
policy-map type queuing default default-out-policy class type queuing default q0
wrr-queue weight 2
bandwidth percent 1 exit
class type queuing default q1 priority level 1
bandwidth percent 1 exit
class type queuing default q2 priority level 1
 
bandwidth percent 1 exit
class type queuing default q3 priority level 1
bandwidth percent 1 exit
class type queuing default q4 priority level 1
bandwidth percent 1 exit
class type queuing default q5 priority level 1
bandwidth percent 1 exit
class type queuing default q6 priority level 1
bandwidth percent 1 exit
class type queuing default q7 priority level 1
bandwidth percent 1 exit
 
 
#show queuing interface xe2
 
Egress Queuing for Ethernet xe2 [System]
 
L0 L1 L2 Group PrioLevel Shape Bandwidth
 
q0 - - -
-
q1 - High -
-
q2 - High -
-
q3 - High -
-
q4 - High -
-
q5 - High -
-
q6 - High -
-
q7 - High -
-
#
 
Note: Unicast weight should be always higher than multicast weight. Between unicast and multicast traffic of different traffic class, scheduling will be as per configuration given in the queueing policy-map attached on the interface.
#configure terminal
Enter configure mode.
(config)#qos enable
Enable QoS globally.
(config)#qos statistics
Enable QoS statistics.
(config)# set qos wrr uc 1 non-uc 1
Schedule unicast and multicast traffic in 1:1
(config)#exit
Exit configure mode.
Validation
Enter the commands listed in the sections below to confirm the configurations.
#show running-configuration qos
qos enable
qos statistics
set qos wrr uc 1 non-uc 1
!
 
#show policy-map
 
Type queuing policy-maps
========================
 
policy-map type queuing default default-out-policy
class type queuing default q0
priority
class type queuing default q1
priority
class type queuing default q2
priority
class type queuing default q3
priority
class type queuing default q4
priority
class type queuing default q5
priority
class type queuing default q6
priority
class type queuing default q7
priority
#show interface counters queue-stats
E - Egress, I - Ingress, Q-Size is in bytes
* indicates monitor is active
+-------------+--------------------+--------+-----------------+-------------------+-----------------+-------------------+
| Interface | Queue/Class-map | Q-Size | Tx pkts | Tx bytes | Dropped pkts | Dropped bytes |
+-------------+--------------------+--------+-----------------+-------------------+-----------------+-------------------+
cpu bpdu (E) 0 1 68 0 0
ce1/1 q1 (E) 424320 0 0 16817 16814000
ce1/1 q7 (E) 0 1 64 0 0
ce1/1 mc-q2 (E) 102336 1710 1710000 15059 15055000
ce24/1 q7 (E) 0 1 64 0 0
ce24/1 pg-q1 (I) 509600 NA NA NA NA
ce24/1 pg-q2 (I) 103584 NA NA NA NA
By default, default-out-policy with priority on all queues is applied on ce1/1, hence receiving only q2 multicast traffic
 
#show interface counters queue-stats
E - Egress, I - Ingress, Q-Size is in bytes
* indicates monitor is active
+-------------+--------------------+--------+-----------------+-------------------+-----------------+-------------------+
| Interface | Queue/Class-map | Q-Size | Tx pkts | Tx bytes | Dropped pkts | Dropped bytes |
+-------------+--------------------+--------+-----------------+-------------------+-----------------+-------------------+
cpu bpdu (E) 0 1 68 0 0
ce1/1 q1 (E) 424320 816 816000 15279 15276000
ce1/1 q7 (E) 0 1 64 0 0
ce1/1 mc-q1 (E) 106080 816 816000 15229 15226000
ce24/1 q7 (E) 0 1 64 0 0
ce24/1 pg-q1 (I) 513344 NA NA NA NA
 
#configure terminal
Enter configure mode.
(config)#qos enable
Enable QoS globally.
(config)#qos statistics
Enable QoS statistics.
(config)#policy-map type queuing default default-out-policy
Enter policy-map type queueing default.
(config-pmap-que-def)#class type queuing default q0
Enter policy-class-map mode.
(config-pmap-c-que-def)#wrr-queue weight 2
Modify strict queue to wrr-queue with weight 2.
(config-pmap-c-que-def)# class type queuing default q1
 
(config-pmap-c-que-def)# wrr-queue weight 2
 
(config-pmap-c-que-def)# class type queuing default q2
 
(config-pmap-c-que-def)#wrr-queue weight 4
 
(config-pmap-c-que-def)#exit
Exit from policy-class-map mode.
(config-pmap-que-def)#exit
Exit from policy-map mode.
(config)#exit
Exit configure mode.
 
Validation
#show policy-map
 
Type queuing policy-maps
========================
 
policy-map type queuing default default-out-policy
class type queuing default q0
wrr-queue weight 2
class type queuing default q1
wrr-queue weight 2
class type queuing default q2
wrr-queue weight 4
class type queuing default q3
priority
class type queuing default q4
priority
class type queuing default q5
priority
class type queuing default q6
priority
class type queuing default q7
priority
 
#show interface counters queue-stats
E - Egress, I - Ingress, Q-Size is in bytes
* indicates monitor is active
+-------------+--------------------+--------+-----------------+-------------------+-----------------+-------------------+
| Interface | Queue/Class-map | Q-Size | Tx pkts | Tx bytes | Dropped pkts | Dropped bytes |
+-------------+--------------------+--------+-----------------+-------------------+-----------------+-------------------+
cpu bpdu (E) 0 1 68 0 0
ce1/1 q1 (E) 421824 312 312000 8957 8954000
ce1/1 q7 (E) 0 1 64 0 0
ce1/1 mc-q2 (E) 106080 624 624000 8607 8592000
ce24/1 q7 (E) 0 1 64 0 0
ce24/1 pg-q1 (I) 411008 NA NA NA NA
ce24/1 pg-q2 (I) 106080 NA NA NA NA