TCP:由于在10.0.0.1:443上过度重传,SACK已被禁用
TCP: SACK has been disabled due to excessive retransmissions on 10.0.0.1:443
ID: networking/tcp-sack-perf-downshift
版本兼容性
| 版本 | 状态 | 引入 | 弃用 | 备注 |
|---|---|---|---|---|
| Linux kernel 5.15 | active | — | — | — |
| Linux kernel 6.1 | active | — | — | — |
| Linux kernel 6.8 | active | — | — | — |
根因分析
当TCP连接经历高重传率时,内核会自动禁用TCP选择性确认(SACK)功能,这通常是由于数据包损坏或中间设备丢弃/损坏SACK选项所致。
English
The TCP Selective Acknowledgment (SACK) feature is automatically disabled by the kernel when the TCP connection experiences a high rate of retransmissions, often due to packet corruption or a misbehaving intermediate device that drops or corrupts SACK options.
官方文档
https://www.kernel.org/doc/html/latest/networking/ip-sysctl.html解决方案
-
ethtool -S eth0 | grep -i crc
-
ip route change 10.0.0.0/24 dev eth0 proto kernel scope link src 10.0.0.1 metric 100 tcp_sack 1
无效尝试
常见但无效的做法:
-
Setting net.ipv4.tcp_sack=0 to prevent the error from appearing.
90% 失败
This disables SACK entirely, which reduces throughput for all connections, and does not address the root cause (e.g., packet corruption or middlebox interference).
-
Increasing tcp_rmem and tcp_wmem to accommodate retransmissions.
70% 失败
Larger buffers may hide the symptom temporarily but do not fix the underlying issue causing retransmissions (e.g., faulty NIC or cable).