简体   繁体   中英

Detect all processes are running in monit

I'd like to run a script from monit after the status of all files/processes/file systems are accessible/running. Outside of writing a script to parse the output of monit status and monit summary , is there some functionality that would allow me to do this?

The way I've decided to accomplish this is run the script outside of monit and use the monit validate utility. This can be run whether or not the monit daemon is running and its exit status $? is 1 if it does nothing and 0 if it detects something is not running/accessible. It can also be run even if the monit daemon is not accessible from the command line (ie if you're not allowing localhost) or monit is not running in daemon mode.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM