I've got a problem, within monit my first time of using it ever so still noob in it but in any case, am expanding my horizons. What i have a problem is, this part :
check process apache with pidfile /var/run/httpd.pid
start program = "/etc/init.d/httpd start"
stop program = "/etc/init.d/httpd stop"
if cpu > 60% for 2 cycles then alert
if cpu > 80% for 5 cycles then restart
if totalmem > 200.0 MB for 5 cycles then restart
if children > 250 then restart
if loadavg(5min) greater than 10 for 8 cycles then stop
if failed host 192.168.1.2 port 80 protocol http
and request "/webwarning.htm"
then exec "/root/testing.bash"
# if failed port 443 type tcpssl protocol http
# with timeout 15 seconds
# then restart
if 3 restarts within 5 cycles then timeout
# depends on apache_bin
its the (then exec "/root/testing.bash") i thought this should execute my script file, but it just doesn't work, even though the file is set as executable and works fine if i just run it as normal from the konsole.
This test all works fine and before hand it was just a (then alert) and i changed it because i wanted it to run my script instead which doesn't seem to happen.
Does anyone have an idea as to what the problem could be