Matt Kinni
2022-Dec-19 12:39 UTC
[Nut-upsuser] APC ups reports "OL DISCHRG" as its normal status, even when plugged into mains
Hello nut users! I have an APC Back-UPS BGM1500 connected via a serial->usb cable, using the usbhid-ups driver. Everything appears to work and automated shutdowns occur as expected in response to the lowbatt signal, but nut-driver is spamming the logs with this error message on every poll interval:> 0.430476 [D1] Quick update... > 0.430484 ups_status_set: seems that UPS [GamingUPS] is in OL+DISCHRG state now. Is it calibrating or do you perhaps want to set 'onlinedischarge' option? Some UPS models (e.g. CyberPower UT series) emit OL+DISCHRG when offline. > 1.866888 sock_connect: enabling asynchronous mode (auto) > 2.262626 [D1] upsdrv_updateinfo... > 2.270082 [D1] Got 1 HID objects... > 2.270092 [D1] Quick update... > 2.284067 ups_status_set: seems that UPS [GamingUPS] is in OL+DISCHRG state now. Is it calibrating or do you perhaps want to set 'onlinedischarge' option? Some UPS models (e.g. CyberPower UT series) emit OL+DISCHRG when offline. > 4.264627 [D1] upsdrv_updateinfo... > 4.334114 [D1] Got 9 HID objects... > 4.334131 [D1] Quick update... > 4.345097 ups_status_set: seems that UPS [GamingUPS] is in OL+DISCHRG state now. Is it calibrating or do you perhaps want to set 'onlinedischarge' option? Some UPS models (e.g. CyberPower UT series) emit OL+DISCHRG when offline. > 6.266562 [D1] upsdrv_updateinfo... > 6.270145 [D1] Got 1 HID objects... > 6.270162 [D1] Quick update... > 6.284123 ups_status_set: seems that UPS [GamingUPS] is in OL+DISCHRG state now. Is it calibrating or do you perhaps want to set 'onlinedischarge' option? Some UPS models (e.g. CyberPower UT series) emit OL+DISCHRG when offline."DISCHRG" is always present on the status line regardless of whether the ups is actually connected to the wall or not, so this appears to be its "normal" state and can't be taken at face value. Is there any way I can get the usb driver to stop complaining about this? Unfortunately I don't think setting 'onlinedischarge' in ups.conf would produce the desired effect, but I'd like to stop the log spam. Thanks
Greg Troxel
2022-Dec-19 13:18 UTC
[Nut-upsuser] APC ups reports "OL DISCHRG" as its normal status, even when plugged into mains
>> 0.430484 ups_status_set: seems that UPS [GamingUPS] is in OL+DISCHRG >> state now. Is it calibrating or do you perhaps want to set >> 'onlinedischarge' option? Some UPS models (e.g. CyberPower UT >> series) emit OL+DISCHRG when offline.I think the first questions are: what is the UPS actually doing? what do other programs, especially from the manufacturer, say? and then perhaps there is need to have a quirk table in the code to be able to express things like For APC BGM1500, if it says OL+DISCHRG, rewrite that to OL, because it's confused. so that then the later logic will be ok with it. Presumably you are watching battery voltage and it's 26ish, assuming 2 12V in series, or similar, so not actually discharging. True? What is the status when the power fails? You said it included DISCHRG, but anything else? Did you trace/debug-log the code that led to OL+DISCHRG? What bits is the UPS really sending? Is this is a UPS bug or a nut bug, or the UPS has an odd spec or ? More questions than answers, but hope it helps -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 194 bytes Desc: not available URL: <http://alioth-lists.debian.net/pipermail/nut-upsuser/attachments/20221219/6365189c/attachment.sig>