Server has more TIME_WAIT connections in Apache(port 80)
Hi,
My webserver has 16GB of RAM and CentOS 5.5, Apache 2.2.3, It's shared webserver used of for webhosting. I have optmized the server as :
<IfModule prefork.c>
StartServers 8
MinSpareServers 10
MaxSpareServers 20
ServerLimit 2150
MaxClients 2000
MaxRequestsPerChild 8000
</IfModule>
Timeout 90
MaxKeepAliveRequests 100
Server is not using Worker MPM, however just assign the following values.
<IfModule worker.c>
StartServers 8
MaxClients 2150
MinSpareThreads 25
MaxSpareThreads 75
ThreadsPerChild 25
MaxRequestsPerChild 8000
</IfModule>
More number of TIME_WAIT Connections on server still exists.
[root@server ~]# netstat -an|grep ":80"|awk '/tcp/ {print $6}'|sort -nr| uniq -c
1681 TIME_WAIT
2 SYN_RECV
4 LISTEN
3 LAST_ACK
7 FIN_WAIT1
6 ESTABLISHED
3 CLOSING
[root@server ~]# netstat -tan |grep :80|grep TIME_WAIT |wc -l
1776
Server Load Avg: 2.36, 2.45, 2.79
Please help me how to reduce the TIME_WAIT connections.
Thanks,
Jay
|