linux TCP/IP参数优化 sysctl.conf

查看TIME_WAIT连接数量

netstat -an | grep TIME_WAIT -wc

快速关闭TIME_WAIT连接

vi /etc/sysctl.conf

net.ipv4.tcp_tw_recycle = 1

net.ipv4.tcp_tw_reuse = 1

生效

sysctl -p

sysctl -p /etc/sysctl.conf

参考:

Linux内核 TCP/IP、Socket参数调优

http://blog.csdn.net/beyondlpf/article/details/52871932

相关推荐