Queuing
Last updated
Last updated
If a network device receives messages faster than it can forward them out of the appropriate interface, the messages are placed in a queue.
By default, queued messages will be forwarded in a First In First Out (FIFO) manner.
Messages will be sent in the order they are received.
If the queue is full new packets will be dropped.
This is called tail drop.
Tail drop is harmful because it can lead to TCP global synchronization.
Review of the TCP sliding window.
Hosts using TCP use the 'sliding window' increase/decrease the rate at which they send traffic as needed.
When a packet is dropped it will be re-transmitted.
When a drop occurs, the sender will reduce the rate it sends traffic.
It will then gradually increase the rate again.
When the queue fills up and tail drop occurs, all TCP hosts sending traffic will slow down the rate at which they send traffic.
They will all then increase the rate at which they send traffic, which rapidly leads to more congestion, dropped packets, and the process repeats again-
A solution to prevent tail drop and TCP global synchronization is Random Early Detection (RED).
When the amount of traffic in the queue reaches a certain threshold, the device will start randomly dropping packets from select TCP flows.
Those TCP flows that dropped packets will reduce the rate at which traffic is sent, but you will avoid global TCP synchronization, in which ALL TCP flows reduce and then increase the rate of transmission at the same time in waves.
In standard RED, all kinds of traffic are treated the same.
An improved version, Weighted Random Early Detection (WRED), allows you to control which packets are dropped depending on the traffic class.
We will cover traffic classes and details about how QoS actually works in the next video.