From dd9a6048bb109494072d94281701ad9734d2b275 Mon Sep 17 00:00:00 2001 From: My Name Date: Thu, 11 Dec 2014 00:47:01 +0100 Subject: Added ZNC init + monit script, rtorrent + zabbix-server monit config and fixed typos --- monit/memcached.conf | 2 +- monit/nginx-vhost.conf | 2 +- monit/rtorrent.conf | 10 ++++++++++ monit/zabbix-server.conf | 7 +++++++ monit/znc.conf | 5 +++++ 5 files changed, 24 insertions(+), 2 deletions(-) create mode 100644 monit/rtorrent.conf create mode 100644 monit/zabbix-server.conf create mode 100644 monit/znc.conf (limited to 'monit') diff --git a/monit/memcached.conf b/monit/memcached.conf index 49f8875..947b632 100644 --- a/monit/memcached.conf +++ b/monit/memcached.conf @@ -1,4 +1,4 @@ -check process with pidfile /var/run/memcached.pid +check process memcached with pidfile /var/run/memcached.pid start program = "/etc/init.d/memcached start" stop program = "/etc/init.d/memcached stop" if failed host localhost port 11211 protocol MEMCACHE then restart diff --git a/monit/nginx-vhost.conf b/monit/nginx-vhost.conf index 1a33323..a34ea1a 100644 --- a/monit/nginx-vhost.conf +++ b/monit/nginx-vhost.conf @@ -1,6 +1,6 @@ server { listen 443 ssl; - server_name monit.example.org + server_name monit.example.org; ssl_certificate /etc/nginx/ssl/example.crt; ssl_certificate_key /etc/nginx/ssl/example.key; diff --git a/monit/rtorrent.conf b/monit/rtorrent.conf new file mode 100644 index 0000000..052498c --- /dev/null +++ b/monit/rtorrent.conf @@ -0,0 +1,10 @@ +check process rtorrent with pidfile "/var/run/rtorrent.pid" + start program = "/etc/init.d/rtorrent start" + stop program = "/etc/init.d/rtorrent stop" + if 2 restarts within 3 cycles then timeout + if totalmem > 100 Mb then alert + if children > 255 for 5 cycles then stop + if cpu usage > 95% for 3 cycles then restart + if failed host 127.0.0.1 port 5000 then restart + if 3 restarts within 3 cycles then alert + if 5 restarts within 5 cycles then timeout diff --git a/monit/zabbix-server.conf b/monit/zabbix-server.conf new file mode 100644 index 0000000..7f75704 --- /dev/null +++ b/monit/zabbix-server.conf @@ -0,0 +1,7 @@ +check process zabbix_server with pidfile /var/run/zabbix/zabbix_server.pid + start program = "/etc/init.d/zabbix-server start" + stop program = "/etc/init.d/zabbix-server stop" + if failed port 10051 type tcp for 3 times within 5 cycles then alert + if failed port 10051 type tcp for 5 times within 10 cycles then restart + if 3 restarts within 3 cycles then alert + if 5 restarts within 5 cycles then timeout diff --git a/monit/znc.conf b/monit/znc.conf new file mode 100644 index 0000000..b4c4d4d --- /dev/null +++ b/monit/znc.conf @@ -0,0 +1,5 @@ +check process ZNC with pidfile /var/run/znc.pid + start program = "/etc/init.d/znc start" + stop program = "/etc/init.d/znc stop" + if failed host localhost port 9999 then restart + if 5 restarts within 5 cycles then timeout -- cgit v1.2.3