Re: [exim-dev] Feature Request: Advanced Logging

Page principale
Supprimer ce message
Répondre à ce message
Auteur: Phil Pennock
Date:  
À: Florian Lagg
CC: exim-dev
Sujet: Re: [exim-dev] Feature Request: Advanced Logging
On 2008-09-17 at 17:55 +0200, Florian Lagg wrote:
> PROBLEM:
> I have to implement some kind of logging to fulfil the law about data
> retention beginning on 01.01.2009. I could code a solution which pharses the
> mainlog using regexp. This has some disadvantages:
> - Problems with log rotating


Embed the date in Exim's logfile names and do the compression yourself,
on suitably old files.

log_file_path = /var/log/exim/%slog-%D

There's something in the src/EDITME (aka Local/Makefile) file about
this.

> - the regexp must be tested very well to log any mail incoming/outgoing - no
> matter how the log line looks like. but it should not log other lines to
> save disk space. That will be hard.


Not that hard, since Exim clearly defines, in the documentation, what
the log lines look like and which options affect them.

exigrep is a utility bundled with Exim which shows some of what can be
done.

> Is someone interested in implementing it? I cannot code it because I do not
> have the time to start digging in the exim code.
> But I CAN help with testing and documentation.


Someone else might be interested; myself, I'd be more inclined, if doing
this, to ask for a precise specification of exactly what data is to be
retained and then provide a exilogcompact script with Exim as a
demonstration of parsing the logfiles and producing something more
condensed. And modify exicyclog to optionally (depending upon
Local/Makefile) call that script to generate the longer-term retention
logfile before compressing away the one it's looking at now.

Given a specification to work to, I might be willing to write/modify the
script(s) to handle this.

-Phil