User Tools

Site Tools


software:dailydata:archiveimap

This is an old revision of the document!


archiveIMAP

We run a small mail server for some of our clients, some of whom retain massive amounts of e-mail. A few never sort anything, but leave it all in the Inbox, which can cause programs like Outlook to become unstable. Additionally, having a lot of mail in one folder can put a strain on the servers as users move around their various folders. Other clients use mail servers which limit the total size of an individual mail account.

Many programs allow auto-archiving of older mail. However, in the case of Outlook, this mail is stored in a local message store (.pst file), and while Thunderbird will move the mail around on the server, it is still creating a huge message store which can negatively impact resources on both the client machine and the mail server.

The main solution we have found is to separate mail into an active account and an archive account. We create a separate mail account strictly for archival purposes, and keep the active account as small as possible for rapid response to the client and fewer resources used on both client and server. The archive account is used for permanent storage of old mail, and can be on older, slower hardware, and not automatically synchronized to the client's computer. archiveIMAP is a perl script which facilitates this.

Client Perspective

After your server administrator has set up archiveIMAP, you can tell her/him the following information:

  • Maximum age to keep active email
  • Specific folders to not archive
  • Whether to delete mail from the active account which has been archived (pretty useless not to)
  • Whether to delete folders which no longer contain e-mail
    • If you do this, you can specify that certain folders will never be deleted
  • How to store mail in the archive account
    • Original path - mail will be stored in the original folder on the archive account, so if it came out of Inbox/Clients/acme, it will be placed in Inbox/Clients/acme in the archive account
    • Year - Mail will be stored in a folder for the year in which it was sent or received. In this case, if a message was sent in 2014, it will be stored in a folder named 2014 in the archive account
    • Month - Mail will be stored in a folder for the month (two digit month number) in which it was sent or received. So, a message sent in January of 2013 will be stored in the folder 01 on the archive server.
    • Any specific folder name - You can specify a folder name, like Archive, or Inbox where all mail should be stored.
    • Any Combination of the above - You can specify one or more of the above, and your systems administrator will be able to archive your mail as you see fit. For example, if you are very organized and have all of your mail sorted, you could tell the sysadmin to store them as the original path, then a year and month. Thus, a message in your Inbox/Clients/acme which was received in March of 2014 could end up in Inbox/Clients/acme/2014/03
software/dailydata/archiveimap.1568704641.txt.gz · Last modified: 2019/09/17 02:17 by rodolico