MTU, MSS and the packets that quietly disappear
Ping works, SSH works, the web server answers — and one file, one API call, one image upload hangs forever. That pattern is almost always an MTU problem, and it stays invisible because small packets fit and large ones do not.
Why small works and large does not
A TCP handshake is a few dozen bytes. A TLS handshake is a couple of kilobytes. When the path MTU is smaller than what the sender assumes, the first packets get through and the first full-size segment is dropped somewhere in the middle. Nothing reports the drop; TCP just retransmits and backs off.
Routers in the path are supposed to send ICMP “fragmentation needed”. Many networks filter that ICMP, which is exactly why this bug survives for months.
How to see it
Ping with a fixed size and the “do not fragment” bit:
ping -M do -s 1472 10.0.0.1
ping -M do -s 1400 10.0.0.1
ping -M do -s 1200 10.0.0.1
If 1472 fails and 1400 works, the path MTU is somewhere between 1428 and 1500. Then confirm on the host side — a socket stuck at a tiny MSS is a strong signal:
ss -tin dst 10.0.0.1
# look for: mss:536, retrans, lost
And on the wire, the retransmissions are visible without any guessing:
tcpdump -ni any -s 0 'host 10.0.0.1 and tcp' -c 200
What actually fixes it
- Lower the interface MTU where the tunnel or PPPoE link requires it (1492 for PPPoE, 1420–1450 for many tunnels).
- Clamp MSS on the router for traffic that crosses the smaller link —
TCPMSS --clamp-mss-to-pmtuin nftables or iptables. - Enable path MTU discovery on both ends, and make sure the ICMP that PMTUD needs is not filtered by your own firewall.
Then repeat the same three pings. The fix is boring, which is the point.