Step 1 |
enable
Example:
|
Enables privileged EXEC mode.
|
Step 2 |
configure
terminal
Example:
Router# configure terminal
|
Enters global configuration mode.
|
Step 3 |
policy-map
policy-map-name
Example:
Router(config)# policy-map session_a_child
|
Creates a child policy and enters policy-map configuration mode.
|
Step 4 |
class
class-map-name
Example:
Router(config-pmap)# class voip
|
Configures the traffic class that you specify and enters policy-map class configuration mode.
|
Step 5 | bandwidth {bandwidth-kbps |
percentpercentage|
remainingpercentpercentage}
Example:
Router(config-pmap-c)# bandwidth 10000
Example:
|
(Optional) Enables class-based weighted fair queueing based on the keywords and arguments specified, as described below.
bandwidth-kbps--Specifies the minimum bandwidth allocated for a class belonging to a policy map. Valid values are from 8 to 2,488,320, which represents from 1 to 99 percent of the link bandwidth.
percent percentage--Specifies the minimum percentage of the link bandwidth allocated for a class belonging to a policy map. Valid values are from 1 to 99.
remaining percent percentage--Specifies the minimum percentage of unused link bandwidth allocated for a class belonging to a policy map. Valid values are from 1 to 99.
|
Step 6 |
precedence
precedence
min-threshold
max-threshold
mark-probability-denominator
Example:
Router(config-pmap-c)# precedence 0 32 256 100
|
(Optional) Configures a precedence level for the traffic class based on the arguments specified, as described below.
precedence--Specifies the IP precedence number. Valid values are from 0 to 7.
min-threshold--Specifies the minimum threshold in number of packets. Valid values are from 1 to 4096.
max-threshold--Specifies the maximum threshold in number of packets. Valid values are from the minimum threshold to 4096.
mark-probability-denominator--Specifies the denominator for the fraction of packets dropped when the average queue depth is equal to the maximum threshold. For example, if the denominator is 512, 1 out of every 512 packets is dropped when the average queue is at the maximum threshold. Valid values are from 1 to 65536. The default value is 10 (1 out of every 10 packets is dropped at the maximum threshold).
|
Step 7 |
set
cos
cos-value
Example:
Router(config-pmap-c)# set cos 1
|
(Optional) Sets the Layer 2 class of service (CoS) value of an outgoing packet.
Note
| Use the set cos command only in service policies that are attached in the output direction of an interface; packets that enter an interface cannot be set with a CoS value. You can configure a CoS value on an Ethernet interface that is configured for 802.1Q or on a virtual access interface that is using an 802.1Q interface.
|
|
Step 8 |
exit
Example:
Router(config-pmap-c)# exit
|
Exits policy-map class configuration mode.
|
Step 9 |
exit
Example:
Router(config-pmap)# exit
|
Exits policy-map configuration mode.
|
Step 10 |
policy-map
policy-map-name
Example:
Router(config)# policy-map session_a_parent
|
Creates a parent policy and enters policy-map configuration mode.
|
Step 11 |
class
class-default
Example:
Router(config-pmap)# class class-default
|
Configures the traffic class as class-default and enters policy-map class configuration mode.
Note
| Do not configure any other traffic class.
|
|
Step 12 |
shape
average
cir
Example:
Router(config-pmap-c)# shape average 10000000
|
Specifies average-rate traffic shaping for all traffic that does not match any other traffic class.
|
Step 13 |
bandwidth
remaining
ratio
ratio
Example:
Router(config-pmap-c)# bandwidth remaining ratio 10
|
Specifies the weight (ratio) for the subinterface.
|
Step 14 |
service-polic
ypolicy-map-name
Example:
Router(config-pmap-c)# service-policy session_a_child
|
Applies the child policy map to the parent class-default class.
|
Step 15 |
exit
Example:
Router(config-pmap-c)# exit
|
Exits policy-map class configuration mode.
|
Step 16 |
exit
Example:
Router(config-pmap)# exit
|
Exits policy-map configuration mode.
|
Step 17 |
interface
virtual-template
number
Example:
Router(config)# interface virtual-template 1
|
Creates a virtual template and enters interface configuration mode.
|
Step 18 |
service-policy
output
policy-map-name
Example:
Router(config-if)# service-policy output session_a_parent
|
Applies the service policy to the virtual interface.
Note
| You must specify the output keyword to apply the service policy to outbound traffic on the interface.
|
|
Step 19 |
end
Example:
|
(Optional) Returns to privileged EXEC mode.
|