Re: [Nut-upsuser] ONLINE + LOWBATT shutdown

2021-03-08 Thread Charles Lepple via Nut-upsuser
On Mar 8, 2021, at 5:38 PM, Lee Damon via Nut-upsuser 
 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.

v2.7.4: https://github.com/networkupstools/nut/blob/v2.7.4/clients/upsmon.c#L701

There's a later commit to specifically ignore calibration-induced "OB LB":

https://github.com/networkupstools/nut/commit/13b26974b4b22e629ecb13c2ce501aba8fdd6aad

> 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)
* https://networkupstools.org/docs/man/upsmon.html#_power_values

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.

-- 
Charles Lepple
clepple@gmail




___
Nut-upsuser mailing list
Nut-upsuser@alioth-lists.debian.net
https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/nut-upsuser


Re: [Nut-upsuser] ONLINE + LOWBATT shutdown

2021-03-08 Thread Manuel Wolfshant

On 3/8/21 11:56 PM, Lee Damon via Nut-upsuser wrote:

There *may* have been a complicating factor. One of our other UPSs
(there are three in the set) *might* have been onbatt because it was
calibrating at the time. I don't think it was but I can't be sure.

However, that was a different UPS so it *shouldn't* have done anything.


calibrating should not trigger nut



___
Nut-upsuser mailing list
Nut-upsuser@alioth-lists.debian.net
https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/nut-upsuser


Re: [Nut-upsuser] ONLINE + LOWBATT shutdown

2021-03-08 Thread Lee Damon via Nut-upsuser
There *may* have been a complicating factor. One of our other UPSs
(there are three in the set) *might* have been onbatt because it was
calibrating at the time. I don't think it was but I can't be sure.

However, that was a different UPS so it *shouldn't* have done anything.

nomad

On 3/8/21 1:42 PM, Manuel Wolfshant wrote:
> On 3/8/21 11:09 PM, Lee Damon via Nut-upsuser wrote:
>> Over the weekend one of three UPSs in our server room decided one of
>> it's new batteries was bad. I thought maybe the battery wasn't really
>> bad since I'd forgotten to tell the UPS to recalibrate.
> 
>>
>> I tried to get the UPS to recharge so I could get it to recalibrate
>> but at some point it flagged LOWBATT and even though it was on line
>> power NUT decided to shut down the world.
> 
> this should not have happened because it's the standard situation when
> the battery is depleted and recharging
> 
> 
>>
>> Needless to say, this was undesirable.
> 
> right. it should not have happened
> 
> 
>>
>> Is there any configuration change I can make to say "only shut down if
>> the UPS is reporting both ONBATT and LOWBATT"?
> 
> as far as I can tell you have a different issue over there that needs
> investigation. as long as the UPS is on line power ( and the input
> voltage is within limits ),  nut should not trigger a shutdown
> 
> 


___
Nut-upsuser mailing list
Nut-upsuser@alioth-lists.debian.net
https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/nut-upsuser


Re: [Nut-upsuser] ONLINE + LOWBATT shutdown

2021-03-08 Thread Manuel Wolfshant

On 3/8/21 11:09 PM, Lee Damon via Nut-upsuser wrote:
Over the weekend one of three UPSs in our server room decided one of 
it's new batteries was bad. I thought maybe the battery wasn't really 
bad since I'd forgotten to tell the UPS to recalibrate.




I tried to get the UPS to recharge so I could get it to recalibrate 
but at some point it flagged LOWBATT and even though it was on line 
power NUT decided to shut down the world.


this should not have happened because it's the standard situation when 
the battery is depleted and recharging





Needless to say, this was undesirable.


right. it should not have happened




Is there any configuration change I can make to say "only shut down if 
the UPS is reporting both ONBATT and LOWBATT"?


as far as I can tell you have a different issue over there that needs 
investigation. as long as the UPS is on line power ( and the input 
voltage is within limits ),  nut should not trigger a shutdown




___
Nut-upsuser mailing list
Nut-upsuser@alioth-lists.debian.net
https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/nut-upsuser


[Nut-upsuser] ONLINE + LOWBATT shutdown

2021-03-08 Thread Lee Damon via Nut-upsuser
Over the weekend one of three UPSs in our server room decided one of it's
new batteries was bad. I thought maybe the battery wasn't really bad since
I'd forgotten to tell the UPS to recalibrate.

I tried to get the UPS to recharge so I could get it to recalibrate but at
some point it flagged LOWBATT and even though it was on line power NUT
decided to shut down the world.

Needless to say, this was undesirable.

Is there any configuration change I can make to say "only shut down if the
UPS is reporting both ONBATT and LOWBATT"?

thanks,
nomad
___
Nut-upsuser mailing list
Nut-upsuser@alioth-lists.debian.net
https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/nut-upsuser