telecom • networking • design

an EventHelix.com blog


1 Comment

TCP fast retransmit and recovery

TCP Slow Start and Congestion Avoidance lower the data throughput drastically when segment loss is detected. Fast Retransmit and Fast Recovery have been designed to speed up the recovery of the connection, without compromising its congestion avoidance characteristics.

Fast Retransmit and Recovery detect a segment loss via duplicate acknowledgements. When a segment is lost, TCP at the receiver will keep sending ack segments indicating the next expected sequence number. This sequence number would correspond to the lost segment. If only one segment is lost, TCP will keep generating acks for the following segments. This will result in the transmitter getting duplicate acks (i.e. acks with the same ack sequence number)

Click here for TCP fast retransmit and recovery sequence diagrams

TCP fast retransmit

The transmitter acts on duplicate acks and retransmits the packet, without waiting for the segment timer expiry

TCP fast recovery

TCP maintains the current data flow

Click here for TCP fast retransmit and recovery sequence diagrams

Advertisements


Leave a comment

TCP congestion avoidance flow

We have already seen that TCP connection starts up in slow start mode, geometrically increasing the congestion window (cwnd) until it crosses the slow start threshold (ssthresh). Once cwnd is greater that ssthresh, TCP enters the congestion avoidance mode of operation. In this mode, the primary objective is to maintain high throughput without causing congestion. If TCP detects segment loss, it assumes that congestion has been detected over the internet. As a corrective action, TCP reduces its data flow rate by reducing cwnd. After reducing cwnd, TCP goes back to slow start.

We examine congestion avoidance in detail. We examine in detail how TCP reacts to the loss of a segment. The changes to the congestion window and the transition into slow start are covered in detail.

TCP congestion avoidance sequence diagram