On Dec 4, 2013, at 3:52 PM, Kris Jordan wrote:> Roger Price wrote, On 12/4/2013 12:35 PM: >> I would like nut to become more loquacious, and to log a much more complete report of its activity. At present nut reports that its components have started operation but does not automatically log their activity when UPS's switch between OB and OL. I believe that this under-reporting of important facts is too minimalist - it would be better for system administrators and for the nut support team if a much more complete report were available of all OB/OL activity by each component. > > I've noticed that NUT doesn't notice short power outages or glitches like previous setups (APC Smart-UPS+Apcupsd) I've had. I do miss that. I thought NUT supported UPS notifications/interrupts so that it can know of power events that happen in-between the regular poll interval. But I don't how much the lack of reporting is due to NUT or the Eaton UPS's I am using now.The default setting in upsmon.conf for ONLINE/ONBATT is SYSLOG+WALL. If those events aren't being logged, we would need to trace further upstream and see if the driver is generating the events. Kris: I don't know the various debug levels off the top of my head, but if you want to manually start the driver with a few -D flags and log the resulting output, we can see whether or not your UPS is sending the notifications the way that the driver is expecting them. -- Charles Lepple clepple at gmail
Charles Lepple wrote, On 12/4/2013 4:11 PM:> On Dec 4, 2013, at 3:52 PM, Kris Jordan wrote: > >> Roger Price wrote, On 12/4/2013 12:35 PM: >>> I would like nut to become more loquacious, and to log a much more complete report of its activity. At present nut reports that its components have started operation but does not automatically log their activity when UPS's switch between OB and OL. I believe that this under-reporting of important facts is too minimalist - it would be better for system administrators and for the nut support team if a much more complete report were available of all OB/OL activity by each component. >> I've noticed that NUT doesn't notice short power outages or glitches like previous setups (APC Smart-UPS+Apcupsd) I've had. I do miss that. I thought NUT supported UPS notifications/interrupts so that it can know of power events that happen in-between the regular poll interval. But I don't how much the lack of reporting is due to NUT or the Eaton UPS's I am using now. > > The default setting in upsmon.conf for ONLINE/ONBATT is SYSLOG+WALL. > > If those events aren't being logged, we would need to trace further upstream and see if the driver is generating the events. > > Kris: I don't know the various debug levels off the top of my head, but if you want to manually start the driver with a few -D flags and log the resulting output, we can see whether or not your UPS is sending the notifications the way that the driver is expecting them.Since August, Apcupsd+SU700NET has logged 20 "Power failures". These were all what I would call glitches. Actual power failures here are rare. During the same period, NUT 2.6.5+Eaton 5PX has logged nothing. It's on the same circuit as the SU700NET. The 5PX is plugged into a cut-off switch so I can easily test it, so I know upsmon's logging is working, if I give it a few seconds to notice. I can flip the switch fast and the UPS responds (beeps, relays clicking), but nothing from upsmon. I've been meaning to do the full debugging bit, including the SU700NET+NUT to see if it behaves differently. I'll upgrade NUT and get that testing done. Thanks
Charles Lepple wrote, On 12/4/2013 4:11 PM:> On Dec 4, 2013, at 3:52 PM, Kris Jordan wrote: > >> Roger Price wrote, On 12/4/2013 12:35 PM: >>> I would like nut to become more loquacious, and to log a much more complete report of its activity. At present nut reports that its components have started operation but does not automatically log their activity when UPS's switch between OB and OL. I believe that this under-reporting of important facts is too minimalist - it would be better for system administrators and for the nut support team if a much more complete report were available of all OB/OL activity by each component. >> I've noticed that NUT doesn't notice short power outages or glitches like previous setups (APC Smart-UPS+Apcupsd) I've had. I do miss that. I thought NUT supported UPS notifications/interrupts so that it can know of power events that happen in-between the regular poll interval. But I don't how much the lack of reporting is due to NUT or the Eaton UPS's I am using now. > > The default setting in upsmon.conf for ONLINE/ONBATT is SYSLOG+WALL. > > If those events aren't being logged, we would need to trace further upstream and see if the driver is generating the events. > > Kris: I don't know the various debug levels off the top of my head, but if you want to manually start the driver with a few -D flags and log the resulting output, we can see whether or not your UPS is sending the notifications the way that the driver is expecting them.apcsmart quick power cuts @ 20 & 30 usbhid-ups @ 30 & 40 The APC unit logs alert_handler: OB. usbhid-ups isn't so obvious, so I'm not sure. At least the apcsmart driver is reacting immediately, but upsmon reports nothing unless I cut power long enough. upsmond has noticed quick power cut, but I think that's because It happened at the same time as the normal check interval. I'm using defaults here, as far as poll intervals. Maybe upsd is getting the message, does it push upsmon? I thought to try upsd at full debugging to see if it says anything, but it appears that nothing special is shown for UPS/driver events. 2.7.1 is working fine so far. Thanks for changing the USB timeout. -------------- next part -------------- A non-text attachment was scrubbed... Name: UPS interrupt test.7z Type: application/octet-stream Size: 39970 bytes Desc: not available URL: <http://lists.alioth.debian.org/pipermail/nut-upsuser/attachments/20131206/e3ce2380/attachment-0001.obj>
Charles Lepple
2013-Dec-07 19:43 UTC
[Nut-upsuser] Plea for a more loquacious nut [short power events]
On Dec 7, 2013, at 12:06 AM, Kris Jordan wrote:> apcsmart quick power cuts @ 20 & 30 > usbhid-ups @ 30 & 40 > > The APC unit logs alert_handler: OB. usbhid-ups isn't so obvious, so I'm not sure.$ grep send_to_all usbhid-ups.log|grep ups.status 10.538414 send_to_all: SETINFO ups.status "OL CHRG" 30.912005 send_to_all: SETINFO ups.status "OB DISCHRG" 32.585047 send_to_all: SETINFO ups.status "OL CHRG" 40.667472 send_to_all: SETINFO ups.status "OB DISCHRG" 43.223281 send_to_all: SETINFO ups.status "OL CHRG"> At least the apcsmart driver is reacting immediately, but upsmon reports nothing unless I cut power long enough. upsmond has noticed quick power cut, but I think that's because It happened at the same time as the normal check interval. I'm using defaults here, as far as poll intervals. > > Maybe upsd is getting the message, does it push upsmon?Good point. It's polling, at a default interval of 5 seconds: https://github.com/networkupstools/nut/blob/v2.7.1/clients/upsmon.c#L2010 Adding something like the IMAP IDLE command to the NUT protocol should enable pushing messages, but would require the client polling loops to be reworked. In the short term, decreasing the upsmon.conf POLLFREQ and POLLFREQALERT settings should catch the shorter events.> I thought to try upsd at full debugging to see if it says anything, but it appears that nothing special is shown for UPS/driver events.I added the upsd case to https://github.com/networkupstools/nut/issues/79 -- Charles Lepple clepple at gmail