monit is a free, open source process supervision tool for Unix and Linux.

learn more… | top users | synonyms

0
votes
0answers
7 views

Monitor logs with Monit?

I have a cluster of zookeepers that occasionally enters a state where they can not reconnect to each other without a restart. The best way to detect this condition, I believe, is to monitor the logs ...
2
votes
1answer
1k views

How to suppress monit alert if restart successful?

We only want to be alerted if the service fails to restart. Is this possible? That is if, on the first check the service is down then restart it and don't bother to send us an alert; but if the ...
0
votes
1answer
1k views

Configure Monit to monitor PHP5-FPM on Ubuntu/Nginx setup

System: LEMP running on Ubuntu 14.04 I'm trying to configure the tool Monit to restart Nginx or PHP-FPM if ever there is a problem. It is correctly monitoring Nginx however under status for PHP-FPM ...
0
votes
0answers
14 views

Running monit AND supervisord simulatenously. Any possible issues?

Two aims: 1) Make sure background daemons such as webserver/rabbitmq are running all the time. If they crash they are automatically restarted etc. For this I am using monit with a config like: set ...
0
votes
0answers
6 views

Monit cannot read content

I've installed the latest version of Monit and created a very basic rule: alert me when the word "Google" cannot be found on google.com (deface check). I keep getting following error: failed to [www....
0
votes
1answer
17 views

Monit showing 0 hosts connected

I am new to Monit. I have one VM and am trying to run M/Monit and Monit on the same server. I downloaded the binary for both and ran both processes. All M/Monit configs are default and I have not ...
0
votes
2answers
31 views

Simple tool to monitor HAProxy web requests?

I'm looking for a tool that can monitor the number of requests that are going to the nodes within HAProxy to determine the need to push out another node to loadbalance the requests. Can something like ...
-1
votes
1answer
28 views

How do I execute monit commands from a shell script without root access?

I've installed and configured monit on a Debian server and opened the http service to localhost and gave rw permissions to the group "monit". I created this group and added myself to this group. The ...
0
votes
0answers
16 views

How to restart nginx when getting 502, with Monit

In Monit, how can I check the health of my Nginx server (if it is returning 502, for example) and how to restart it when this occurs. The environment is an Ubuntu 14.04 64bit
0
votes
2answers
2k views

monit fails to start apache

I'm running Apache, and trying to monitor it wiht Monit. The monitoring seems to work fine, but when Apache is down, Monit does not succeed to start it. Monit does detect that it's down, but the ...
0
votes
0answers
20 views

Monitoring HAProxy to determine need to scale

I'm learning about load-balancing and auto scaling at the moment. I have a VM running HAproxy with 3 nodes under it to distribute traffic. My endgoal is to spam it to overload number of requests it ...
1
vote
1answer
1k views

Issues in monitoring apache tomcat server using Monit

I have installed Monit using the following command in Ubuntu Linux 12.04.1 server sudo apt-get install monit My main goal in using Monit is to restart my - MySQL and Apache tomcat services ...
-1
votes
2answers
76 views

Debian: How to upgrade MONIT correctly?

I did sudo apt-get install monit but it only installs version 5.9 and the current version is 5.17.1. So I did wget https://mmonit.com/monit/dist/binary/5.17.1/monit-5.17.1-linux-x64.tar.gz to download ...
0
votes
0answers
22 views

Monit run script on restart

So I have been trying to get Monit to run a script on start of a service. While Monit has no problem restarting the service, I of course want to be alerted when if my service required starting, not ...
-2
votes
0answers
93 views

Run your own python script in background [migrated]

I have my own python library which gets installed wide when I do this python setup.py install inside python project directory, it copies the executable file in bin also, but basically I am doing ...
-1
votes
1answer
30 views

Monit not able to start program in screen

I have monit able to watch the program but the start script is not working. The stop script works just fine. The when monit tries to start it, it just says execution failed. Monit part check ...
0
votes
1answer
13 views

“check file” in monitrc fails with syntax error

