set mailserver
mail.erfwerfwer.ru
USERNAME "fser@erfwer.ru"
PASSWORD "й423523452345"
set alert init@уцвцув.ru
set mail-format {from: цувцу@цувцувцу.ru}
check process mpd5 with pidfile /var/run/mpd5.pid
start program = "/usr/local/etc/rc.d/mpd5 start"
stop program = "/bin/sh -c 'kill `cat /var/run/mpd5.pid`'"
if cpu > 60% for 2 cycles then alert
if not exist then restart
if not exist for 2 cycles then alert
check process radiusd
matching "radiusd"
start program = "/usr/local/etc/rc.d/radiusd start"
stop program = "/usr/bin/killall radiusd"
if cpu usage > 95% for 10 cycles then restart
if cpu > 60% for 2 cycles then alert
if not exist then restart
if not exist for 2 cycles then alert
check process mysqld
matching "mysqld"
start program = "/usr/local/etc/rc.d/mysql-server start"
stop program = "/usr/bin/killall mysqld"
if cpu usage > 95% for 10 cycles then restart
if cpu > 60% for 2 cycles then alert
if not exist then restart
if not exist for 2 cycles then alert
check process db2dhcp
matching "db2dhcp"
start program = "/usr/local/etc/rc.d/db2dhcp.sh start"
stop program = "/usr/bin/killall db2dhcp"
if cpu usage > 95% for 10 cycles then restart
if cpu > 60% for 2 cycles then alert
if not exist then restart
if not exist for 2 cycles then alert
check process squid
matching "squid"
start program = "/usr/local/etc/rc.d/squid start"
stop program = "/usr/bin/killall squid"
if cpu > 60% for 2 cycles then alert
if not exist then restart
if not exist for 2 cycles then alert
check process named
matching "named"
start program = "/usr/sbin/named -t /var/named -u bind"
stop program = "/usr/bin/killall named"
if cpu usage > 95% for 10 cycles then restart
if cpu > 60% for 2 cycles then alert
if not exist then restart
if not exist for 2 cycles then alert
check process httpd
matching "httpd"
start program = "/usr/local/etc/rc.d/apache22 start"
stop program = "/usr/bin/killall apache22"
if cpu usage > 95% for 10 cycles then restart
if cpu > 60% for 2 cycles then alert
if not exist then restart
if not exist for 2 cycles then alert