The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

httpd failed...

Discussion in 'General Discussion' started by ethix, Aug 4, 2007.

  1. ethix

    ethix Active Member

    Joined:
    Dec 21, 2004
    Messages:
    44
    Likes Received:
    0
    Trophy Points:
    6
    Location:
    Australia
    im running WHM 11.2.0 cPanel 11.6.0-R15076
    CENTOS Enterprise 4.5 i686 - WHM X v3.1.0
    (VPS)
    and everytime an account is created or terminated within 10 minutes httpd failes

    here is the error log at the time i terminated an account
     
  2. ddeans

    ddeans Well-Known Member

    Joined:
    Feb 13, 2004
    Messages:
    296
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Maryland
    This seems to be pretty common with cPanel 11, I am sure that it will be fixed soon.. If you restart httpd, I assume that it works fine right? If so, use this code, it will check apache to see if it is running, and if it fails, it will automaticially restart it. This is only a temporary fix, but cPanel will soon have this issue resolved.

    Code:
    #!/bin/sh
    #
    # Apache Process Monitor
    #
    checkapache=`ps ax | grep -v grep | grep -c httpd`
    if [ $checkapache -le 0 ]
    then
    /usr/local/apache/bin/apachectl startssl
    fi
    Name the file apachemonitor.sh and place it under the /etc directory

    Set cron to run this:

    Code:
    */1 * * * * sh /etc/monitor-apache.sh > /dev/null 2>&1
    It will check apache every minute to ensure that it is running. I am using it on one of my boxes that has cPanel 11 and it keeps it going, but again, this is only a temporary fix.
     
  3. ethix

    ethix Active Member

    Joined:
    Dec 21, 2004
    Messages:
    44
    Likes Received:
    0
    Trophy Points:
    6
    Location:
    Australia
    ok thanks mate :)
     
  4. Bravo

    Bravo Well-Known Member

    Joined:
    Oct 30, 2001
    Messages:
    71
    Likes Received:
    0
    Trophy Points:
    6
    Same here, running R16448
     
  5. mambovince

    mambovince Well-Known Member

    Joined:
    Jan 15, 2005
    Messages:
    192
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    London, UK
    I thought cPanel automatically checks this and restarts http in case of failures?:confused:

    - Vince
     
  6. cPanelDavidG

    cPanelDavidG Technical Product Specialist

    Joined:
    Nov 29, 2006
    Messages:
    11,279
    Likes Received:
    8
    Trophy Points:
    38
    Location:
    Houston, TX
    cPanel Access Level:
    Root Administrator
    That is correct for all services cPanel uses (including cpsrvd itself). However, it's generally considered prudent that if a service is frequently crashing that you try to determine what is causing the crash and take corrective action.

    Additionally, these checks are performed once every 8 minutes, so theoretically a service can be down close to 8 minutes before it is automatically restarted.
     
Loading...

Share This Page