CLOSE_WAIT status slowing down my web service?


I have a web server running WIN2K. iPlanet Web Server Enterprise Edition 6.0. A lots of my clients/users are complaining that there is a dramatic reduce in speed connecting to my web server. Sometime, they cant even get the page. I did a netstat n and I saw a lot of  CLOSE_WAIT status (more than 100). I suppose it took up a lot of my servers resources When I did a reboot on the web server, the CLOSE_WAIT status are gone and the connection speed to my server resume.

Can anyone please advise me if there is any way I can kill the service and how do I reduce the number of CLOSE_WAIT status? Or is there a way to configure the parameter as to increase the performance of my web server?

I will appreciate for all the advice given. Thanks
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

What web server? IIS or Apache?
anglsAuthor Commented:
It is iPlanet Web Server Standard Edition 6.0
Hmmm. The CLOSE_WAIT status is a state in which a socket goes waiting for the other end to also close the socket. It also waits in case any lost packets arrive, since the packet is destined for a port which might get reused and hence the new owner would get an unsolicited message.

Now, the number of ports available for backward connections (which is the majority of these close-wait sockets) is around 24,000 (16 bit port number of which those below 8K don't get used), so you won't run out of those. Each socket under Unix becomes effectively a file descriptor so the number of open files (Kernel parameter) should be made as high as possible.

That said however, the normal situation is that a listener (like INet) wakes up a process and passes the incomming connection to it. This process then produces the response and closes the connection.

It is very unlikely that an incomming connection cannot be allocated a socket number since they are all in close-wait. It is more likely that there is no process available to process the connection, since they are all busy dealing with other connections.

I would suggest that you post a question regarding "How to optimise my IPlanet Web Server", since there are people here who have dones such things. I very much doubt that it is a socket problem.


Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Web Servers

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.