Service Monitoring

Forum for questions and support relating to the 1.29.x releases only.
Post Reply
Zmjm15
Posts: 90
Joined: Fri Jul 31, 2015 7:56 pm

Service Monitoring

Post by Zmjm15 » Sat Apr 30, 2016 11:18 am

Hi guys,

Was just wondering if anyone has managed to setup a monitoring service to alert when zoneminder service fails/stops?

Im just installing Monit and wondering how to implement it if anyone knows?


Many thanks

User avatar
iconnor
Posts: 710
Joined: Fri Oct 29, 2010 1:43 am
Location: Toronto
Contact:

Re: Service Monitoring

Post by iconnor » Sat Apr 30, 2016 1:59 pm

I use the following. Could probably be more robust.

check process zmdc.pl with pidfile /run/zm/zm.pid
if failed unixsocket /run/zm/zmdc.sock then restart
group zm
start program = "/bin/systemctl start zoneminder"
stop program = "/bin/systemctl stop zoneminder"

Zmjm15
Posts: 90
Joined: Fri Jul 31, 2015 7:56 pm

Re: Service Monitoring

Post by Zmjm15 » Sat Apr 30, 2016 3:46 pm

No thats good i searched forum and found where youve given this script before and its been working great.

Now i just have to learn how to get email alerts from monit!

Many thanks

Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests