Results 1 to 4 of 4

Hybrid View

  1. #1
    Join Date
    May 2004
    Location
    UK and Greece
    Posts
    337

    Question restart pache when load goes to 10?

    Hello,

    Does anyone knows a way to add a script in the cronjob that will restart apache as soon as the load reach the 10?

    Thanks

  2. #2
    CPU load reaches 10% ?

    If this is being caused by user downloads, you might be better off trying to implement mod_throttle or mod_bwshare.

    Also check out the 4th post down in this thread: http://www.webhostingtalk.com/showth...hreadid=389191
    Last edited by nick252; 03-28-2005 at 12:47 PM.

  3. #3
    Join Date
    Mar 2004
    Location
    Poland, Lublin
    Posts
    75
    make shell script like in php..
    script should do this steps:

    1. take current load (#uptime) and parse it
    2. if >10, then run restarting script.. and log it
    3. else .. nothing to do

    and add to cronjobs for every 15mins.. or 10mins.. or 5mins..

  4. #4
    Join Date
    Oct 2004
    Location
    UK
    Posts
    487
    What does "#uptime" have to do with the current CPU load?

    I know the basics of a script, but I don't know the exact script to get the CPU load from the server

Posting Permissions

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