WRED Weighted RED
Weighted Random Early Detection (WRED) is a congestion avoidance mechanism used in network routers to manage and control the queuing of packets during periods of network congestion. It is an enhancement of the traditional Random Early Detection (RED) algorithm, which aims to prevent network congestion collapse and maintain fair packet queuing in network queues.
The Need for WRED:
Network congestion occurs when the rate of incoming traffic exceeds the capacity of the network or a specific network link. During congestion, packets may be delayed, dropped, or experience increased latency, which can lead to degraded network performance and potential data loss.
Traditional congestion control mechanisms, such as tail drop, often result in global synchronization, where all packets are dropped simultaneously when the buffer reaches its maximum capacity. This can lead to a sudden and severe decrease in the network throughput, causing congestion collapse. RED was introduced as a solution to this problem.
How WRED Works:
WRED dynamically manages the size of network buffers and selectively drops packets based on the average queue size, the threshold, and packet drop probabilities. By doing so, WRED aims to prevent global synchronization and maintain fair queuing during periods of congestion.
WRED uses a weighted approach to decide which packets to drop based on their priority or importance. This is particularly useful when multiple classes of traffic (e.g., voice, video, data) coexist in the network, and certain traffic types require preferential treatment.
Key Components of WRED:
- Queue Thresholds: WRED uses one or more queue thresholds to determine when congestion is approaching. Each threshold corresponds to a different level of congestion severity.
- Drop Probability Curves: WRED employs drop probability curves to calculate the likelihood of dropping packets based on the average queue size relative to the configured thresholds. The curves can be linear or non-linear, depending on the desired behavior.
- Explicit Congestion Notification (ECN): WRED can work in conjunction with ECN, where instead of dropping packets, the routers mark the packets with a congestion indication. The end devices can then respond by adjusting their transmission rates accordingly.
WRED for Differentiated Services:
WRED is particularly useful in Differentiated Services (DiffServ) networks, where different classes of traffic receive different levels of service. By configuring WRED parameters differently for each class, network administrators can provide preferential treatment to high-priority traffic while managing congestion for less important traffic.
Benefits of WRED:
- Improved Fairness: WRED helps to avoid global synchronization, ensuring fair packet queuing for different traffic flows, classes, or service levels.
- Reduced Latency: By dropping packets before the buffer reaches its maximum capacity, WRED helps reduce packet latency during congestion.
- Prevention of Congestion Collapse: WRED prevents congestion collapse by selectively dropping packets early in the queue, rather than all at once.
- Support for Differentiated Services: WRED's weighted approach allows for differentiated treatment of various traffic classes based on their importance and priority.
Conclusion:
Weighted Random Early Detection (WRED) is an enhancement of the Random Early Detection (RED) algorithm used in network routers for congestion avoidance. It employs a weighted approach to manage packet queuing during periods of network congestion, aiming to prevent congestion collapse and maintain fair treatment of different traffic flows. WRED is particularly useful in differentiated services networks, where different classes of traffic require different levels of service and priority. By intelligently dropping packets based on configured thresholds and drop probability curves, WRED helps to ensure efficient and fair utilization of network resources during congestion.