27-38
Cisco ME 3800X and 3600X Switch Software Configuration Guide
OL-23400-01
Chapter 27 Configuring QoS
Configuring QoS
This example shows how to create policy map with a conform action of set dscp and a default exceed
action, and attach it to an EFP.
Switch(config)#
class-map in-class-1
Switch(config-cmap)#
match dscp 14
Switch(config-cmap)#
exit
Switch(config)#
policy-map in-policy
Switch(config-pmap)#
class in-class-1
Switch(config-pmap-c)#
police 230000 8000 conform-action set-dscp-transmit 33
exceed-action drop
Switch(config-pmap-c)#
exit
Switch(config-pmap)#
exit
Switch(config)#
interface gigabitethernet0/1
Switch (config-if)#
service instance 1 Ethernet
Switch (config-if-srv)#
service-policy input in-policy
Switch (config-if-srv)#
exit
This example shows how to use policy-map class police configuration mode to set multiple conform
actions and an exceed action. The policy map sets a committed information rate of 23000 bits per second
(b/s) and a conform burst size of 10000 bytes. The policy map includes multiple conform actions (for
DSCP and for Layer 2 CoS) and an exceed action.
Switch(config)#
class-map cos-set-1
Switch(config-cmap)#
match cos 3
Switch(config-cmap)#
exit
Switch(config)#
policy-map map1
Switch(config-pmap)#
class cos-set-1
Switch(config-pmap-c)#
police cir 23000 bc 10000
Switch(config-pmap-c-police)#
conform-action set-dscp-transmit 48
Switch(config-pmap-c-police)#
conform-action set-cos-transmit 5
Switch(config-pmap-c-police)#
exceed-action drop
Switch(config-pmap-c-police)#
exit
Switch(config-pmap)#
exit
Switch(config)#
interface gigabitethernet0/1
Switch(config-if)#
service-policy input map1
Switch(config-if)#
exit
Configuring a Policy Map with 2-Rate, 3-Color Policing
A 2-rate, 3-color policer uses both the committed information rate (CIR) and the peak information rate
(PIR) and includes three profiles (colors) for packets that conform, exceed, or violate the specified rates.
You can configure actions to take on each of these profiles.
Beginning in privileged EXEC mode, follow these steps to create an input policy map with individual
2-rate, 3-color policing:
Command
Purpose
Step 1
configure terminal
Enter global configuration mode.
Step 2
class {class-map-name |
class-default}
Enter a class-map name or class-default to match all unclassified packets, and
enter policy-map class configuration mode.
If you enter a class-map name, you must have already created the class map
by using the class-map global configuration command.
Step 3
policy-map policy-map-name
Create a policy map by entering the policy map name, and enter policy-map
configuration mode. By default, no class maps are defined.