[Nut-upsuser] ONLINE + LOWBATT shutdown
clepple at gmail.com
Tue Mar 9 02:57:15 GMT 2021
On Mar 8, 2021, at 5:38 PM, Lee Damon via Nut-upsuser <nut-upsuser at alioth-lists.debian.net> wrote:
> On 3/8/21 2:05 PM, Manuel Wolfshant wrote:
>> calibrating should not trigger nut
> I agree, it shouldn't.
The behavior is going to depend slightly on which version of NUT you are running.
There's a later commit to specifically ignore calibration-induced "OB LB":
> The only thing I can think of that may explain what happened was
> UPS1 - ONBATT (calibrating)
> UPS2 - ONLINE + LOWBATT (because of a bad battery)
> UPS3 - ONLINE
> it saw the ONBATT for 1 and the LOWBATT from 2 and triggered.
For the state described above, you should have a "power value" of 2 (OB but not LB still contributes 1 to the power value):
* https://github.com/networkupstools/nut/blob/v2.7.4/clients/upsmon.c#L679 (loop over all UPSes, check each independently as to whether they are critical)
What is your MINSUPPLIES in upsmon.conf?
> If that's the case, how do I prevent it from happening again?
I think the key is going to be figuring out the exact state that triggered it. You can increase log levels to see state changes in the drivers. If these are CyberPower UPSes doing OB+LB+CAL, that commit mentioned above is probably the simplest fix.
Another option is to do some sort of "debouncing" with upssched, but that assumes that your batteries will last longer in an actual power failure than the duration of the test. Debouncing is also harder to configure correctly.
In any case, it might be good to use VMs with dummy-ups drivers to test some of these potential solutions.
clepple at gmail
More information about the Nut-upsuser