NRPE and include_dir

Mike Chesnut mikec at aggregateknowledge.com
Tue Mar 15 03:00:19 CET 2011


Apologies if this list isn't appropriate for this question, but I 
thought I'd try here first.

We're trying to use the include_dir directive in NRPE with an 
/etc/nagios/nrpe.d/ directory.  My assumption was that files in this 
directory would be loaded in alphanumeric order, but it seems to only 
load in alphabetical order, ignoring numerals.

For instance, if I have these files:
/etc/nagios/nrpe.d/000-fileone.cfg
/etc/nagios/nrpe.d/100-filetwo.cfg

and they both define the same command, I would expect the one in 
100-filetwo.cfg to take precedence, as it should be loaded second. 
However, this is not the case.  (I've verified the order they are loaded 
with debug=1).

If I have these files, though:
/etc/nagios/nrpe.d/aaa-fileone.cfg
/etc/nagios/nrpe.d/bbb-filetwo.cfg

then things work in the order I expect (checks defined in 
bbb-filetwo.cfg will override checks defined in aaa-fileone.cfg).

I'm using NRPE 2.5.2, which I realize is slightly old (2.12 seems to be 
the most recent version).  I can't find a bug report for this issue, 
though, so I'm not sure if it's been recognized as such, nor if it's 
been corrected in newer versions.  In fact, I see no documentation 
anywhere that specifies the order in which files will be loaded from 
within a directory that's been included with include_dir.

Has anybody seen this behavior?  Am I correct in believing it to be a bug?

Thanks,
Mike

------------------------------------------------------------------------------
Colocation vs. Managed Hosting
A question and answer guide to determining the best fit
for your organization - today and in the future.
http://p.sf.net/sfu/internap-sfd2d
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null





More information about the Users mailing list