12-16-2019 12:33 AM - edited 12-16-2019 01:15 AM
PARENT_10Mbps policy applied to some interface.
The CHILD policy BULK_CLASS has both "bandwidth percent" and "police" commands applied.
1) Which of these two commands will take effect? Or both commands will work together somehow?
Command "bandwidth percent 5" is 500kbps (bacause of 10Mbits PARENT shaping) and "police 3000000" is 3Mbits.
2) What real speed this class gets in cases of partial and full utilization of 10Mbits?
policy-map CHILD class VOICE_CLASS priority percent 50 class BUSINESS_TRAFFIC_CLASS bandwidth percent 45 class BULK_CLASS bandwidth percent 5 police 3000000 8000 8000 conform-action transmit exceed-action drop violate-action drop class class-default fair-queue random-detect policy-map PARENT_10Mbps class class-default shape average 10000000 service-policy CHILD
Solved! Go to Solution.
12-16-2019 10:21 AM - edited 12-16-2019 10:22 AM
I'm surprised IOS accepted the shown policies. Why? Because 100% has been allocated leaving class-default zero percent. (I recall [?] HQF IOS versions require a minimum of 1% for class-default. [I also recommend all classes have an explicit bandwidth allocation.])
#1 Normally both commands work together. BULK_CLASS will always be "capped" at 3 Mbps due to the policer. If class-default really is only getting a zero percent guarantee, then BULK_CLASS will be dequeued obtaining its 5% relative to the other non-LLQ active classes. So, for example, if only BULK_CLASS and BUSINESS_TRAFFIC_CLASS were only two active classes, and both wanted all the bandwidth, they would split it 45:5 or 9:1, i.e. BUSINESS_TRAFFIC_CLASS would obtain 9 Mbps and BULK_CLASS 1 Mbps (which is within the policer's limit).
#2 Depends on what the other classes are doing. Bandwidth allocations, excluding LLQ, "under-the-covers" really sets relative dequeuing ratios. (LLQ classes always dequeue first, but they have an implicit policer.) Also, prior to HQF, FQ in class-default isn't "limited" just by class bandwidth allocation (it's rather complicated). With HQF, FQ in class-default is supposed to enforce the class bandwidth allocation, but don't know, if bandwidth is undefined, what's supposed to happen.
12-16-2019 01:37 AM
Hello
In times of congestion the class- Bulk_Class will receive a minimum of 256kps of BW but could obtain more if the other classes are not being utilized with the police action stating if this class exceeds 3mb then its traffic will be dropped.
12-16-2019 03:34 AM
Thank you for answer.
In times of congestion the class Bulk_Class will receive a minimum of 256kps
You mean 512kbps (5% of 10Mbits) ?
Do I correctly understand that these two commands can work together and:
1) Bandwidth percent command guarantees the minimum bandwidth in case of full utilization of channel (10Mbit)
2) Assume that shaping process in some moment of time is ready to give more than 3Mbits to BULK_CLASS (because of channel low utilization by other classes), but configured police command will always drop packets above 3Mbit rate ?
12-16-2019 05:48 AM
Hello
@Pavel Komissarov wrote:
Thank you for answer.
In times of congestion the class Bulk_Class will receive a minimum of 256kps
You mean 512kbps (5% of 10Mbits) ? - < no it will be 256kps because you have priority LLQ taking 50% of the 10mb
Do I correctly understand that these two commands can work together and:
1) Bandwidth percent command guarantees the minimum bandwidth in case of full utilization of channel (10Mbit) < yes
2) Assume that shaping process in some moment of time is ready to give more than 3Mbits to BULK_CLASS (because of channel low utilization by other classes), but configured police command will always drop packets above 3Mbit rate ? <-- correct
12-16-2019 06:50 AM
Ok. Everything is clear, except:
You mean 512kbps (5% of 10Mbits) ? - < no it will be 256kps because you have priority LLQ taking 50% of the 10mb
Don't you by chance confuse bandwidth percent and bandwidth remaining percent commands?
Because from my experience bandwidth percent directly sets percent of bandwidth and doesn't depend on priority percent command parametres from other classes.
12-16-2019 02:59 PM
12-16-2019 10:21 AM - edited 12-16-2019 10:22 AM
I'm surprised IOS accepted the shown policies. Why? Because 100% has been allocated leaving class-default zero percent. (I recall [?] HQF IOS versions require a minimum of 1% for class-default. [I also recommend all classes have an explicit bandwidth allocation.])
#1 Normally both commands work together. BULK_CLASS will always be "capped" at 3 Mbps due to the policer. If class-default really is only getting a zero percent guarantee, then BULK_CLASS will be dequeued obtaining its 5% relative to the other non-LLQ active classes. So, for example, if only BULK_CLASS and BUSINESS_TRAFFIC_CLASS were only two active classes, and both wanted all the bandwidth, they would split it 45:5 or 9:1, i.e. BUSINESS_TRAFFIC_CLASS would obtain 9 Mbps and BULK_CLASS 1 Mbps (which is within the policer's limit).
#2 Depends on what the other classes are doing. Bandwidth allocations, excluding LLQ, "under-the-covers" really sets relative dequeuing ratios. (LLQ classes always dequeue first, but they have an implicit policer.) Also, prior to HQF, FQ in class-default isn't "limited" just by class bandwidth allocation (it's rather complicated). With HQF, FQ in class-default is supposed to enforce the class bandwidth allocation, but don't know, if bandwidth is undefined, what's supposed to happen.
12-17-2019 01:05 AM
Thank you for answer.
And about this little correction:
I recall [?] HQF IOS versions require a minimum of 1% for class-default.
Yes, you are right. Cisco CLI declines the command, when I try to allocate all 100% of bandwidth percents beetween several classes, but 99% it accepts.
12-17-2019 07:24 AM - edited 12-18-2019 06:27 AM
Then in that case, we might presume class-default obtains 1%. However, if you defined less than 99% for other classes, again, not really sure what class-default obtains without an explicit bandwidth allocation. Whatever it obtains in such cases, by default, may vary between IOS variants.
Otherwise, are your questions answered? Bandwidth allocations, for non-LLQ classes, really define dequeuing weights, and dequeuing is relative between those weights. So, again, between BUSINESS_TRAFFIC_CLASS and BULK_CLASS, they will split bandwidth 45:5 or 9:1. This, though, assumes they want their full allocation or more. If, for example, BUSINESS_TRAFFIC_CLASS was only using 1 Mbps, BULK_CLASS class could have the unused bandwidth, yet if both queues had something in their queues as the same moment, BUSINESS_TRAFFIC_CLASS would more often be selected to be dequeued first.
A LLQ class, like your VOICE_CLASS class, will always dequeue before other non-LLQ classes, assuming it's not dropped due to exceeding its bandwidth allocation. However, usually that bandwidth limit is only active when there's actual congestion. If not, generally the LLQ class can exceed the implicit limit. I.e. you could find, for example, VOICE_CLASS using 90% of the bandwidth.
12-17-2019 10:53 PM
Yes, thank you for detailed answers. Everything is clear for now.
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