I have the following in /etc/monit/monitrc on line 130-131: check file ip-172-31-37-63:1.log with path /home/ubuntu/.vnc if match "Connections\: accepted" then exec /home/ubuntu/alerts/slack.rb ...
1
vote
1answer
2k views

monit does not run script after “if does not exist” check

I'm having trouble with monit. I have setup monitoring with monit. However, I'm having trouble with a check for the process running. If the process is not running, i want to run an specific script ...
1
vote
1answer
2k views

Monit check log file content

I am having a issue with Monits content check. I know I can check the log file like this check file test.log with path logs/test.log if not match "something" for 5 cycles then alert But the log ...
8
votes
4answers
5k views

How to disable Monit instance start/stop alerts?

Monit sends an alert every time the monit daemon is stopped or started. This is obnoxious and not useful information. According to the docs, I set: set alert user@mycompany.com but not on { ...
0
votes
1answer
1k views

Monit failed to start shell script

So I am having a problem with monit starting a process this is my code: check process program_1 matching "program_1" start program = "/home/user1/files/start.sh" stop program = "/home/user1/files/...
7
votes
1answer
8k views

how to set up monit to monitor disk-space

I use monit on my server to monitor apache and mysql running. Now I want to add an alert if the disk gets too full. I added this for testing in /etc/monit/monitrc: check device rootfs with path /dev/...
0
votes
0answers
18 views

Monit for PHP7 connection failed

Trying to get monit working for PHP7 but getting a connection error. Here is the config file: check process php7.0-fpm with pidfile /run/php/php7.0-fpm.pid group phpcgi start program = "/usr/sbin/...
1
vote
3answers
893 views

Monit: how do you stop monit from running the exec statement every time the test fails?

How do you stop monit from running the exec statement every time the test fails? The statement in my monitrc is: check filesystem tmpfs with path /var ...
0
votes
1answer
45 views

MONIT: Monitoring logfile on counting and changes of timestamp

I want to monitor a logfile and I am only interested in the "Received new block" lines. I need two different scripts to monitor a) the height, which should always be one number higher then the height ...
15
votes
2answers
4k views

Disable Monit alerts when PID changed

When you monitor a process with Monit by its pid, like : check process blop with pidfile /.../blop.pid start program = "..." stop program = "..." you get an alert when the pidfile is ...
2
votes
0answers
6 views

aggregation of monit alerts per cycle

I have a dozen of identical services configured in monit. When I enable alerts for check process on these services and alert condition arises in all of the services I receive a dozen of identical ...
2
votes
1answer
44 views

On restart, start with “monitor all” enabled

