Congestion Management and Avoidance 175
Congestion Management and Avoidance
After the switch classifies, marks, and polices a packet against QoS rules, the switch queues
the packet into a transmit queue for output scheduling. Placing the packet into one of
multiple queues allows for the switch to differentiate service by transmitting packets from
the queue with specific order and priority. The Catalyst 3550 Family of switches utilizes
WRED and tail-drop queuing mechanisms for congestion avoidance; the Catalyst 2950
Family of switches does not support congestion avoidance. Both the Catalyst 2950 Family
and 3550 Family of switches support four transmit queues. Although both switches support
output scheduling utilizing WRR, the Catalyst 3550 Family of switches supports additional
output scheduling and queuing configurations.
In brief, the Catalyst 2950 Family of switches supports the following output scheduling
mechanism:
Strict-priority scheduling
WRR scheduling
Strict-priority scheduling services packets placed into higher-priority queues before
servicing packets in lower-priority queues. Although this mechanism works well for high-
priority traffic such as Voice over IP (VoIP), this mechanism may starve transmission of
traffic in lower-priority queues. As a result, the second option of using WRR scheduling
exists. WRR transmits traffic based on a weight value. In this manner, each queue receives
an assigned weight of the total bandwidth. Therefore, during any period of time, the switch
sends traffic out of every queue based on its weighted value. Subsequent sections discuss
these mechanisms in more detail with configuration examples.
In brief, the Catalyst 3550 Family of switches supports the following queuing and output
scheduling mechanisms:
Expedite (strict-priority) queue
WRR scheduling
Configurable drop thresholds per output queue
WRED congestion avoidance algorithm
The Catalyst 3550 Family of switches uses WRR scheduling for output scheduling in a
manner similar to the Catalyst 2950 Family of switches. However, the Catalyst 3550 Family
of switches allows for designation of an expedite queue and configuration of congestion
avoidance mechanisms using tail-drop thresholds or WRED. The designation of the
expedite queue forces strict priority of transmission on the respective egress queue. The
congestion avoidance algorithms attempt to subside congestion by dropping packets with
lower priority before higher-priority packets in the same transmit queue. Later sections of
this chapter discuss these features in more detail.
176 Chapter 6: QoS Features Available on the Catalyst 2950 and 3550 Family of Switches
Congestion Management with the Catalyst 2950 and 3550 Family of
Switches
As noted in the preceding section, both the Catalyst 2950 Family and Catalyst 3550 Family
of switches perform output scheduling via strict-priority queuing and WRR, although each
family of switches exploits different default configurations. In summary, both the Catalyst
2950 Family and Catalyst 3550 Family of switches support the following congestion
management configuration options:
DSCP-to-CoS Mapping
CoS-to-Transmit Queue Mapping
Strict-Priority Queuing
Configurable Weights for WRR
DSCP-to-CoS Mapping
The Catalyst 2950 Family and 3500 Family of switches use an internal DSCP value to
differentiate service as a packet traverses the switch. Because marking may occur on a
packet during the marking and policing of packet process, the CoS value of the packet needs
to be updated on transmit. As a result, the switch employs the use of a DSCP-to-CoS
mapping table for mapping the internal DSCP value to CoS value on packets before the
switch schedules the packet into a transmit queue. Table 6-5 indicates the default DSCP-to-
CoS mapping table.
The DSCP-to-CoS mapping table is configurable on a global basis. Use the following
global configuration command to configure the DSCP-to-CoS mapping values:
mls qos map
dscp-cos dscp-list
to
cos
dscp-list represents up to eight DSCP values separated by a space. CoS corresponds to the
transmitted CoS value on the egress frame. Example 6-25 illustrates a user configuring and
verifying the QoS DSCP-to-CoS mapping.
Table 6-5 Default DSCP-to-CoS Mapping Table
DSCP Value 0–7 8–15 16–23 24–31 32–39 40–47 48–55 56–63
CoS Value 01234567
Example 6-25 Verifying and Configuring the DSCP-to-CoS Mapping
Switch#configure terminal
Switch(config)#mls qos map dscp-cos 37 38 39 to 5
Switch(config)#mls qos map dscp-cos 32 to 3
Switch(config)#end
Switch#show mls qos map dscp-cos
Dscp-cos map:
d1 : d2 0 1 2 3 4 5 6 7 8 9
Congestion Management and Avoidance 177
CoS-to-Transmit Queue Mapping
With the Catalyst 2950 and 3550 Family of switches, output scheduling uses the strict-
priority queuing or WRR algorithm with four transmit queues. The switch queues traffic
into the four transmit queues based solely on the CoS value associated with the frame. By
default, the switch places frames with higher CoS values into the higher-number queues.
The internal DSCP value actually determines the CoS value and subsequently the transmit
queue. Before the switches places packets into the transmit queues, the switch determines
the egress CoS value of the frame using the internal DSCP value and the DSCP-to-CoS
mapping table.
In retracing the path of the packet, refer to the following outline and Figure 6-5 to under-
stand the role of internal DSCP in CoS-to-transmit queue mapping.
Switch receives packet.
Switch classifies packets with an internal DSCP value based on configuration.
Switch polices, marks, or marks down the internal DSCP value.
Switch determines egress CoS value based on internal DSCP value and DSCP-to-CoS
mapping table.
Switch queues the packet into one of four transmit queues based on egress CoS value,
CoS-to-transmit queue mapping table, and any configured congestion avoidance
configurations.
Switch schedules packet out of the transmit queue based on strict-priority queuing or
WRR.
Table 6-6 illustrates the default CoS-to-transmit queue mapping.
---------------------------------------
0 : 00 00 00 00 00 00 00 00 01 01
1 : 01 01 01 01 01 01 02 02 02 02
2 : 02 02 02 02 03 03 03 03 03 03
3 : 03 03 03 04 04 04 04 05 05 05
4 : 05 05 05 05 05 05 05 05 06 06
5 : 06 06 06 06 06 06 07 07 07 07
6 : 07 07 07 07
Table 6-6 Default CoS-to-Transmit Queue Mapping Table
CoS Value Transmit Queue
0, 1 1
2, 3 2
4, 5 3
6, 7 4
Example 6-25 Verifying and Configuring the DSCP-to-CoS Mapping (Continued)
178 Chapter 6: QoS Features Available on the Catalyst 2950 and 3550 Family of Switches
Use the following command to display the CoS-to-transmit queue mapping:
ss
ss
hh
hh
oo
oo
ww
ww
ww
ww
rr
rr
rr
rr
--
--
qq
qq
uu
uu
ee
ee
uu
uu
ee
ee
cc
cc
oo
oo
ss
ss
--
--
mm
mm
aa
aa
pp
pp
The Catalyst 2950 Family of switches allows for custom configuration of the CoS-to-
transmit queue mapping on a global basis. The Catalyst 3550 Family of switches supports
CoS-to-transmit queue mapping on a per-interface basis. Use the following global and
interface configuration command to configure the CoS-to-transmit queue mapping:
wrr-queue cos-map
qid cos1..cosn
q_id represents one of the four transmit queues. cos1..cosn represents configuration for up
to eight CoS values to map to a transmit queue.
Example 6-26 illustrates a user custom configuring the CoS-to-transmit queue mapping
table and verifying the DSCP-TxQueue mapping table configuration.
Strict-Priority Queuing
By default, the Catalyst 2950 Family of switches schedules packets from transmit queues
using the strict-priority algorithm. Using this algorithm, the switch transmits all packets out
of the higher-priority queues before servicing lower-priority queues.
The Catalyst 3550 Family of switches utilizes the strict-priority queue configuration with
WRR for scheduling all the packets out of transmit queue four before servicing any other
queue. The switch still utilizes WRR for scheduling packets out of the remaining queues.
The behavior of this configuration is slightly different from the behavior on the Catalyst
2950 Family of switches. Priority Queuing on the Catalyst 2950 Family of switches
services higher-priority queues before lower-priority queues in order and does not support
the concept of a single expedite queue.
To configure the Catalyst 3550 Family of switches for the strict-priority scheduling of
transmit queue four, use the following interface command:
pp
pp
rr
rr
ii
ii
oo
oo
rr
rr
ii
ii
tt
tt
yy
yy
--
--
qq
qq
uu
uu
ee
ee
uu
uu
ee
ee
oo
oo
uu
uu
tt
tt
As a result of the strict-priority scheduling algorithm on both the Catalyst 2950 and 3550
Family of switches, the switches may never transmit traffic out of lower-priority queues
when line-rate traffic exists in higher-priority queues. Although this behavior is warranted
for high-priority traffic such as VoIP, many applications of strict-priority queuing may
starve lower-priority traffic. To remedy this situation, consider configuring the switch for
WRR bandwidth and WRED as discussed in the next section.
Example 6-26 User Configuring and Verifying the DSCP-to-Transmit Queue Mapping Table
Switch#configure terminal
Switch(config)#wrr-queue cos-map 1 0 1 2
Switch(config)#wrr-queue cos-map 2 3 4
Switch(config)#wrr-queue cos-map 3 5
Switch(config)#end
Switch#show wrr-queue cos-map
CoS Value : 0 1 2 3 4 5 6 7
Priority Queue : 1 1 1 2 2 3 4 4
Congestion Management and Avoidance 179
Configurable Weights for WRR
By default, the Catalyst 3550 Family of switches utilizes WRR for congestion management.
The Catalyst 2950 Family of switches supports WRR as an optional configuration. Both the
Catalyst 2950 Family and 3550 Family of switches support adjusting the scheduling weight
for each transmit queue. For the Catalyst 2950 Family of switches, WRR conguration is a
global configuration. On the Catalyst 3550 Family of switches, WRR configuration is per
interface. The scheduling weight effectively determines the egress bandwidth per queue. Use the
following egress bandwidth formula to determine WRR weight:
(W/S )* B = n
W represents the WRR weight of the queue, and S represents the sum of all weights of the
active queues. B is the available bandwidth of the outgoing interface(s), and n represents
the egress bandwidth.
For example, each queue, 1 through 4, is assigned the following WRR weights on a Gigabit
Ethernet interface, respectively:
50 50 100 200
The S of the weights is 400. As a result of this configuration, each transmit queue receives
the following egress bandwidth:
Queue 1: 125 Mbps
Queue 2: 125 Mbps
Queue 3: 250 Mbps
Queue 4: 500 Mbps
To configure the scheduling weight of total bandwidth per queue, use the following global
configuration command for the Catalyst 2950 Family of switches and interface configu-
ration command for the Catalyst 3550 Family of switches:
wrr-queue bandwidth
weight1...weight4
weight1…weight4 represent four weighted values assigned to transmit queues 1, 2, 3, 4 respec-
tively. Use the following command to display the configured WRR bandwidth per queue:
ss
ss
hh
hh
oo
oo
ww
ww
ww
ww
rr
rr
rr
rr
--
--
qq
qq
uu
uu
ee
ee
uu
uu
ee
ee
bb
bb
aa
aa
nn
nn
dd
dd
ww
ww
ii
ii
dd
dd
tt
tt
hh
hh
Example 6-27 illustrates a user configuring the WRR bandwidth per queue for heavier
weights on higher-priority queues and verifying the WRR bandwidth configuration on a
Catalyst 2950 switch. In this example, queue 1 receives 10 percent of the bandwidth, queue 2
receives 20 percent of the bandwidth, queue 3 receives 30 percent of the bandwidth, and
queue 4 receives 40 percent of the bandwidth on egress.
Example 6-27 User Configuring and Verifying a WRR Bandwidth Configuration
Switch#configure terminal
Switch(config)#wrr-queue bandwidth 10 20 30 40
Switch(config)#end
Switch#show wrr-queue bandwidth
WRR Queue : 1 2 3 4
Bandwidth : 10 20 30 40
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset