7 Rate Limiting and Traffic Shaping Flashcards
Data (Source Classification)
bursty, periodic, regular
Audio (Source Classification)
continuous, periodic
Video (Source Classification)
continuous, bursty (compression), periodic
CBR (a type of class of sources)
Constant Bit Rate source
In a constant bit rate source of traffic, traffic arrives at regular intervals, and packets are typically the same size as they arrive, resulting in a constant bit rate of arrival.
Audio is an example of a constant bit rate source
When we shape CBR traffic, we shape it according to a peak rate.
VBR (a type of class of sources
Variable Bit Rate source
Many other sources of traffic are VBR
Video and Data are often variable bit rate
VBR is shaped according to both an average rate and a peak rate where the average rate might actually be a small fraction of the peak rate.
At certain times, peak rate might well exceed the average rate.
“Leaky Bucket” (Traffic Shaping)
Each flow has its own bucket
Data arrives in a bucket of size beta and drains from the backet at rate rho.
The parameter rho controls the average rate.
Data can arrive faster or slower into the bucket but it cannot drain at a rate faster than rho.
Therefore the maximum average rate that traffic can be sent is the smooth rate, rho.
Size of the bucket controls the maximum burst size that a sender can send for a particular flow.
At times, the sender might be able to send at a faster rate, as long as the total size of the burst does not exceed the size of the bucket or does not overflow the bucket.
The leaky bucket allows flows to periodically burst, and the regulator at the bottom of the leaky bucket ensures that the average rate does not exceed the drain rate of the drain rate of the bucket.
Setting a larger bucket size can accommodate a larger burst size
Setting a larger value of rho can accommodate or enable a faster packet rate
(r,T) Traffic Shaping
Traffic divided into T-bit frames
Flow can inject less than or equal to r bits in any T-bit frame
A flow that obeys this rule has what is known as an rT smooth traffic shape
One cannot send a packet that’s larger than r bits long.
Unless T is very long, the maximum packet size may be very small
Range of behaviors is typically limited to fixed rate flows
Variable flows have to request data rates that are equal to the peak rate, this is wasteful
Flow can send a certain number of bits every time unit instead of 1 packet every time unit(like leaky bucket)
When flow exceeds a particular rate, the excess packets in that flow are given a lower priority.
If network is heavily loaded or congested, the packets from a flow that exceeds the rate may be preferentially dropped.
Priorities may be assigned at the sender or at the network.
At the sender, the application may mark its own packets since the sender knows which ones are lower or higher in priority.
In the network, the routers may mark packets with a lower priority, which is called policing
Shaping Bursty Traffic Patterns
Sometimes we may want to shape bursty traffic patterns allowing for bursts to be sent on the network, but still ensuring that the flow does not exceed some average rate.
For this we might use what is called a token bucket
Token Bucket
permits burstiness, but bounds it
no discard or priority
difficulty with policing
Leaky Bucket
smooths bursty traffic
priority policies
Apply policing to token buckets
Use a Composite Shaper, which is to combine a Token Bucket Shaper with a Leaky bucket
This allows for good policing, confirming that the flow’s data rate does not exceed the average data rate allowed by the smooth Leaky Bucket rate is easy.
But the implementation is more complex since each flow now requires two counters and two timers (one counter and one timer for each bucket)
1 byte = ?
8 bits
8 bits = ?
1 byte
Power Boost
A traffic shaping mechanism that was first deployed in commercial broadband networks in June 2006 by Comcast
Allows a subscriber to send at higher rate for a brief period of time
targets spare capacity for users who do not put sustained load on the network
2 types of power boost
capped
if the rate at which the user can achieve during this burst window is set to not exceed a particular rate, then we say that the policy is capped PowerBoost
uncapped
The configuration is simple.
PowerBoost bucket size, the max amount of traffic that can be sent that exceeds the sustained rate.
Power Boost has effect on the latency as well as the loss rate
Shaping traffic < or equal to Rsus can prevent this buffering