Summary

  • RFC 6298 builds the retransmission timeout from a smoothed round-trip estimate and its variation, and it refuses ambiguous samples that would teach the estimator the wrong story.
  • The first guess is one second, a lost SYN pushes the data timer to three, and every later expiry doubles the wait before the next attempt.

A sender fires off a segment and then hears nothing. No error, no receipt, no polite acknowledgement. Just the void. That silence could mean the segment died, the ACK died, or both are simply stuck behind a slow queue. Retransmit too early and you duplicate a packet onto a path that may already be choking. Wait too long and a real loss sits unrepaired while the application taps its foot. The retransmission timeout, RTO, is TCP's rule for choosing between those two mistakes without pretending it knows which one happened.

The estimate carries both time and its own uncertainty

Before a single round-trip sample exists, RFC 6298 says the sender should set RTO to one second, though a more cautious value is allowed. After the first measurement R, it sets SRTT = R, RTTVAR = R/2, and RTO = SRTT + max(G, 4*RTTVAR), where G is the clock granularity.

Later samples update the variation before the smoothed time: RTTVAR leans on the old SRTT with beta of one quarter, and SRTT then follows with alpha of one eighth. The order matters, because the variation term is really asking how surprising the new sample was next to the prior estimate. The fresh RTO is again SRTT plus the greater of clock granularity and four times the variation.

Round the result up to one second if it lands smaller. An implementation may cap the ceiling only at 60 seconds or more. Those bounds spell out the RFC's posture: you may be more conservative than the algorithm, never more trigger-happy.

Not every ACK teaches the clock

RFC 6298 requires Karn's algorithm. An ACK that arrives after a retransmission is a witness with a shaky memory: it may be acknowledging the first copy or the second. The sender must not turn that ACK into an RTT sample unless the TCP Timestamps option clears up the confusion. Without timestamps, take at least one measurement per RTT; timestamps can surface many more samples, but they do not suspend the estimator's rules.

This is a different job from PAWS. RFC 6298 reaches for timestamps only to identify which transmission produced an ACK. It does not use them to reject wrapped sequence numbers.

One timer, earliest outstanding data

When new data goes out and the retransmission timer is idle, the sender starts it at the current RTO. An ACK that covers all outstanding data stops it. An ACK that nudges the acknowledged frontier forward while data remains outstanding restarts it at the current RTO.

If the timer expires, TCP retransmits the earliest unacknowledged segment, doubles RTO, and restarts the timer at the doubled value. Exponential backoff makes each round of silence progressively more expensive to answer. A later clean RTT measurement can pull RTO back down; after several backoffs, an implementation may throw away SRTT and RTTVAR because those estimates may no longer describe the path at all.

The one-second opening has a specific exception. If a SYN times out while the implementation is running below three seconds, RTO must reset to three seconds once the connection is established and data starts flowing. The optimistic opening assumption is withdrawn the moment the path disproves it.

A timer is a control, not a diagnosis

An attacker can delay a timed packet to inflate RTO, or try to drive it down with forged traffic. The smoothing and backoff rules limit how far that game goes, but they do not authenticate delay. So read an RTO expiry as an action taken under uncertainty, not a verdict that a particular packet was lost.

The sole source is RFC 6298, published on the Standards Track in June 2011. It defines the normative timer algorithm and its historical rationale. It does not settle current implementation defaults, path RTT distributions, or vendor behavior.