Find the answer to your Linux question:
Results 1 to 4 of 4
Hi, I Googled for like 2 days without any results.If you can, please help. I'm using Centos 6.3 64bit running Apache 2.2.15 Apache works fine, but it stops responding after ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    May 2012
    Location
    Pretoria,South Africa
    Posts
    5

    Talking apache and CLOSE_WAIT connections


    Hi,

    I Googled for like 2 days without any results.If you can, please help.

    I'm using Centos 6.3 64bit running Apache 2.2.15
    Apache works fine, but it stops responding after a few minutes.
    The cause for this is that the connections never close.
    The connections will stay in a CLOSE_WAIT state.As soon as i restart apache it works again
    until the MaxClients are reached and then it stops responding again.

    OUTPUT:
    netstat -plant |grep CLOSE_WAIT:
    tcp 1 0 ::ffff:10.0.0.47:80 ::ffff:10.0.0.50:54140 CLOSE_WAIT 3498/httpd (Have like 600 of this)

    Any idea what might cause this?

    Thanks

  2. #2
    Just Joined!
    Join Date
    Sep 2012
    Location
    Finland
    Posts
    96
    This will help you with your quest.
    Configuring Apache for Maximum Performance LG #123

    KeepAlive and KeepAliveTimeout is the part that might interest you.
    Last edited by Peconet009; 09-26-2012 at 12:31 PM. Reason: Addition

  3. #3
    Just Joined!
    Join Date
    May 2012
    Location
    Pretoria,South Africa
    Posts
    5
    Hi,

    Did try it, doesn't make a difference to my problem.

    Thanks

  4. $spacer_open
    $spacer_close
  5. #4
    Linux Newbie
    Join Date
    Jun 2012
    Location
    SF Bay area
    Posts
    195
    Unless there's an Apache bug in play here, my guess is that you're only seeing requests turn into CLOSE_WAIT connections for URI's that are handled by code. Meaning static content isn't causing them. In very crude summary, CLOSE_WAIT means the OS knows the connection is dead (since the client indicated it was done) but the program that owns the local end of the connection hasn't called close() yet. So my suggestion is to track down what software is handling the requests and make sure it's closing connections properly.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •