Error 408 Request Timed out on 1 site only ?

Discussion in 'Install/Configuration' started by eva2000, Dec 7, 2004.

  1. eva2000

    eva2000 Member

    My vBulletin forum is on a litespeed web server powered server which also hosts Disboards.com forums.

    Problem is for the past 2-4 days I haven't been able to load my forums or site via domain or directly via IP address. I see the browser status bar "waiting for mydomain.com" but if I leave it long enough like this, the eventually the error message I get is from litespeed web server is as follows:

    Where do I increase this connection timeout value ? Or more importantly why would I only now experience this request timeout when the site has been fine before ?

    thanks

    George
    Last edited: Jan 28, 2011
  2. mistwang

    mistwang LiteSpeed Staff

    Welcome, George! :wink:

    Sorry about the downtime.
    It looks like a PHP problem from within lsws admin interface. 20 PHP Fast CGI instances are allocated for animeboards.com, normally, only 2-3 instances are used concurrently, but by the time I logon, all 20 PHP processes were hanging there, won't process any new requests, eventually the HTTP connection will be timed out by lsws.

    I happen have the admin login on disboards.com, so I restarted lsws from the web admin interface, it is ok now.

    Really need to logon that box and check those hanging PHP processes.

    I will PM Alex about this, see if we can figure something out.

    Best Regards,
    George
  3. mistwang

    mistwang LiteSpeed Staff

    Hi George,

    After intensive investigation on a server with similiar symptom (hanging PHP FastCGI processes), I think it is the fault of MySQL persistent connection in PHP, for more information please refer PHP documentation on www.php.net, section about persistent MySQL database connection.

    I had informed Alex about the PHP configuration change.

    Best Regards,
    George
  4. xing

    xing LiteSpeed Staff

    My two cents. If it is indeed mysql persistence problem, and you decide to disable them, use the following to get the most out of mysql performance.

    Configure thread_cache within my.cnf to be just high enough so that threads_created stat line does not increase. You'll have to monitor the mysql server during peak hours to see which value is best.

    If you have the above variable set correctly, non-persistent mysql connection will be as fast from php , espeically if using sockets, as compared to persistent ones.

    For me personally, using enabling mysql persistence within php had always caused severe scaling problems for me in the past.
  5. eva2000

    eva2000 Member

    thanks George :)

    i checked and my persistent connections in vB is disabled.

    but now having another problem since updating to PHP 4.3.10 on this server

    right now not properly parsing some PHP/MySQL stuff and intermittently the same problem is on Disboards.com as well as my own forums ?

    Also the documentation is pretty lite and trying to find out what the virtual host -> external app differences are between what disboards.com and mydomain.com have set or not set in them ?
    Last edited: Jan 28, 2011
  6. mistwang

    mistwang LiteSpeed Staff

    You are welcome. :)

    It should be a PHP problem, either caused by changes in 4.3.10 or some parameters in php.ini need to be tuned. The prebuilt PHP binary is configured with '--enable-magic-quotes' option, not sure it will affect any thing.
    Havn't heard any complaint from Alex yet. :)


    The PHP external app configurations for disboards.com and animeboards.com are almost identical, they share the same PHP binary and php.ini, only difference is the maximum number of concurrent connections, 20 for animeboards.com and 50 for disboards.com.
    So animeboards.com and disboards.com should behave exactly the same for the same PHP code. :)
  7. eva2000

    eva2000 Member

    okay seems to be working now.. i commented out in lsws's php.ini PHPA and Ioncube encoder and all works including my forum's /admincp panel

    btw, do .htaccess work with lsws ?

    there's a worm thing going around and the fix is this .htaccess entry

    but not sure if it will work with lsws ?

    thanks
  8. mistwang

    mistwang LiteSpeed Staff

    There is a new ioncube loader for php 4.3.10
    http://www.ioncube.com/php4.3.10_issues.php
    disboards needs ioncube loader for rating stuff.

    LiteSpeed has .htaccess, but not all Apache directives are supported right now, and .htaccess is not very efficient. Please use rewrite rules to block those requests, like

    Code:
    RewriteCond   %{HTTP_USER_AGENT}    .*lwp.*  [NC]
    RewriteRule     ^/                                               [F]
    Just add above rules under "Rewrite" tab for animeboards.com

    There is a bug in 2.0RC4 that "reload", "restart" links stop working if a "reload" had been performed from the web admin interface. So you need to restart lsws from command line after the configuration change. There is no service interruption during the restart, so please always use "restart" from the web interface for now. :)
  9. eva2000

    eva2000 Member

    1. how do you use lsws restart from command line ?
    2. seems my forums still have issues in /admincp but disboards.com doesn't after readding ioncube/PHPA..

    i noticed i'm using different PHP version now 4.3.8 ??

    scratches head... seems it's running Apache 1.3.31 now hmmm
  10. mistwang

    mistwang LiteSpeed Staff

    You need to find out where lsws is installed to, then use
    Code:
    bin/lswsctrl restart
    to restart it.

    Unless code is different, it should behave the same.

    Maybe Alex is working on the server, PM him. ;-)

Share This Page