Re: [Exim] Log Rotation

Etusivu
Poista viesti
Vastaa
Lähettäjä: John W Baxter
Päiväys:  
Vastaanottaja: KP^2 - NOC, Exim List
Aihe: Re: [Exim] Log Rotation
At 13:10 -0500 8/31/01, KP^2 - NOC wrote:
>I guess my first question would be, do I need to rotate mainlog, paniclog,
>and rejectlog?
>
>And if so, I would really like to use newsyslog (this is on a FreeBSD 4.4
>system), which I tried but encountered a problem. When newsyslog creates
>the new log file, it is owned by root. If any of you have a work around in
>place for this, I would love to hear it!! So, for now I just disabled
>newsyslog (at least where the exim logs are concerned), and chown'd the log
>files so the exim user was the owner. Here are my newsyslog conf lines for
>exim:
>
>/var/log/exim/mainlog                   644  7     *    @T00  Z
>/var/log/exim/paniclog                  644  7     *    @T00  Z
>/var/log/exim/rejectlog                 644  7     *    @T00  Z


We use the exicyclog which comes with Exim (more accurately, is built with
Exim).
Actually, we use a hacked form of that which rotates two more logs we create.

There is a longer "lag" than you may be used to in having the rotation
"take" once the file manipulations are done...although the Saturday morning
overlap was only 26 seconds or so here...here's the boundary between files
(head exim_mainlog; tail exim_mainlog.01):

2001-09-01 03:23:05 15d7va-0007DP-00 Completed
2001-09-01 03:22:31 15d7v3-0007Co-00 => blah blah

So if you use a rotate thing which immediately compresses the old file,
you'll have problems. And it's not easy to know how long to wait (although
exicyclog's 24 hours is sufficient ;-)).

If you have to rotate paniclog, you've got problems. paniclog should
always be empty...if something does show up there that we need to study, we
copy it out and empty paniclog again.

--John

-- 
John Baxter   jwblist@???      Port Ludlow, WA, USA