Does anyone know of a script which can be run via cron to delete mail over X days old? Client forwarding mail to read elsewehere. Keeps a backup copy on server to access via webmail. Does not POP from our server, only uses webmail occasionally. Wishes to have mail over 30 days old deleted automatically.
One idea I am going to play with is symlinking the webmail Saved and Trash folders. Set webmail to move old messages to 'Saved' at logout. Set the trash to delete messages over 30 days old. But this will only work if the customer logs in regularly, correct? Is the trash only emptied when the client uses webmail the same as the filtering?
Do you know of a preexisting script than can do this?
How can we delete mail after X days?
Moderators: BBear, theunknownhost, flaguy
- Arf
- Official Test Penquin
- Posts: 9103
- Joined: Tue Apr 09, 2002 12:00 am
- Location: IDAHO, USA
- Contact:
Re: How can we delete mail after X days?
Sapphyre wrote:Set the trash to delete messages over 30 days old. But this will only work if the customer logs in regularly, correct? Is the trash only emptied when the client uses webmail the same as the filtering?
Do you know of a preexisting script than can do this?
I believe so, yes yes and no to these questions. I don't think there's a script that will do this on webmail files. Email Plumber does this on a regular email box file.
Can email plumber do this via cron for one account only?
I did find 'archivemail'
http://archivemail.sourceforge.net/
...but it's not compatible
Oh, but we'll have a go with this one ... stay tuned:
http://adc-archmbox.sourceforge.net/
I did find 'archivemail'
http://archivemail.sourceforge.net/
...but it's not compatible
Oh, but we'll have a go with this one ... stay tuned:
http://adc-archmbox.sourceforge.net/
We actually set a cron to delete ONE email account mail file every night at midnight. Using the CP cron manager like this:
cd /home/USER/DOMAIN-mail/; rm info -f
Where as the email account "info" was being deleted nightly. Been working well. Do it because Blackberry's and Treo phones dont like to remove mail from the server. Hope this helps!
cd /home/USER/DOMAIN-mail/; rm info -f
Where as the email account "info" was being deleted nightly. Been working well. Do it because Blackberry's and Treo phones dont like to remove mail from the server. Hope this helps!
Who is online
Users browsing this forum: No registered users and 1 guest