Timeout Estimation
- SampleRTT from segment transition until ACK receipt
- Average several recent measurements
- Estimated = $(1-\alpha)e + \alpha s$ where $\alpha$ is typically $\dfrac{1}{8}\approx 10\%$
- Set timeout as EstimatedRTT + 4*std devRTT
- DevRTT = $(1-\beta)d + \beta*|s-e|$ where $\beta$ is typically $\dfrac{1}{4}$
- On RTO expiry
- Retransmit
- Double value
- Start timer
- Once new RTT, update using formula
3-way Handshake
…
Flow Control
- TCP receiver advertises free buffer
rwnd
- Sender limits amount of unACKed data
- Guarantees buffer won’t overflow
Congestion Control
- Assumption: all lost TCP segments are due to internet congestion
- Detecting loss
- Timeout event
- Fast retransmit
- Additive increase
- Multiplicative decrease (50%)
- Golden rule (AIMD)
- Motivated by TCP fairness—approaches fairness line