Defining Policies for the Traffic Classes Using the policy-map Command
Router(config)# policy-map MYQOS-POLICY | Creates a policy map named "MYQOS-POLICY." |
Router(config-pmap)# class VOIP | Associates the class map named "VOIP" to this policy map. |
Choose one of these two: | Router(config-pmap-c)# priority 256 | Traffic classified as "VOIP" is assigned to a priority queue that has a bandwidth guarantee of 256 Kbps. |
OR |
Router(config-pmap-c)# priority percent 25 | Traffic classified as "VOIP" is assigned to a priority queue that has a bandwidth guarantee of 25 percent of total available bandwidth. |
Router(config-pmap-c)# exit | Returns to config-pmap mode. |
Router(config-pmap)# class BUSINESS-TRAFFIC | Associates the class map named "BUSINESS-TRAFFIC" to this policy map. |
Choose one of these three: | Router(config-pmap-c)# bandwidth 1000 | Traffic classified as "BUSINESS-TRAFFIC" is assigned to a WFQ with a bandwidth guarantee of 1000 Kbps. |
OR |
Router(config-pmap-c)# bandwidth percent 25 | Traffic classified as "BUSINESS-TRAFFIC" is assigned to a WFQ with a bandwidth guarantee of 25 percent of total available bandwidth. |
OR |
Router(config-pmap-c)# bandwidth remaining 25 | Traffic classified as "business-traffic" is assigned to a WFQ with a bandwidth guarantee of 25 percent of the remaining bandwidth. |
Router(config-pmap-c)# exit | Returns to config-pmap mode. |
Router(config-pmap)# class class-default | Associates the class map named "class-default" to this policy map. The "class-default" class map is a predefined map defined by Cisco IOS. |
Router(config-pmap-c)# fair-queue | Traffic classified as "class-default" will be assigned to a queue that gets the rest of the available bandwidth. |
Router(config-pmap-c)# exit | Returns to config-pmap mode. |
Router(config-pmap)# exit | Returns to global configuration mode. |
Note
Names used in the policy-map command are case sensitive.
Note
Up to 256 traffic classes (each defined by a class map) can be associated with a single traffic policy.
Note
If, within a policy map, you do not refer to the class-default class, any traffic that is not matched to a defined class will still be treated as class-default. The class-default will get no QoS guarantees and can have either a FIFO or a WFQ policy assigned to it.