пятница, 18 января 2008 г.

CentOS. Настройка tcp-стека

/etc/sysctl.conf
# increase TCP max buffer size
net.core.rmem_max = 16777216
net.core.wmem_max = 16777216
# increase Linux autotuning TCP buffer limits
# min, default, and max number of bytes to use
net.ipv4.tcp_rmem = 4096 87380 16777216
net.ipv4.tcp_wmem = 4096 65536 16777216

# for Gigabit
#ifconfig eth0 txqueuelen 1000

# don't cache ssthresh from previous connection
net.ipv4.tcp_no_metrics_save = 1
# recommended to increase this for 1000 BT or higher
net.core.netdev_max_backlog = 2500
# for 10 GigE, use this
# net.core.netdev_max_backlog = 30000

net.ipv4.tcp_max_syn_backlog = 4096
net.ipv4.tcpsyn_cookies = 1
net.ipv4.tcp_fin_timeout = 30
net.ipv4.tcp_orphan_retries = 1

Комментариев нет: