Marantz, Roy wrote:
> Maildir is such a big win over mbox that I also agree that this is a
> good idea. I'd suggest you worry about the writer and read locking.
> Do something that works on many implementations of file systems (i.e.
> avoid flock). I believe that some similar code uses the file mode or
> name to intricate if it is being written. Of course you then need to
> clean up files that are too old which are left over from crashed
> writers. Roy
>[snip]
I'm not even planning with trying to implement file level locking, as it
looks to be poorly implemented (and inconsistent) across different file
systems. The file naming method is the simplest method - write data to
files named 'dXXXXX' and rename them to 'cXXXXX' when done. Nagios will
only process check results from files named 'cXXXXX' and will happily
deleted other files in the queue directory that are older than a certain
threshold.
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]