Date: Tue, 12 May 2009 15:29:36 -0700 From: Tim Kientzle <kientzle@freebsd.org> To: Garance A Drosehn <gad@freebsd.org> Cc: freebsd-current@freebsd.org, Dmitry Morozovsky <marck@rinet.ru> Subject: Re: newsyslog(8) patch for both size and time checks Message-ID: <4A09F850.2080208@freebsd.org> In-Reply-To: <p06240800c62f5d4bab62@[128.113.24.47]> References: <alpine.BSF.2.00.0905121354450.1756@woozle.rinet.ru> <p06240800c62f5d4bab62@[128.113.24.47]>
next in thread | previous in thread | raw e-mail | index | archive | help
Garance A Drosehn wrote: > At 1:59 PM +0400 5/12/09, Dmitry Morozovsky wrote: >> >> for now, if log is configured to be rotated in time manner, its size >> is not checked ... >> >> The following simple patch should fix the problem. Any objection to >> commit this? > > It would fix your problem, but it changes the behavior as is explicitly > documented in 'man newsyslog.conf' . There is a paragraph in the man > page which makes it clear that if both fields are specified, then the > log file will only be rotated if both conditions are true. I've never liked that paragraph and find the documented behavior is much less useful than the proposed behavior. With the documented behavior, the effect is "rotate at this size, but no more often than XXX time interval", which serves to limit the number of log files created, but not the total size. In practice, /var/log total size is almost always the critical resource. If compatibility is essential, perhaps we could add a new flag to control this behavior. (I would argue for changing the default and providing a flag to obtain the old behavior.) Tim
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4A09F850.2080208>