1. Please take a little time for this simple survey! Thank you for participating!
    Dismiss Notice

php script hangs server

Discussion in 'Plesk for Linux - 8.x and Older' started by codesmith, Jul 21, 2005.

  1. codesmith

    codesmith Guest

    0
     
    Hello,

    This isn't directly a Plesk question but since y'all are my favorite *nix support team.... :)

    While developing PHP scripts occasionally a script will go out of control, endless loop, etc. This is bringing our server to it's knees - loads of 45 or higher, sometime necessitating a manual reboot. Is there anything that can be done to 'throttle' apache so it times these out or not so much processing time goes to this?

    Thanks....
     
  2. jamesyeeoc

    jamesyeeoc Guest

    0
     
    There was a thread at WHT which dealt with a similar problem.

    Not sure if one of those suggestions will help you.
     
  3. serial-thrilla

    serial-thrilla Guest

    0
     
    two possible reasons:
    1. php bug.
    2. flaw in the script

    but regarding reason 2, i think php would disable the script after a certain amout of time leading me to think reason 1 is the problem.

    upgrade to the latest version of php...
    if that doesn't help, or you already have the latest, then submit a bug report.

    perhaps this will help you knock down the dam instead of trying to pump the water over it...
     
  4. codesmith

    codesmith Guest

    0
     
    Hmm I let this go and now I'm back at it. An endless loop on a PHP script definitely jumps the load on the server way high and I pretty much have to restart Apache to stop it.

    We have
    max_execution_time=90
    and memory_limit=32M

    to handle larger file uploads and Gallery stuff (thumbnail processing).

    I don't know why the max_execution_time is being ignored - the scrips go on forever. We are running safe_mode off but the script itself isn't overriding that. Apache Timeout is set to 300 seconds but can't tell if it should timeout something like this.

    Any other idears?
     
Loading...