I have monit enabled and monitoring one of my applications, where if the application restarts more than 4 times in 10 cycles, I stop it, and run a script (which, among other action, also does ...
6
votes
2answers
2k views

Monit monitor http status with 404 page

I am trying to monitor HTTP status with 404 or 403 page. As you all know Monit takes those pages as failed connection, but how could I change that. I just want to monitor that it shows the 404 or 403 ...
0
votes
0answers
20 views

Configure alerts on failed Unicorn restart

Our setup looks like this: Ubuntu 14.04.4 LTS AWS Opsworks Chef 12 Monit 5.17 Ruby 2.3 Rails 4.0.8 And we managed to get everything working just nicely, yet however if for some reason, Unicorn ...
0
votes
0answers
26 views

Is it possible to visualize disk stats using Monit Graph?

I am using Monit and Monit Graph in order to monitor Mysql and Apache processes. I have found in monit documentation and in serverfault (also here) that I can monitor disk usage and get alerts. ...
0
votes
1answer
19 views

Monit is reporting low memory use

Monit is reporting very low memory use that is not consistent with actual use. If I look at Monit, under System I see "5.7% [918.0 MB]" though the real scenario is very different; total ...
1
vote
2answers
1k views

Monit http-based API

I'm just wondering whether monit has an API, which we could poll-regularly (perhaps something that is http-based) ? It would be very useful to create an integrated monitoring solution across multiple ...
0
votes
0answers
16 views

How to set maximum limit to monit exec?

I have monit setup on servers. I am sending out SNS on monit alerts as below. check filesystem "root" with path /dev/xvda1 if space usage > 80% for 10 cycles then exec "/bin/bash -c '/usr/...
4
votes
2answers
7k views

monit send email does not work

I am trying to use monit, and set up email server using gmail. The configuration file is like this: set mailserver smtp.gmail.com port 587 username "someuser@gmail.com" password "password" using ...
1
vote
1answer
42 views

Monit Web Service not available

I'm trying to configure monit on my server using chef solo. When I visit port 2812 response saying this webpage is not availble. config/chef/files/default/monitrc set daemon 30 set pidfile /var/run/...
0
votes
1answer
28 views

monit can not resolve hostname: getaddrinfo does not find host

I use monit v5.16 running on Debian Wheezy to check if a server is up or down using the ping instruction. Here is my configuration: check host my.server.domain with address my.server.domain ...
1
vote
2answers
184 views

Monitoring zabbix server (itself) externally

I have some infrastructure (servers, switches etc) monitored by a Zabbix server, setup to alert in case of issues; so far so good. But what if the Zabbix server itself (or any of the underlying infra)...
0
votes
2answers
47 views

Prevent monit from checking while restarting

We have the following monit config which restarts tomcat if unable to connect to it: check host Tomcat-Foo with address localhost stop program = "/usr/bin/systemctl stop tomcat.service" start ...
7
votes
5answers
5k views

Make monit wait longer before thinking something is dead

I'm trying to start a program (Resque) but it takes a bit of time before a pidfile is written. Thus, I think that Monit thinks the program hasn't started and starts one or two more programs before ...
0
votes
1answer
43 views

Nginx M/Monit password protect

I am trying to protect access to M/Monit web interface: Box: ubuntu 14.04 nginx 1.8.1 mmonit-3.5.1 I created a mmonit config file under /etc/nginx/sites-available: server { listen 8080; ...
6
votes
2answers
1k views

What's the point of using runit in combination with monit?

I see a lot of people using monit in combination with runit. Isn't that redundant? What is the point of using runit as well? Is it because it's more reliable when dealing with services (as it doesn't ...
1
vote
0answers
117 views

Monit “check program” and restart based on exit code

When I use check process, monit will start the program I define under start program then monit will restart it if it stops. But when I use check program monit will not automatically start it. If the ...
0
votes
0answers
14 views

Escalate monit events to pager address

is it possible to send escalating notification to pager address in case when monit test failed for n-times? We want to receive a pager beep only in case when monit tried to do its best and problem is ...
0
votes
0answers
35 views

Monit's $HOST variable expanding to “SYSTEM”

For some reason, Monit's $HOST variable is being expanded to "SYSTEM" which is causing problems for emailing (becomes "From: monit@SYSTEM"). The /etc/hostname and /etc/hosts files are correctly ...
0
votes
2answers
75 views

monit: Consolidated dashboard for monit running on multiple machines

I have monit setup on multiple machines. For Example: x.example.com:2812, y.example.com:2812 and z.example.com:2812. Is there a way so that we can see all these dashboards consolidated at one place ...
1
vote
0answers
42 views

monit: add NOALERT in an IF construct

On debian jessie, I have configured monit to check for HAproxy particular port forwardings, and to restart it if failed like this: check process haproxy with pidfile /run/haproxy.pid group www-...
1
vote
2answers
81 views

monit “check program” with email?

I have this in a monit script (lines 11-13): check program foo with path "/usr/local/bin/foo.sh" with timeout 300 seconds if status != 0 then alert dan@example.com monit reload says: /...
0
votes
0answers
43 views

How to monitor multiple instances of the same process with Monit

I have one process of which I need to run multiple instances. I would like to monitor this with Monit. Currently this is how I'm doing it. check program maintain_workers with path maintain_workers....
1
vote
3answers
3k views

Can't find httpd.pid to use for Monit apache2 monitoring

I'm new to Linux and I setup Ubuntu 12.04 on Digital Ocean. I installed Monit and got it to monitor MySQL successfully with email alert. I want to monitor Apache2 as well but cannot find any httpd....