27-18
Cisco ME 3800X and 3600X Switch Software Configuration Guide
OL-23400-01
Chapter 27 Configuring QoS
Understanding QoS
Traffic Shaping
Traffic shaping or class-based peak rate scheduling is used to specify the maximum transmission rate for
a traffic class. Unlike traffic policing, where nonconforming packets are dropped or marked right away,
packets exceeding the rate specified in the shape command are usually buffered and can be sent later
when bandwidth is available. While policing propagates traffic bursts, shaping smooths bursts by
sending the packets later. Traffic policing is used in input policy maps, and traffic shaping occurs as
traffic leaves an interface or service instance.
Configuring a queue for traffic shaping sets the maximum bandwidth or PIR of the queue. You can set
the PIR from 1 Kb/s to 10 Gb/s. You can also configure the PIR as a percentage of the PIR of a parent
level.
Note
You cannot configure traffic shaping (shape average) and or priority queuing (priority) for the
same class in an output policy map. However, you can configure CIR, PIR, and EIR bandwidth
independently for a class and use the bandwidth, bandwidth remaining, and shape average
commands at the same time within a class.
Class-Based Shaping
Class-based shaping uses the shape average policy-map class configuration command to limit the rate
of data transmission in bits per second to be used for the committed information rate for a class of traffic.
The switch supports separate queues for four or eight classes of traffic, including the default queue for
class class-default, unclassified traffic.
See the
“Configuring Class-Based Shaping” section on page 27-47
.
Port Shaping
Port shaping is applied to all traffic leaving a target. It uses a policy map with only class default when
you specify the maximum bandwidth for the port by using the shape average command. You can attach
a child policy to the class-default in a hierarchical policy map format to specify class-based and
VLAN-based actions. See the
“Configuring Port Shaping” section on page 27-48
.
Parent-Child Hierarchy
The switch also supports parent policy levels and child policy levels for traffic shaping. The QoS
parent-child structure is used for specific purposes when a child policy is referenced in a parent policy
to provide additional control of a specific traffic type.
Note
The total of the minimum bandwidth guarantees (CIR) for each queue of the child policy cannot exceed
the total port-shape rate.
This is an example of a parent-child configuration:
Switch(config)#
policy-map parent
Switch(config-pmap)#
class class-default
Switch(config-pmap-c)#
shape average 50000000
Switch(config-pmap-c)#
service-policy child
Switch(config-pmap-c)#
exit
Switch(config-pmap)#
exit
Switch(config)#
interface gigabitthernet0/1
Switch(config-if)#
service-policy output parent
Switch(config-if)#
exit