Re: [Nagios-devel] Nrpe and reiserfs

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
Guest

Re: [Nagios-devel] Nrpe and reiserfs

Post by Guest »

Gerhard Lausser wrote:
> Hi Ethan,
>
> i stumbled over a bug in reiserfs, when i was desperately trying to find out
> why an include_dir= statement in my nrpe.cfg was ignored.
> In the read_config_dir function you wrote:
>
> #ifdef _DIRENT_HAVE_D_TYPE
> /* only process normal files */
> if(dirfile->d_type!=DT_REG)
> continue;
> #endif
>
> which is completely correct.
> BUT:
> - Linux defines _DIRENT_HAVE_D_TYPE
> - readdir for a reiserfs ALWAYS returns DT_UNKNOWN as d_dtype
> so always the continue statement will be executed and the configfile will be
> ignored.
> I made a patch which uses stat and the S_ISREG and S_ISDIR macros instead of
> d_type, which also should work on systems without _DIRENT_HAVE_D_TYPE.
>
> Greetings from Munich,
> Gerhard

Thanks! This will be included in NRPE 2.5, which I will be releasing
shortly...


Ethan Galstad,
Nagios Developer
---
Email: [email protected]
Website: http://www.nagios.org





This post was automatically imported from historical nagios-devel mailing list archives
Original poster: [email protected]
Locked