how can i stop a script that runf for 90 hours

Discussion in 'PHP' started by arambo, Mar 27, 2009.

  1. #1
    how can i stop a script that runf for 90 hours
    i have a script that runs for 90 hours and sometimes i want to stop it before this time

    how can i do this ?
     
    arambo, Mar 27, 2009 IP
  2. jestep

    jestep Prominent Member

    Messages:
    3,659
    Likes Received:
    215
    Best Answers:
    19
    Trophy Points:
    330
    #2
    You can put:

    set_time_limit($time_in_seconds);

    at the top of the script if you want to limit the time. You can also restart apache and it will kill any running script. If you have ssh ability, you can kill the process.

    use:

    ps

    to find the running process, and then:

    kill process_number

    to end the specific process.

    What are you running that would take this long to execute?
     
    jestep, Mar 27, 2009 IP
  3. ActiveFrost

    ActiveFrost Notable Member

    Messages:
    2,072
    Likes Received:
    63
    Best Answers:
    3
    Trophy Points:
    245
    #3
    You can stop it by closing your browser window :rolleyes:
     
    ActiveFrost, Mar 27, 2009 IP
  4. campolar

    campolar Peon

    Messages:
    2,683
    Likes Received:
    244
    Best Answers:
    0
    Trophy Points:
    0
    #4
    Say loudly "STOP", and if that doesnlt work, try saying this loudly "YOU FUC*ING SCRIPT, JUST STOP YOURSELF NOW, OR ELSE...."

    and if that also doesn;t work, just wonder WHY does it work for 90 hours? and use waht above posts said :D
     
    campolar, Mar 27, 2009 IP
  5. arambo

    arambo Peon

    Messages:
    218
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #5
    you people hhhhhhhhh
    i found an answear to use on off switch with mysql
     
    arambo, Mar 27, 2009 IP