Scenario
You are operating an OPNsense edge with the Monit plugin enabled. The following symptoms appear:
- Monit GUI shows no recent alerts and no current status
- A process the rule was watching is down but no alert fires
- System log shows Monit did not start, or restarted but never checks
Available evidence:
service monit statusreports “not running” or “configuration error”monit -treports parse errors on/usr/local/etc/monit.d/<rule>.conf- System log: “monit cannot parse configuration” or “monit daemon disabled”
Your task
Determine the cause, recover, document, and validate.
Investigation
The investigation follows the discipline taught in Part XXXIV:
- Form hypothesis, find evidence, test, validate.
- Use the available evidence above to bound the search.
- Reach one of the likely root causes.
Recovery procedure
(Do not reveal until you have reasoned through the problem.)
- Identify the failing component.
- Apply the remediation pathway.
- Validate with the verification step.
- Document the incident.
Remediation
service monit status. 2.monit -tto validate the config syntax. 3. Inspect/usr/local/etc/monit.d/for rules referencing missing services or paths. 4. Remove or fix the offending rule. 5.service monit restartand verify status.
Verification
Monit is running; GUI shows current status; the previously missed failure now triggers an alert.
Rollback
Disable broken rules individually until monit -t passes; restart Monit.
Prevention
After every major upgrade, run monit -t before relying on monitoring. Treat Monit rules as code: version them, review them in changes, and remove rules for services you no longer run. Test alerts by stopping a watched service in a controlled window.