|Considerations when using Monit with systemd
|Tue, 16 Apr 2019 13:01:03 +0100
Iâm successfully (and happily) using Monit to monitor services that have suddenly exited on a CentOS 7 setup. For example:
check process mariadb with pidfile /var/lib/mysql/hostname.pid
Â Â Â Â Â start program = "/bin/systemctl start mariadb"
Â Â Â Â Â stop program = "/bin/systemctl stop mariadb"
Â Â Â Â Â restart program = "/bin/systemctl restart mariadb"
Â Â Â Â Â if failed port 3306 protocol mysql then restart
Â Â Â Â Â if 3 restarts within 5 cycles then unmonitor
Do I need to do anything else to make Monit and systemd play together nicely? My concerns are:
1. What happens when the system is shutting down, does Monit frantically try to start things up that are shutting down, or has Monit itself been stopped by that point?
2. Is there are problem with Monit trying to start services at the same time systemd does at system boot time?
Thanks in advance!
|[Prev in Thread]
|[Next in Thread]