2

it seems that by default starting monit the first time when there is no state file(my state file gets blown away on reboot) will start all processes in monitored mode. I want to start the daemon in unmonitored mode, then start up each processes individually using "monit start" commands.

i can't seem to find any documentation in monit on how to do this.

1 Answer 1

3

On Ubuntu there is a script that gets run as soon as monit starts if it exists.

/etc/monit/monit_delay

You can simply add a monit unmonitor all to this script. And all monitoring will get disabled basically as soon as the service starts.

4
  • This works, but I'm trying to understand exactly what monit is doing. Does monit just run every script in this directory before starting the daemon? I can't find anything about this in the man page.
    – richmb
    Oct 1, 2013 at 20:57
  • The Debian/Ubuntu startup script runs it. See /etc/init.d/monit.
    – Zoredache
    Oct 1, 2013 at 21:32
  • Thanks! I'd upvote, but I don't have enough rep.
    – richmb
    Oct 2, 2013 at 12:48
  • Any idea how to do something similar on CentOS? I suppose I could manually modify /etc/init.d/monit, if need be.
    – Nick Allen
    May 11, 2016 at 15:37

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .