Difference between revisions of "Monit"
Jump to navigation
Jump to search
↑ https://mmonit.com/monit/documentation/monit.html#ALERT-MESSAGES
Tags: Mobile web edit, Mobile edit |
|||
Line 4: | Line 4: | ||
== Installation == | == Installation == | ||
− | * Installation [[macOS]]: <code>brew install monit</code> | + | * Installation [[macOS]]: <code>[[brew install monit]]</code> |
* Linux: <code>[[apt install monit]]</code> | * Linux: <code>[[apt install monit]]</code> | ||
* Access: http://localhost:2812/ (admin/monit) | * Access: http://localhost:2812/ (admin/monit) | ||
Line 16: | Line 16: | ||
* Command: <code>[[monit status]]</code> | * Command: <code>[[monit status]]</code> | ||
* Restart Monit service: <code>systemctl restart monit.service && systemctl status monit</code> | * Restart Monit service: <code>systemctl restart monit.service && systemctl status monit</code> | ||
− | |||
== Example == | == Example == |
Revision as of 05:36, 14 June 2024
Monit is a free, open-source process supervision tool for Unix and Linux. Monit can restart a process automatically if process dies or monitor process characteristics, such as memory or cpu cycles and alert or execute and action. Monit only support alert messages by email[1]. Monit support monitoring cpu, memory, swap usage and loadavg among others.
Installation
- Installation macOS:
brew install monit
- Linux:
apt install monit
- Access: http://localhost:2812/ (admin/monit)
- Config file:
/etc/monit/monitrc
(monit -t
) to verify configuration file
set daemon 120
By default configured to check services every 120 seconds- Review examples: https://mmonit.com/wiki/Monit/ConfigurationExamples
- Logs:
/var/log/monit.log
- Command:
monit status
- Restart Monit service:
systemctl restart monit.service && systemctl status monit
Example
# check system $HOST # if loadavg (1min) per core > 2 for 5 cycles then alert # if loadavg (5min) per core > 1.5 for 10 cycles then alert # if cpu usage > 95% for 10 cycles then alert # if memory usage > 75% then alert # if swap usage > 25% then alert
Related commands
See also
- monit,
monit -t, monit status, /etc/monit/monitrc
- Monitoring: Prometheus, Cacti, monit, munin, RRDtool, Zabbix, Netdata, Nagios, Check MK, Icinga, Pingdom, OpsGenie and Datadog, Opsgenie, PRTG, Checkmk
- Monitoring: On call, Monitoring software, Monitoring services, Resource monitoring, Metric colletion tools, network monitoring, SLA Management Monitoring Tools, Alarm/Alert, Resource starvation, Alerts and notifications, Monitoring Kubernetes, VictoriaMetrics, Sensu, LogicMonitor, Distributed tracing, Datadog Monitors
Advertising: