On Thu, 4 Jan 2001, Paul Makepeace wrote:
> At least with Debian the log rotation duties are handed over to savelog
> who's invoked in a /etc/cron.daily/exim script. This is quite a traditional
> unix-y way of doing things. The problem since these parameters are
> hard-coded into the script comes if the default number of files to keep
> changes or it's only desire to rotate weekly or whatever. When the package
> is upgraded these script hacks are typically lost, and worse often silently.
>
> I realize this is arguably an issue with packaging in general and not exim
> itself
I would argue that.
> Here are some suggestions:
>
> a) make the daemon rotate the logs using internal code, obviously configured
> in exim.conf.
> b) put the name of the rotation program in exim.conf with config parameters
> (e.g. a command line and when to run it)
> c) simply have the configuration valid in exim.conf that exim ignores and
> some external program parses.
I would oppose a and b, and most of c. But c would be okay if if the
external program read things that are otherwise seen as COMMENTS exim's
configure file.
> Given that there is already log directives in exim.conf I don't think any of
> the above are that radical.
Building a log rotater into the exim binary is radical.
> *Especially* since there are already log directives we already have
> some unfortunate coupling between savelog invocations and exim's log
> filename format (e.g. changing mainlog to main.log breaks the
> rotating).
Are you aware of the -P option to exim. You can extract particular
configure file parameters by querying exim itself.
Also are you aware of the log rotation script that comes with exim? You
may wish to have your cron job call that.
(Although at home I am using Redhat's logrotate facility because I can
tune it to rotate only when files reach a certain size).
> The real aim is to have exim and the log rotation able to discover these
> parameters from a configuration file.
Look at the exicyclog script.
Cheers,
-j
--
Jeffrey Goldberg
I have recently moved, see
http://www.goldmark.org/jeff/contact.html
Relativism is the triumph of authority over truth, convention over justice