有线上设备系统日志频繁输出:

TCP: time wait bucket table overflow 

解决办法:

# vim /etc/sysctl.conf
tcp_max_tw_buckets =200000 #改值的默认值是18w
net.ipv4.tcp_syncookies = 1
net.ipv4.tcp_tw_reuse = 1
net.ipv4.tcp_tw_recycle = 1
net.ipv4.tcp_fin_timeout = 10
# sysctl -p #让参数生效

含义:

net.ipv4.tcp_tw_reuse = 1 表示开启重用。允许将TIME-WAIT sockets重新用于新的TCP连接,默认为0,表示关闭; net.ipv4.tcp_tw_recycle = 1 表示开启TCP连接中TIME-WAIT sockets的快速回收,默认为0,表示关闭。 
net.ipv4.tcp_fin_timeout = 10s 修改系統默认的TIMEOUT时间,默认是60s.

以上内容全文整理自:https://blog.csdn.net/wyl9527/article/details/78556964

其他参考:http://blog.51cto.com/benpaozhe/1767612

Related Posts: TCP: time wait bucket table overflow 解决方案 :

avatar