[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Sometimes when restarting Monit it resets all services to unmonitore
From: |
Ciprian Dorin Craciun |
Subject: |
Re: Sometimes when restarting Monit it resets all services to unmonitored |
Date: |
Fri, 7 Aug 2020 16:41:10 +0300 |
OK... I've tried the following combinations and these were the outcomes:
* `mode passive onreboot nostart` -- on system reboot none of the
services or items are monitored;
* `mode passive` -- on system reboot **all** services and items are
monitored, regardless if before the reboot some were marked an
"unmonitored";
* `mode passive onreboot laststate` -- on system reboot Monit appears
to keep the monitored state as was before the reboot;
Additional observations:
* this monitoring reset seems to happen **only** on reboot, but
**not** on restarting of the Monit service; my assumption is that
Monit detects a system reboot and behaves differently;
* although I have `start` / `stop` / `restart` commands defined, and I
have `if not exist then alert`, I don't know if Monit tries or not to
start some services automatically; (based on what Lutz Mader said, I
would assume it won't;)
My conclusion: the "correct" setting should be `mode passive onreboot
laststate`.
Hope it helps,
Ciprian.