TCP Reno and TCP New Reno are both congestion control algorithms that play a crucial role in the transport layer of the TCP/IP protocol stack. TCP Reno, known for its reliability and efficiency, incorporates mechanisms like slow start, AIMD, fast retransmit, and fast recovery. It dynamically adjusts the congestion window size to regulate data transmission and respond to network congestion.?Taking congestion control to the next level, TCP New Reno builds upon TCP Reno's foundation. It intelligently handles multiple packet losses within a single window of data, minimising unnecessary retransmissions. By efficiently recovering from packet loss and optimising throughput, TCP New Reno enhances the overall performance of data transmission. Like TCP Reno, TCP New Reno is implemented within the TCP stack of operating systems, ensuring seamless integration into network infrastructure.?
Here's a simplified explanation of TCP Reno's behaviour.
- Initially, the sender starts with a congestion window (cwnd) of a small value, such as 1 or 2 packets.
- The sender enters the slow start phase, where it exponentially increases the cwnd by 1 for every ACK received, effectively doubling the cwnd after each round trip.
- As the cwnd increases, the sender transmits more packets, increasing the network utilisation.
- If the sender detects packet loss (signaled by duplicate ACKs), it assumes network congestion and enters the fast retransmit and fast recovery phases.
- During fast retransmit, the sender retransmits the missing packet without waiting for a timeout.
- In fast recovery, the sender reduces the cwnd by half instead of setting it to the initial value. It then enters a congestion avoidance phase where the cwnd is incremented by a smaller value for every round trip.
- Upon receiving new ACKs, the sender continues to increase the cwnd additively until it reaches a certain threshold.
- If another congestion event occurs (packet loss or multiple duplicate ACKs), the sender reduces the cwnd by half and repeats the fast retransmit and fast recovery phases.
- This cycle of AIMD (additive increase, multiplicative decrease) continues, adapting the sender's transmission rate based on network conditions.
Here's a brief explanation of each component-
TCP Reno = Slow Start + AIMD + Fast Retransmit + Fast Recovery
- Slow Start- During the slow start phase, the sender gradually increases its transmission rate, starting with a small congestion window size and exponentially growing it for every received acknowledgment. This helps probe the network and find the optimal transmission rate.
- Additive Increase/Multiplicative Decrease (AIMD)- After slow start, TCP Reno switches to the congestion avoidance phase. In this phase, the congestion window increases linearly, typically by adding 1 MSS (Maximum Segment Size) for each round trip time. If packet loss is detected, indicating network congestion, TCP Reno performs multiplicative decrease by halving the congestion window.
- Fast Retransmit- When the sender receives multiple duplicate acknowledgments for the same data segment, it assumes that a packet has been lost in the network. Instead of waiting for a timeout, TCP Reno performs a fast retransmit by retransmitting the missing packet immediately.
- Fast Recovery- After performing a fast retransmit, TCP Reno enters the fast recovery phase. During this phase, instead of reducing the congestion window to the initial value as in TCP Tahoe, TCP Reno reduces it to approximately half of the current congestion window. This allows for a more efficient recovery from packet loss without completely resetting the congestion window.
Now let's look at TCP New Reno. TCP New Reno is an extension of TCP Reno, enhancing its congestion control mechanisms. It improves upon TCP Reno's response to multiple packet losses within a single window of data. TCP New Reno aims to minimise unnecessary retransmissions and maximise network throughput. Let's explore TCP New Reno with an example.
An example with below Assumptions
- The sender has unlimited data to send.
- The initial congestion window (cwnd) is 10 segments.
- Packets 3 and 4 are lost.
- Initially, the sender sends 10 packets into the network without waiting for any ACKs.
- The sender receives ACKs for packets 1 and 2, increasing the cwnd by 2. Thus, cwnd becomes 12.
- The sender continues sending packets 11 and 12.
- When the receiver detects the packet loss of packets 3 and 4, it generates duplicate ACKs for packet 2.
- Upon receiving the duplicate ACKs, the sender retransmits the missing packets (3 and 4) immediately, without waiting for a timeout.
- The sender keeps track of the last ACK received (ACK 2) and enters a state called "partial ACK."
- Upon receiving the partial ACK for packet 2, the sender knows that packets 3 and 4 were received by the receiver. The sender retransmits packet 4 and continues sending new packets.
- The sender receives ACKs for the retransmitted packet 4 and the subsequent packets.
- The sender recognises that it has received a cumulative ACK for packet 4, indicating that all previous packets (1, 2, 3, and 4) have been successfully received.
- Based on the cumulative ACK, the sender exits the partial ACK state and resumes normal congestion control behaviour, adjusting the cwnd using AIMD (Additive Increase/Multiplicative Decrease).
- The sender continues sending new packets, incrementing the cwnd additively for every ACK received, and reducing the cwnd multiplicatively when packet loss is detected.
In TCP New Reno, the primary difference lies in its handling of multiple packet losses within a single window of data. It avoids unnecessary retransmissions by recognising partial ACKs, allowing for more efficient recovery from packet loss and improving network throughput.