-
-
Notifications
You must be signed in to change notification settings - Fork 350
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
introduce further handling and notifiers for ALARM status #2658
introduce further handling and notifiers for ALARM status #2658
Conversation
Signed-off-by: desertwitch <[email protected]>
Signed-off-by: desertwitch <[email protected]>
Signed-off-by: desertwitch <[email protected]>
Signed-off-by: desertwitch <[email protected]>
Signed-off-by: desertwitch <[email protected]>
Signed-off-by: desertwitch <[email protected]>
For further improvements down the road, perhaps we should also consider tracking |
Thanks, I hope to have some time to look at it this week. So far it started very intensively. |
Signed-off-by: desertwitch <[email protected]>
Signed-off-by: desertwitch <[email protected]>
Signed-off-by: desertwitch <[email protected]>
Signed-off-by: desertwitch <[email protected]>
Signed-off-by: desertwitch <[email protected]>
Signed-off-by: desertwitch <[email protected]>
Signed-off-by: desertwitch <[email protected]>
Signed-off-by: desertwitch <[email protected]>
Signed-off-by: desertwitch <[email protected]>
Signed-off-by: desertwitch <[email protected]>
Signed-off-by: desertwitch <[email protected]>
Thanks Jim, it's no stress at all, I've taken the liberty to broaden the scope here a bit where it made sense. 😉 |
❌ Build nut 2.8.2.2247-master failed (commit f8aaf4c1ea by @desertwitch) |
✅ Build nut 2.8.2.2248-master completed (commit f3f2049828 by @desertwitch) |
Signed-off-by: desertwitch <[email protected]>
Signed-off-by: Jim Klimov <[email protected]>
✅ Build nut 2.8.2.2282-master completed (commit f3f2b3361b by @jimklimov) |
As outlined in #2657,
dstate.c
setsALARM
as a common denominator status when encounteringups.alarm
variables reported through the different device-/manufacturer-specific implementations within the UPS drivers. Previously a user had to either rely on audible alarms by the UPS or (in an unattended setting) periodically check the UPS status and variables manually to be informed of potentially severe UPS device alarm states/conditions.This pull request introduces
ALARM
status handling inupsmon
as the remaining piece of the puzzle to effectively act upon UPS device alarms as raised by the UPS drivers. This includes notifiersALARM
andNOTALARM
for when the status is encountered and dissipates, respectively, allowing the user to now configure notifications and tasks e.g. throughupssched
.By default
upsmon
will treat any encounteredALARM
status as (potentially) severe enough to warrant an UPS being promoted to critical in a no-communication situation. This can, however, be unwarranted due to there being no common standard for what constitutes an alarm. In fact mundane alarm states were previously observed with UPS devices in HE/ECO mode, which could lead to unwarranted shutdown situations on minor connection hiccups. For this reason a0|1
settingALARMCRITICAL
was introduced intoupsmon.conf
, for such users to be able to preventupsmon
from treating theALARM
status as overly severe when it's not.As for the default behaviour (of considering such an UPS as volatile) erring on the side of caution seemed to be reasonable, as e.g. an alarm for some failing circuitry and the affected UPS later dropping offline should be concern enough for the UPS to be considered immediately critical and the system pre-emptively being shutdown e.g. by reduction/depletion of
MINSUPPLIES
.fixes #2657