Discussion:
Connections hanging in CLOSE_WAIT
(too old to reply)
Edgar Fuß
2011-11-22 22:08:14 UTC
Permalink
One of our web servers just ceased to function because there were 400 connection in CLOSE_WAIT state, thus lighttpd was running out of file descriptors.
Is there any known bug in 4.0/amd64 in this area?

--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-***@muc.de
Matthew Mondor
2011-11-22 22:43:42 UTC
Permalink
On Tue, 22 Nov 2011 23:08:14 +0100
Post by Edgar Fuß
One of our web servers just ceased to function because there were 400 connection in CLOSE_WAIT state, thus lighttpd was running out of file descriptors.
Is there any known bug in 4.0/amd64 in this area?
Does lighttpd support an option to disable TCP_LINGER? Otherwise, a
closed socket might remain in CLOSE_WAIT state until the remote end
also confirms the connection close. I would be surprised though if
lighttpd doesn't already disable that.

Thanks,
--
Matt

--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-***@muc.de
Matthew Mondor
2011-11-23 07:42:43 UTC
Permalink
On Tue, 22 Nov 2011 17:43:42 -0500
Post by Matthew Mondor
Does lighttpd support an option to disable TCP_LINGER? Otherwise, a
closed socket might remain in CLOSE_WAIT state until the remote end
also confirms the connection close. I would be surprised though if
lighttpd doesn't already disable that.
I meant set SO_LINGER to a delay of 0 seconds using setsockopt(2)...
--
Matt

--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-***@muc.de
Edgar Fuß
2011-11-23 11:24:41 UTC
Permalink
Sorry, it looks like my brain had confused CLOSE_WAIT with TIME_WAIT.
As most connections are hanging in CLOSE_WAIT with no data to send, it looks more like an application error, i.e. lighttpd not closing sockets it should be closing.
--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-***@muc.de
Loading...