Xymon Mailing List Archive search

Config report(critical) not working with critical systems (nkview.cfg), but NK tags

list Buchan Milne
Wed, 6 Feb 2008 11:17:48 +0200
Message-Id: <user-743c2433ac0d@xymon.invalid>

On Tuesday 05 February 2008 18:25:56 Buchan Milne wrote:
I am moving to the Critical Systems view, however, to ensure that all the
critical systems are in fact on the Critical Systems view, I was hoping to
use the Config report (critical), and refer teams to the reports for their
pages/servers. However, I always get empty reports, while the normal Config
report has the correct values (from nkview.cfg) in the NK column for the
correct host/test.

The source code for hobbit-confreport.c shows that it filters based on the
NK tag from bb-hosts when run with the --critical option.

This is quite a big issue, I can't give everyone edit access, and there's
no other really feasible way to audit this at present.

OK, it looks like there's something wrong here:

if (!nkalerts || (strcmp(nkval(hname, tname, nkalerts), "No") == 0)) wanted
= 0;

This change (beware line breaks) seems to do what I need (at least on the
dev system I tested on):
[...]
However, a host with NK tags in bb-hosts now appears in the report, with NK
columns displaying "No". I can live with this though ...
The attached patch seems to be a better (and easier to read) fix.

Regards,
Buchan
Attachments (1)