Re: [Nagios-devel] Nagios ignores broken file descriptor?

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] Nagios ignores broken file descriptor?

Post by Guest »

Steven D. Morrey wrote:
> Here is an strace on the same box from just a few minutes ago.
> As you can see whats happening is Nagios does not appear to be catching
> the error about trying to write to a read only file system.
>
> nanosleep({1, 0},{1, 0}) = 0
> kill(-7799, SIGKILL) = -1 ESRCH (No such process)
> gettimeofday({1227029613, 509530}, NULL) = 0
> close(10) = 0
> open("/usr/local/nagios/var/nagios.log", O_RDWR|O_APPEND|O_CREAT, 0666)
> = -1 EROFS (Read-only file system)

Actually, it does catch it (which is why it doesn't try to write to it),
but since it's the logging API, there's not much Nagios can do about it
except crashing out. Given Nagios' role in the network, it's considered
better to keep running with logging disabled than to silently die without
leaving a core-dump or some other entry-point for debugging.

In other words, this is unfortunate, but by design. If you have a solution,
I'm all ears.

--
Andreas Ericsson [email protected]
OP5 AB www.op5.se
Tel: +46 8-230225 Fax: +46 8-230231





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