Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Email rotation

Status
Not open for further replies.

axman505

Technical User
Joined
Jun 20, 2001
Messages
489
Location
US
Hello,

Is there any way to use procmail or something else to easily delete messages out of an imap folder once they are over a month old?

I have an email account setup just for mailing lists, and after x number a days, it would be nice to have an automated way to remove the message so the account doesnt grow to overtake the server:)

Any suggestions?

Thanks
 
You could put on crontab :
15 1 * * 1 find <pathname> -mtime +30 | xargs rm -f

The files older than 30 days could be deleted.
Good Luck...:)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top