Monit, and Apache2

Discussion in 'Server Operation' started by edge, Dec 23, 2007.

  1. edge

    edge Active Member Moderator

    After some "big" tweaks of my apache2.conf file I can not get Monit to monitor Apache2 anymore.

    I know that I need to set the Monit values (/etc/monit/monitrc) accordingly to what it's set in apache2.conf, but here is where I get lost!

    This is the part that I've changed in apache2.conf
    Now I need to set the correct values in "/etc/monit/monitrc"

    The monitrc files looks like this at the moment.
    Problem is that Monit is giving me a "Connection failed" on Apache with the new apache2.conf settings :/

    I think the problem is the "if totalmem > 700 MB for 5 cycles then restart", as when I take this line out, it's working fine.
    The monit document is saying this about totalmem:
    If I read the above correct I need to multiple ServerLimit by it's child processes (I guess that this is MaxRequestsPerChild)
    So.. 512 x 100 = 51200 MB.
    Wow.. 51200 MB... For sure this is wrong!.. Or.. Did I make a mistake in (1) the apache2.conf (setting MaxRequestsPerChild to 100) or (2) with my calculation for totalmem?

    Anyone here who's got more info on this?
     
    Last edited: Dec 23, 2007
  2. falko

    falko Super Moderator ISPConfig Developer

    I've taken out the totalmem line in my monit configuration. I was getting error messages saying that monit doesn't know that option. I guess that Debian's monit package isn't the newst one... ;)
     
  3. edge

    edge Active Member Moderator

    For now I have also removed it, but I would love to get the correct value for it.

    The monit version I'm using is 4.8.1, and it does take a "totalmem" option.
     

Share This Page