Monit 5.19/5.20 Crashes while check program
We're trying to monitor and automatically restarted different programs all belonging to a SAP Service. The Actions status, start and stop are executed via bash scripts that return 0 for success or 1, sometimes 2, for failure. Some services depend on others, like the sap instances depends on the Database. All checks except for the filesystem checks are check program checks. When starting the whole group monit crashes with:
[CET Nov 11 13:46:19] critical : AssertException: P raised in Process_exitStatus at src/system/Command.c:293
The Function which throws the exception is: https://bitbucket.org/tildeslash/monit/src/6b0a4690ae7cc1374d55d2444537f3acef75a0cf/libmonit/src/system/Command.c?at=master&fileviewer=file-view-default#Command.c-293
A monit 5.17.1 works without crashes with everything else the same.
The monit log with -vv, a stracelog and the config is attached.
Comments (2)
-
repo owner -
repo owner - changed status to resolved
Fixed: Issue
#501: check program may fail when parent service is not monitored every cycle and multiple services depend on it.→ <<cset 4b32d8b6bddc>>
- Log in to comment
will fix
the problem should be also resolved in Monit 5.20 by configuration change ... for example service "sapdb_VRO" depends on "saphostservices", and service "sapinstance_VRO_ASCS01_vravroci" depends on "sapdb_VRO" - it's not necessary to explicitly repeat the dependency on "saphostservices" in the context of "sapinstance_VRO_ASCS01_vravroci", as it is part of the dependency graph automatically.
Current dependency configuration (excerpt):
Suggested dependency simplification (still sets the correct dependency):