I am sending an HTTP request with body that it is large enough for request to get segmented into multiple packets of sizes 374B (headers), 1500B and 199B.
Since some of our network equipment has a MTU of only 1430B and the packets have IPv4 "Don't fragment" flag set, the equipment rejects the packet of size 1500B and responds with ICMP Fragmentation needed, but "don't fragment" flag set. This packet ICMP packet has "MTU of next hop" of 1430B.
TCP then waits a bit and re-transmits the packet just at it was dropped as a result of network congestion (see Wireshark screenshot) and does not adjust the size of its segments.
Why won't TCP adjust the size of the segments, so the packet size would be smaller enough?
I am using:
- Java Apache HTTPClient library or curl 7.64.0
- Linux raspberrypi 4.19.86-v7+
- SIMCOM SIM7600G-H LTE Module
IPv4 headers of the large packet
ICMP packet that responds to the large packet (with "MTU of next hop: 1430B")
Edit: all traffic was captured at client device via tcpdump
.