[Nagiosplug-devel] Patch for check_ups

Ton Voon ton.voon at altinity.com
Tue Nov 20 13:19:36 CET 2007


Hi Olivier,

On 20 Nov 2007, at 06:49, Olivier 'Babar' Raginel wrote:

> As I was tired of getting 5 security error log lines at each nagios
> invocation (upsd[1138]: Host 127.0.0.1 disconnected (read failure)), I
> patched the check_ups.c to do a clean LOGOUT.
>
> A better way would be to check all variables at once, and then close  
> the
> connection. I'll probably code that when I'll have more time.
> Patch is pretty quick and dirty, as it had been ages since I did C,  
> but
> it works fine. Basically, idea is to add a "LOGOUT\n" after a GET VAR,
> so it disconnects properly, and remove the "OK Goodbye\n" from the
> returned output.
>
> I've tested it on my local MGE UPS, and it works fine.

Thanks for the patch. Is there a UPS that we can test this against? Or  
is some dummy UPS server code that we could run tests against?  
Alternatively, could you provide a server for tinderbox (http://tinderbox.altinity.org 
) so we can continually test this plugin?

As I don't have any UPS to run against, I'd like something to validate  
that the patch is okay and that the plugin still works on an ongoing  
basis.

Ton





More information about the Devel mailing list