3 qos example, Xample – PLANET XGS3-24040 User Manual
Page 161

Chapter 17 Qos Configuration
17-10
17.3 QoS Example
Example 1:
Enable QoS function, change the queue out weight of port ethernet 1/1 to 1:1:2:2:4:4:8:8, and set the port in
trust QoS mode without changing DSCP value, and set the default QoS value of the port to 5.
The configuration steps are listed below:
Switch#config
Switch(config)#mls qos
Switch(config)#interface ethernet 1/1
Switch(Config-If-Ethernet1/1)#wrr-queue bandwidth 1:1:2:2:4:4:8:8
Switch(Config-If-Ethernet1/1)#mls qos trust cos pass-through-dscp
Switch(Config-If-Ethernet1/1)#mls qos cos 5
Configuration result:
When QoS enabled in Global Mode, the egress queue bandwidth proportion of port ethernet1/1 is
1:1:2:2:4:4:8:8. When packets have CoS value coming in through port ethernet1/1, it will be map to the queue
out according to the CoS value, CoS value 0 to 7 correspond to queue out 1, 2, 3, 4, 5, 6, 7, 8, respectively.
If the incoming packet has no CoS value, it is default to 5 and will be put in queue6. All passing packets would
not have their DSCP values changed.
Example 2:
In port ethernet1/2, set the bandwidth for packets from segment 192.168.1.0 to 10 Mb/s, with a burst value of
4 MB, all packets exceed this bandwidth setting will be dropped.
The configuration steps are listed below:
Switch#config
Switch(config)#access-list 1 permit 192.168.1.0 0.0.0.255
Switch(config)#mls qos
Switch(config)#class-map c1
Switch(Config-ClassMap-c1)#match access-group 1
Switch(Config-ClassMap-c1)#exit
Switch(config)#policy-map p1
Switch(Config-PolicyMap-p1)#class c1
Switch(Config-PolicyMap-p1-Class-c1)#policy 10000 4000 exceed-action drop
Switch(Config-PolicyMap-p1-Class-c1)#exit
Switch(Config-PolicyMap-p1)#exit
Switch(config)#interface ethernet 1/2
Switch(Config-If-Ethernet1/2)#service-policy input p1