Re: [exim] Auto Purge of specific mail

Góra strony
Delete this message
Reply to this message
Autor: Ted Cooper
Data:  
Dla: exim-users
Temat: Re: [exim] Auto Purge of specific mail
cfaust-dougot wrote:
> Folks,
>
> I've got 60+ domains all running under WHM and CPANEL using Exim to handle the mail.
>
> I'm using SA and SpamBox to have all the tagged spam messages get added to a SPAM folder on the server.
>
> My question is, can someone help me or point the way to some help in getting a process in place that can traverse all these domains and delete any mail in the spam directory that is older then 60 days?
>
> TIA!
> -Chris


If you use Maildir format, easy using tools available on the system.

You may blow out the command line length with this depending on how many
domains and users you have - to get around this you might need a
separate program that iterates into each of the directories before
running ...

find /path/to/mailroot/*/*/.SPAM -daystart -mtime +60 -exec rm -R {} \;

(the path changes to . if you use a separate program to get into the
directory first)

If you're using one of the other mail formats, you'll be restricted to
using the mail tools. IMAP/POP connected to thunderbird might be enough,
but you'd have to have it accessing everyones email :P


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