Re: [exim] Slightly OT: autodelete older emails

Page principale
Supprimer ce message
Répondre à ce message
Auteur: Ted Cooper
Date:  
À: exim-user
Sujet: Re: [exim] Slightly OT: autodelete older emails
Yan Seiner wrote:
> I am using exim .forward to put all mailist emails into a single lists
> file. Now I would like to set up that list file as a ringbuffer, so
> that when a new email comes in, an older one drops off. (most maillists
> are archived anyway, so there's no point in keeping old emails).
>
> I can either do this as each mail comes in, or daily in batch, but how
> do I set up a filter to delete older emails? Or should I write a script
> to do this from cron?


I use this for killing old mails in a Maildir format

# kill anything over 14 days old
find /path/to/Maildir/.whatever/cur -type f -mtime +14 -exec rm {} \;

Of course, you're out of luck without Maildir ;) I'm sure there's
scripts or programs out there to trim off spool files.

--
The Exim Manual
http://www.exim.org/docs.html
http://www.exim.org/exim-html-current/doc/html/spec_html/index.html