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.

Apache dies regularly on RUID

Discussion in 'EasyApache' started by hkusulja, Dec 2, 2012.

  1. hkusulja

    hkusulja Registered

    Joined:
    Feb 3, 2010
    Messages:
    4
    Likes Received:
    0
    Trophy Points:
    1
    Hi,
    I have server with latest stable WHM/cPanel 11.34.0 (Update 9) with latest Apache 2.2.23, PHP 5.3.19 and mod_ruid2 compiled with EasyApache. I do not have suphp. CentOS 5.8 with all system updates, 64bit.

    Everything works like it should, except that sometimes (about every 4 or 24 hours) root apache process dies and then there are no httpd processes at all, so my HTTP service is stopped. I need to wait for my monit service to restart(start) apache and then everything again works, but this is about total of 10 minutes downtime for http service which is not acceptable.

    Problem did occur on last few versions of cPanel, PHP etc. also. I can not find root of cause and there is nothing about this logged in /etc/httpd/logs/error_log .

    Please help me troubleshoot and fix my problem.
     
    #1 hkusulja, Dec 2, 2012
    Last edited: Dec 2, 2012
  2. nospa

    nospa Well-Known Member

    Joined:
    Apr 23, 2012
    Messages:
    110
    Likes Received:
    0
    Trophy Points:
    16
    cPanel Access Level:
    Reseller Owner
    First of all, setup your own test (for example with cURL) that will restart apache if it will not be available (for example try to connect to localhost/whm-server-status etc). Then you will have some time to find cause of the problem. We had such problem before (without mod_ruid2) when we set wrong values for apache config in WHM (eg. start servers or max request per child etc).
     
  3. hkusulja

    hkusulja Registered

    Joined:
    Feb 3, 2010
    Messages:
    4
    Likes Received:
    0
    Trophy Points:
    1
    Hi, thank you for comment.
    Server and apache is normally working for html, static files and for php, etc. but sometimes apache service is suddenly stopped, i can not find reason or connection with any other stuff why and when is this happening, it is in random times, (maybe when server load goes a little higher?).
    I am monitoring using monit service every 10 minutes for http availability and if does not work, it restarts apache, however this is just small temp resolution it is not a fix.
    Fix is to find out, why is this happening, troubleshooting, see any error messages, and then trying to fix.
     
  4. prajithp13

    prajithp13 Member

    Joined:
    Jun 12, 2012
    Messages:
    20
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    India
    cPanel Access Level:
    Root Administrator
    add the following directive in your mod_ruid2 configuration file. The file is located in /usr/local/apache/conf/mod_ruid2.conf

    AcceptMutex posixsem

    Example configuration:

    <IfModule mod_ruid2.c>
    RMode config
    RDefaultUidGid nobody nobody
    RUidGid nobody nobody
    AcceptMutex posixsem
    </IfModule>

    This should fix your issue
     
  5. hkusulja

    hkusulja Registered

    Joined:
    Feb 3, 2010
    Messages:
    4
    Likes Received:
    0
    Trophy Points:
    1
    Thank you, i believe this is a solution. I will write if it happens again, but for now it seems it is running fine.
    Maybe cPanel should add this to their default configuration.

    And once more - Thank you,
    Kind regards
     
Loading...

Share This Page