[Apcupsd-users] Communications with UPS ups0 restored messages
Brought to you by:
adk0212
|
From: Shawn H. <ap...@el...> - 2022-11-16 15:15:15
|
I see a number of "Communications with UPS ups0 restored" messages from apcupsd. But almost never see the "lost" message unless communication really is lost, which happens when I unplug the USB cable. Some time ago, I looked into the code, and discovered this was because it takes steps to not send the "lost" message unless it really is lost. But it doesn't apply any similar check for the "restored" message. I tried to modify the code so that it will only send the "restored" message in cases where a "lost" message had been sent previously, but none of my attempts to do that actually worked. So I have a feature/change request: Only send "communication restored" when a "communication lost" message has been sent. Logging both events even when it is determined they are not real is fine, as long as no email is sent and syslog doesn't send a console message. Thanks, Shawn |