03-25-2011 08:43 AM - edited 03-04-2019 11:52 AM
Hi,
I am working on creat the QoS Policy with the shaping. Please the policy below.
class-map match-any mail
match protocol exchange
match protocol smtp
!
class-map match-any system
match protocol ftp
match protocol telnet
!
class-map match-any high
match access-group 2222
!
class-map match-any low
match protocol http url "xxx.com*"
match class-map mail
match class-map system
!
policy-map low_family
class mail
bandwidth percent 80
class system
bandwidth percent 20
!
policy-map ABC
class high
shape average percent 60
class low
shape average percent 40
service-policy low_family
In the red hightlight,
Can I do like this without matching two class-map since they will fall into the low class policy?
class-map match-any low
match protocol http url "xxx.com*"
Please advise. Thanks.
03-25-2011 09:42 AM
Yes.
Steve
03-25-2011 11:25 AM
Hi Steve,
Can you please provide me little details? or link will be helpful.
Thanks.
03-25-2011 02:25 PM
Sorry for giving you the wrong answer. I've had the flu for the past week and obviously my brain isn't functioning yet.
OK.
You want to take this:
class-map match-any low
match protocol http url "xxx.com*"
match class-map mail
match class-map system
and break it down to this:
class-map match-any low
match protocol http url "xxx.com*"
Here is the issue:
policy-map low_family
class mail
bandwidth percent 80
class system
bandwidth percent 20
!
policy-map ABC
class high
shape average percent 60
class low
shape average percent 40
service-policy low_family
In your policy map, as it classifies traffic it will reach "low". The classification for low contains mail, system and the URL. If you remove mail and system from the classification when it reaches your policy classifcation of low it will only classify the URL and apply the policy of low_family. Even though low_family matches mail and system, the policy-map itself that you attach to the interface won't match mail and system.
Let me try to break it down a bit easier.
Traffic goes out and the router classifies the traffic. It sees high which is ACL based and gives this priority. It won't see mail and system if you remove that from class-map match-any low even though you have it in the policy-map. It will only know when to apply the policy-map when the classification critera has been met. Without this, it won't know what to do with mail and system. You can provide more control over the remaining 40% by applying another policy-map to it, as you did.
I would re-work it this way:
class-map match-any LowURL
match protocol http url "*youtube*"
policy-map low_family
class mail
bandwidth percent 70
class system
bandwidth percent 20
class LowURL
bandwidth percent 10
OR
class class-default
fair-queue
Does that help?
Again, sorry for confusing you earlier.
References:
http://www.cisco.com/en/US/docs/ios/12_2/qos/configuration/guide/fqos_c.html
http://www.cisco.com/en/US/docs/ios/12_2/qos/configuration/guide/qcfcbshp.html#wp1002748 <--I recommend looking at this.
http://www.cisco.com/en/US/docs/ios/12_0t/12_0t5/feature/guide/cbwfq.html (Class-Based Weighted Fair Queueing)
04-01-2011 02:24 PM
Hi Steve,
Thank you so much for your help. I have two more questions...
1. Based on the policy below,
class-map match-any low
match protocol http url "youtub.com*"
match class-map mail
match class-map system
!
policy-map low_family
class mail
bandwidth percent 80
class system
bandwidth percent 20
!
policy-map ABC
class high
shape average percent 60
class low
shape average percent 40
service-policy low_family
If the url"youtube.com*" is place in a low (parent) policy, but not within the low family policy, how is that traffic handled in relation to CBWFQ defined in the low family policy?
2. What takes precedence for classification of traffic, NBAR or access-list?
Regards,
Joe
04-03-2011 05:58 PM
If the url"youtube.com*" is place in a low (parent) policy, but not within the low family policy, how is that traffic handled in relation to CBWFQ defined in the low family policy?
"If a default class is configured with the bandwidth policy-map class configuration command, all unclassified traffic is put into a single queue and given treatment according to the configured bandwidth. If a default class is configured with the fair-queue command, all unclassified traffic is flow classified and given best-effort treatment. If no default class is configured, then by default the traffic that does not match any of the configured classes is flow classified and given best-effort treatment. Once a packet is classified, all of the standard mechanisms that can be used to differentiate service among the classes apply. " (Cisco)
2. What takes precedence for classification of traffic, NBAR or access-list?
References:
Quality of Service Order of Operation
Class-Based Weighted Fair Queueing
You are welcome, I'm happy that I was able to help. Let me know if you have any more questions.
Steve
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide