01-08-2014 04:26 AM - edited 03-16-2019 09:08 PM
Are the following class-maps equivalent since there is only one match statement in them? or does the any/all apply to "af41 and/or cs4"
class-map type qos match-any VIDEO
match dscp af41 cs4
class-map type qos match-all VIDEO
match dscp af41 cs4
Brian Holmes
Verizon Enterprise for Chrysler
01-08-2014 04:31 AM
To create a traffic class, use the class-map command. The syntax of the class-map command is as follows:
class-map [match-any | match-all] class-name
no class-map [match-any | match-all] class-name
The match-all and match-any Keywords
The match-all and match-any keywords need to be specified only if more than one match criterion is configured in the traffic class.
The match-all keyword is used when all of the match criteria in the traffic class must be met in order for a packet to be placed in the specified traffic class.
The match-any keyword is used when only one of the match criterion in the traffic class must be met in order for a packet to be placed in the specified traffic class.
If neither the match-all nor match-any keyword is specified, the traffic class will behave in a manner consistent with match-all keyword.
About The match not Command
The match not command, rather than identifying the specific match parameter to use as a match criterion, is used to specify a match criterion that prevents a packet from being classified as a member of the class. For instance, if the match not qos-group 6 command is issued while you configure the traffic class, QoS group 6 becomes the only QoS group value that is not considered a successful match criterion. All other QoS group values would be successful match criteria.
01-08-2014 04:42 AM
But since there is only one match statement in this case, wouldn't match-any be equivelent to match-all?
on the other had, if the class map looked like this I understand how match-any would be differant than match-all
class-map type qos match-all VIDEO
match dscp af41
match dscp cs4
i.e.
In this case I would expect no packets to ever match since a packet could never have dscp af41 AND dscp cs4
But with the original class-map
class-map type qos match-all VIDEO
match dscp af41 cs4
Can I assume an OR is applied between "af41 cs4" since it is a single match statement?
Brian Holmes
Verizon Enterprise for Chrysler
01-08-2014 06:16 AM
The match-any or match-all will change from OR to AND for multiple lines.
Match all its acts as a "AND" operation. Where match any does a "OR" operation . if there is only one it does not matter at all, however if there are more than one then you match all of them.
let says you have
class-map type qos match-all VIDEO
match dscp af41
match dscp cs4
So when packets arrives, it will matches AF41 and CS4.
class-map type qos match-any VIDEO
match dscp af41
match dscp cs4
"Match-any" is OR logic between each line in the class-map. If any of those entries hold true, so if it has af41 or cs4 the class map will have match
Br,
Nadeem
Please rate all useful post.
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