Hi Martin, Sorry for the delay. Apache portion of monitrc below:
check process Apache with pidfile /var/run/apache2.pid group www start program = "/etc/init.d/apache2 start" stop program = "/etc/init.d/apache2 stop" if totalcpu > 60% for 2 cycles then alert if totalcpu > 80% for 5 cycles then restart if totalmem > 500 MB for 5 cycles then restart if children > 250 then restart if loadavg(5min) greater than 10 for 8 cycles then restart if 3 restarts within 5 cycles then timeout On Sat, Aug 13, 2011 at 7:52 AM, Martin Pala <[email protected]> wrote: > Please can you post your monit configuration for apache service? > > If you're using the pidfile based monitoring, the pidfile should contain > the pid of the apache master process which is parent to all apache childs. > Monit then summarizes the memory of all its childs. > > If you're using the pattern matching process monitoring and multiple > processes match the pattern, then monit checks only the first matching > process - if this process is child, then it wont see the total memory usage > of the sibblings. > > Regards, > Martin > > > > On Aug 10, 2011, at 8:20 PM, Darhl Thomason wrote: > > I'm using Monit 5.2.5 running on Debian Squeeze > > When I look at my Monit web portal I see items similar to this: > > Apache <http://localhost:85/Apache> running 9d 3h 27m 0.0% 0.6% > [10692 kB] > But when I do 'ps aux | grep apache' I get: > root@mail:/# ps aux | grep apache > www-data 2009 0.0 0.8 44528 13404 ? S Aug09 0:22 > /usr/sbin/apache2 -k start > www-data 4941 0.0 0.8 44524 13248 ? S Aug09 0:07 > /usr/sbin/apache2 -k start > root 5194 0.0 0.0 3300 740 pts/1 S+ 11:11 0:00 grep > apache > www-data 5733 0.0 0.8 44524 13096 ? S Aug09 0:18 > /usr/sbin/apache2 -k start > www-data 8829 0.0 0.8 44524 13108 ? S Aug09 0:16 > /usr/sbin/apache2 -k start > www-data 9411 0.0 0.8 44524 13112 ? S Aug09 0:15 > /usr/sbin/apache2 -k start > www-data 9423 0.0 0.8 44524 13104 ? S Aug09 0:28 > /usr/sbin/apache2 -k start > www-data 13388 0.0 0.8 44256 12500 ? S 06:05 0:01 > /usr/sbin/apache2 -k start > www-data 13484 0.0 0.8 44524 12940 ? S 06:06 0:00 > /usr/sbin/apache2 -k start > www-data 17911 0.0 0.3 38296 5736 ? S 06:22 0:00 > /usr/sbin/apache2 -k start > www-data 22802 0.0 0.8 44524 13120 ? S Aug09 0:10 > /usr/sbin/apache2 -k start > root 24120 0.0 0.6 38160 10692 ? Ss Aug01 1:08 > /usr/sbin/apache2 -k start > > it adds up to 8.1% memory. Why is it only reporting 0.6% Memory? > > There are other/similar items examples Amavis, Spamassassin, etc. > > Thanks! > > Darhl > > -- > To unsubscribe: > https://lists.nongnu.org/mailman/listinfo/monit-general > > > > -- > To unsubscribe: > https://lists.nongnu.org/mailman/listinfo/monit-general >
-- To unsubscribe: https://lists.nongnu.org/mailman/listinfo/monit-general
