Pcornel
Networking · Network & Protocols › TCP, UDP & Transport

TCP Retransmission, PMTUD & MSS Reference

Cheat sheet · https://pcornel.dk/topic.php?topic=283

Back to the Topic

Answer

A retransmission is TCP resending data that was not acknowledged — normal in small numbers. The commonest systematic cause is packets too large for the path, which is where MSS and path MTU discovery come in.

Remember

Look at the pattern: only full-size segments resent while small ones pass is an MTU problem; scattered single losses are a lossy path; bursts with rising delay are congestion. Clamp the MSS on tunnels (ip tcp adjust-mss) and let the ICMP "fragmentation needed" messages through.

First checks

  • ss -ti dst <ip> — retransmissions, round-trip time and learned path MTU.
  • netstat -s | grep -i retrans — system totals.
  • ping -M do -s 1472 <ip> — does a full 1500-byte packet pass unfragmented?
  • Wireshark: tcp.analysis.retransmission, tcp.analysis.duplicate_ack.

Commands

ss -ti
ip tcp adjust-mss 1360

Verify in this order

MSS announced from each interface MTU → smaller link on the path → clamp or ICMP feedback lowers the segment size → segments fit end to end → retransmissions rare and quickly recovered

Where it usually breaks

media/optics → administrative state → carrier/line protocol → negotiation → error/drop counters → neighbor discovery → upper-layer adjacency

Read-only verification commands unless stated otherwise. Confirm syntax for your platform and release. Full reference: https://pcornel.dk/topic.php?topic=283

Confirmation

Confirm action

Continue?