[syslog-ng]Re: Logrotate "remove_if_older" documentation
klaas.vangend@philips.com
klaas.vangend@philips.com
Wed, 13 Feb 2002 09:07:12 +0100
> I read something about a "remove_if_older" Config variable in Baszis 1.5.14
> announce, but couldn't find any documentation for it. In which context do i
> have to use this function (destination i guess..) and which options does it
> accept/need?
> Is there also a function which compresses the "rotated-away" logfiles, or
> do i have to use the "find -mtime" hack?
I added documentation in the patch I sent.
Yes, remove_if_older requires one parameters, stating the number of seconds (it was days in my patch,
but Balazs changed that to seconds to match all other syslog-ng parameters).
If the file where the log line is to be written to is older than the number of seconds
specified, the file will be removed prior to writing the log to file. Thus it is a parameter of the file() destination.
I originally though about implementing some other features, like the ones you described, but because
our product (which uses syslog-ng as logger) doesn't need those features, my boss didn't allow me to
work on those. It shouldn't be too complex to add, by the way.
You can take my patch as a basis for knowing where to change the source code.
Groetjes,
Klaas van Gend