Have you ever wanted to synchronize email between two machines and been disgusted at the lack of options to truly synchronize all mail? Of course there are ways to do it easily between a PDA and a desktop machine, but between a laptop and a desktop there aren’t many options (let alone good ones). Over the years I have tried a combination of things like IMAP, rsync, commercial apps, etc. and never found anything which wasn’t more trouble than it was worth. Today I had a surprisingly simple idea which so far is working fantastically, so here’s the info so you can do the same.
First step is to configure Thunderbird on both machines to check the same pop account. If you need help with this step, then you probably should stop now. When configuring the pop account, check the box which says “leave mail on server” and then check the box which says “delete mail after ___ days”. Set the number of days to the maximum number of days which either machine could go without checking mail (two days seemed reasonable in my case). All of this should seem pretty unoriginal at this point and might work for some people. The issue I had was how to share my sent email between both machines. Fortunately, I found an option in Firefox which makes all of that easily possible. When viewing the email account settings, you should see an option in the left side which says “Copies & Folders”. There, you will see an option which says “When sending email, automatically BCC these addresses”. Click on that option and type in your email address in the box to BCC to. Now all email you send out will be automatically BCC’d back to yourself without any further work. After doing this, we now need to make sure the incoming BCC’d email gets put into the Sent mail folder. We do this by setting up two new rules, the first rule will move mail sent by the other machine into your sent mail folder on this machine, the other will delete the duplicate email received by the local machine which is already in the sent items folder. You could of course uncheck the option in the account setup which saves a copy automatically in the sent items folder, but I didn’t want to do that because if something failed on the MTA, I would then loose my copy of a sent email (which isn’t acceptable to me). The first rule is setup to match on Return-Path being the return path which matches your email address and the user agent string of the opposite machine. My machines have different User-Agent headers (different OS’s), but if your’s doesn’t then you will need something else unique in the headers between both machines. For the actions, you would want to move the email to the sent items folder, mark it as read, and delete it from the pop server (as the other machine already has it in it’s sent items folder anyway). The second rule will match on the same criteria, only with the user agent of the local machine instead of the other machine. The actions for this rule will simply mark it as read and then delete it (putting it in the trash folder). After setting up the rules on both machines, any email sent by one or the other machine will now show up in the sent items on both. Although nothing in these instructions is revolutionary or ground breaking, it does work very well for keeping mail synchronized between two machines without requiring any additional software. If you have any questions or know of any other methods, please feel free to leave a comment.