[syslog-ng] logline corruption
erik.williamson at gmail.com
Tue Dec 6 19:30:52 CET 2005
Beautiful - thanks to both of you for getting back to me! Now to
re-architect it all...
On 12/6/05, Valdis.Kletnieks at vt.edu <Valdis.Kletnieks at vt.edu> wrote:
> On Mon, 05 Dec 2005 15:07:56 EST, Erik Williamson said:
> > being written to a local disk. There are many destination files on
> > the server, but it is possible that more than one logging server may
> > be attempting to write to the same destination file at the same time.
> More than one process writing to a file without benefit of locking is
> looking for exactly the sort of corruption you're seeing (although for
> local files, opening with O_APPEND may help, but not for NFS - the
> Linux 'man 2 open' manpage says:
> The file is opened in append mode. Before each write(), the file
> offset is positioned at the end of the file, as if with lseek().
> O_APPEND may lead to corrupted files on NFS file systems if more
> than one process appends data to a file at once. This is
> because NFS does not support appending to a file, so the client
> kernel has to simulate it, which can't be done without a race
> syslog-ng maillist - syslog-ng at lists.balabit.hu
> Frequently asked questions at http://www.campin.net/syslog-ng/faq.html
More information about the syslog-ng