From: Jose L. M. <jlm...@ca...> - 2009-09-28 18:26:20
|
Hi, Currently I'm testing injecting big results into Nagios via a new program called nrd (Nagios Result Distributor) (I posted a while ago on this list, announcing it as nsca2). Currently I'm getting the results into Nagios fine, but ndo seems to have a bad time with big perfdata... The Nagios screens show all the perfdata correctly, but the results don't appear in the NDO db. I activate debugging in NDO, and never see an INSERT with lots of perfdata. I've tracked down the problem to the following: - the ndo.dat file seems to get the data messed up: - reading through the code, it looks like every entry in the ndo.dat would finish in 999 (NDO_API_ENDDATA) - the perfdata entry 99 (NDO_API_PERFDATA) for "206:" seems to have a mix of data in it (starts like result "213", until you get another NDO_API_PERFDATA section, and at the end of the line you get a 999 (with no "\n" before it). - I attach a test.dat file that is a capture of the ndo.dat file so you can examine it. - I attach the script that is causing this: check_big_perfdata.pl I would expect to see the 500 perfdata entries that the big_perfdata check generates (as the Nagios status screens show them without problems) Looking around in the code, to find a possible cause, I think I found a small bug in io.c, also ndo_unescape_buffer: if (buffer[x+1]=='\t'){ i think should be if (buffer[x+1]=='t'){ but I think this is unrelated to the big perfdata problem. Any thoughs on why NDO is "eating up" the perfdata? Cheers, Jose Luis Martinez jlm...@ca... |