On Tue, 30 April 2013 16:53:54 -0400, Jörn Engel wrote:
> On Tue, 30 April 2013 22:55:38 +0100, Paul Martin wrote:
> 
> > The alternative (and ultimately safest against log file data loss) is
> > to delete the status file completely if it fails writing, and hence
> > reset all the rotation intervals to their default.  Unorthodox, yes,
> > confusing, yes, but absolutely the least likely to cause data loss
> > (except perhaps from allowing /var/log to run out of space too, which,
> > if /var/lib and /var/log are on the same filesystem, has already
> > happened).
> 
> Seems good to me.  Move the status file, rotate, write new status
> file, rename.  If anything goes wrong in the middle, say a system
> reboot, we at least don't destroy data.

And while working on a fix I noticed that svn commit 254 introduced
the data-eating behaviour.

In case of logrotate exiting before rewriting the state file there is
also a data loss scenario, but the one I happened to hit was
impossible before 254.

Jörn

--
Courage is not the absence of fear, but rather the judgement that
something else is more important than fear.
-- Ambrose Redmoon


-- 
To UNSUBSCRIBE, email to debian-bugs-rc-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org

Reply via email to