Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

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.

Make cPanel restart Apache automatically as needed?

Discussion in 'General Discussion' started by 0884094, Mar 5, 2018.

  1. 0884094

    0884094 Member

    Joined:
    Nov 14, 2013
    Messages:
    10
    Likes Received:
    5
    Trophy Points:
    3
    cPanel Access Level:
    Root Administrator
    Hi all, I want cPanel/WHM to automatically restart the Apache service if it is down. Is there a built-in feature to make this happen?

    A few times a year, our cPanel server completely dies -- either shuts off or becomes completely unresponsive -- and so we reboot it. But then after the reboot, Apache isn't responsive, and we have to restart the service (or just reboot the server again). I've coded an AWS rule to automatically reboot when the server dies, and that works, but it comes back up in this state where Apache isn't working. I know that cPanel is aware that Apache isn't working because I get an email from chkservd saying "The service “httpd” appears to be down". That same email has a field "Number of Restart Attempts: 1" but there's no indication that it's tried to restart the service at all, and nothing ever works until a person logs in to restart everything. I think if I could make chkservd do 3x restart attempts instead of 1x it would fix my issue... any way to do that?
     
  2. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    43,279
    Likes Received:
    1,759
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Hello,

    You can enable monitoring for Apache via:

    "WHM Home » Service Configuration » Service Manager"

    If it isn't working as expected, feel free to open a support ticket using the link in my signature so we can take a closer look.

    Thank you.
     
Loading...

Share This Page