cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1464
Views
15
Helpful
3
Replies

Rate Limiting drop algorithm procedure

Hi dears,

I want to know how a switch rate-limiting feature drops packets. So suppose a port is sending out 1 Gb traffic and I configure a 500mb egress filter on that port. Does the switch drop one packet from two consecutive packets? or Another rule is applied for dropping packets? does packet lengths affect on dropping procedure? 

 

Is there any standard for limiting in CISCO switches? Is this standard same for other switches?

as may you understand I want to know the exact procedure that a CISCO switch does when traffic exceeds from our egress limits. 

1 Accepted Solution

Accepted Solutions

What I believe, all packets that violate the volume limit during the time interval are dropped. I.e. packets that arrive, in the time interval, before the volume limit is exceeded, would not be dropped. So, for example, if fixed sized packets completely filled the time interval (i.e. 100% link utilization), starting at the beginning of the time interval, let's assume that would be 10, and the rate limit was 50% of the link speed, the first five packets would be passed and the second five packets would be dropped. Or, assuming only six packets arrived during the time interval, again the first five packets would be passed and the sixth packet would be dropped. In this later instance, it doesn't matter when those six packets arrived during the time interval. Also with this second instance, the seventh packet would be the first packet within the second time interval, and it too would be passed, as is would be one of the five allowed during that time interval.

Since packets are counted for "volume", the size of the packets matters concerning which one will be dropped or not. For example, if all the packets are still fixed size, but only half the size of the above, all the numbers, above, would be doubled.

I don't recall reading any documentation that states how/when a time interval is started. For simplicity, it might just be on a fixed real-time clock value, or it might stated with the first received packet and only reset when there are no packets received during a time interval (the latter assuming Be isn't "borrowed" [Be is somewhat difficult to explain, as I recall Cisco documentation doesn't always agree with how it often appears to actually operate]).

Again, keep in mind that a rate limiter tends to pass its volume of traffic much like a interface with that allocated bandwidth but with a small egress buffer/queue. I.e. bursts of overrate traffic will "tail drop" packets from the burst.

View solution in original post

3 Replies 3

Joseph W. Doherty
Hall of Fame
Hall of Fame
"does packet lengths affect on dropping procedure? "

It may.

"Another rule is applied for dropping packets?"

Yes, what happens is the rate limiter counts transmission volume during some time interval (Cisco known as "Tc"). When, during the time interval, there's more volume than would happen at the specified/limited rate, for the same time interval, the "exceeding" frames/packets will be dropped.

For the same physical link speed, and for the same logical limit speed, different device (or even identical device but different IOS versions) might have different default parameters, for Bc (and Be) but if they are manually set, you should obtain like behavior, although I don't recall what happens to the frame/packet that actually first breaks the time interval's volume limit, i.e. whether it's dropped for not. (I suspect it's dropped).

Depending how actual frames/packets align with the time interval's boundaries, packets might be dropped or not. I.e. a rate limiter's actual behavior is also impacted by the nature of the actual traffic's moment-to-moment transmission rate too.

BTW, shapers (not as often found on switches) also will drop packets, and their behavior overlaps that of a rate limiter's behavior. By default, a rate limiter passes traffic (volume wise) much like an interface for the configured rate that has a small buffer whereas a shaper behaves like an interface with a large buffer.

Thanks for your attention.

Let me give an example that helps you to make me packet dropping procedure clear.

For example, I have 100000 number of 1000 bytes Ethernet packets each packet consisting of a number that indicates the number of a packet (in this example number from 1 to 100000). this packets streams are repetitive in 1 second that makes 1 G traffic. I am sending this kind of packets into one port of a switch and I have chosen the rate limit of 500 M. My question is what stream of packets will I receive?

Maybe. packet number 1, packet number 3,.... (I haven't captured a stream like this but I cannot understand the output stream procedure)

what is the exact formula that map rate limit to the time that device capture data? (you know the ingoing ethernet lengths are unknown) 

 

What I believe, all packets that violate the volume limit during the time interval are dropped. I.e. packets that arrive, in the time interval, before the volume limit is exceeded, would not be dropped. So, for example, if fixed sized packets completely filled the time interval (i.e. 100% link utilization), starting at the beginning of the time interval, let's assume that would be 10, and the rate limit was 50% of the link speed, the first five packets would be passed and the second five packets would be dropped. Or, assuming only six packets arrived during the time interval, again the first five packets would be passed and the sixth packet would be dropped. In this later instance, it doesn't matter when those six packets arrived during the time interval. Also with this second instance, the seventh packet would be the first packet within the second time interval, and it too would be passed, as is would be one of the five allowed during that time interval.

Since packets are counted for "volume", the size of the packets matters concerning which one will be dropped or not. For example, if all the packets are still fixed size, but only half the size of the above, all the numbers, above, would be doubled.

I don't recall reading any documentation that states how/when a time interval is started. For simplicity, it might just be on a fixed real-time clock value, or it might stated with the first received packet and only reset when there are no packets received during a time interval (the latter assuming Be isn't "borrowed" [Be is somewhat difficult to explain, as I recall Cisco documentation doesn't always agree with how it often appears to actually operate]).

Again, keep in mind that a rate limiter tends to pass its volume of traffic much like a interface with that allocated bandwidth but with a small egress buffer/queue. I.e. bursts of overrate traffic will "tail drop" packets from the burst.
Review Cisco Networking for a $25 gift card