[mythtv-users] Backend Crashes / Status Monitoring
David
myth at dgreaves.com
Tue Mar 22 20:18:40 UTC 2005
It must be the time of year :)
I'm installing a full blown Nagios setup for my network but for my myth
box I run 'monit'
The config file I use is below (there's a patch accepted by the Debian
maintainer to allow 'delayed' startup so it doesn't 'flap' the service -
contact me if you like).
Simple Debian/knoppmyth install : apt-get install monit
It monitors processes and restarts them if they fail.
Can be configured to alert you (I like to know if it crashes in case it
gets serious!)
It is 'secure'able
Has a web interface to check status and log
Can also monitor anything else (eg listings downloads, disk space etc)
I installed festival to speak the warnings too <grin>
It's a shame it's been stable :(
David
# Monit control file
#
# Comments begin with a '#' and extend through the end of the line.
# Blank lines between program entries are ignored. Keywords are case
# insensitive. All path's MUST BE FULLY QUALIFIED, starting with '/'
#
set daemon 30
set logfile /var/log/monit.log
set mailserver smtp.dgreaves.com
set mail-format
{ from: monit at bao.dgreaves.com }
set alert root at dgreaves.com # Send alert to system admin on any event
set httpd port 2812 and
allow ash.dgreaves.com
allow 10.0.0.90
allow 127.0.0.1
allow haze.dgreaves.com
allow admin:monit # user 'admin' with password 'monit'
check process mythbackend with pidfile /var/run/mythtv/mythbackend.pid
group mythtv
start program = "/etc/init.d/mythtv-backend start"
stop program = "/etc/init.d/mythtv-backend stop"
if failed port 6544 then restart
mode manual
depends on mysql
check process mysql with pidfile /var/run/mysqld/mysqld.pid
group mythtv
start program = "/etc/init.d/mysql start"
stop program = "/etc/init.d/mysql stop"
if failed port 3306 then restart
mode manual
More information about the mythtv-users
mailing list