Merging mailboxes across different OS X boxes?
November 1, 2005 4:43 AM   Subscribe

Merging mailboxes maintained with the Mail app under OS X?

I use the OS X Mail app to send & receive email on five different accounts.

I had an accident and my 15" 1.25Ghz PowerBook got trashed. The case was bent sharply and although the machine ran just fine it would not sleep. The PowerBook and I visited the Genius Bar at the Apple Store on Regent Street where it was repaired in about two weeks.

But I need a machine so before I sent the 15" off I purchased a sweet 12" 1.5Ghz PowerBook, and used Apples Migration Assistant to "clone" the original machine onto the new one. I figured the 12" would visit Mr eBay once the 15" was home.

So two weeks later I got the 15" back, but one thing led to another and although I've tried to be disciplined some six weeks later the mail spools on the two machines are inconsistent. In terms of receiving, the 15" does have the canonical inbox across all the accounts, but both machines have slightly different outboxes (i.e., I've sent from both computers). These tied to POP3 mailboxes on the various servers.

What options do I have to merge the mailboxes across the two computers? I'd hate to have to do this manually as I'm sure I'd miss something. And the 12"? Yeh I know, I'm a loser - I'm keeping both.
posted by Mutant to Computers & Internet (6 answers total)
I forget: Does Mail use mbox format? I don't think so, but with procmail and formail, it's pretty easy to do so.

Hmm. Mail seems to have a sync feature, working with iSync. You'd need a .Mac account, but otherwise, you'd just sync each notebook -- first the 15", then the 12" (which would make the 12" current with the 15") then the 15" again (which would make it current with the 12)
posted by eriko at 5:26 AM on November 1, 2005

In terms of an ongoing solution, just set it so that mail isn't deleted from your POP3 account for a month (or whatever), and then the mail should be updated on both machines. If you're losing a machine for a couple of weeks, no matter, it'll all turn up on the other machine's return. This doesn't solve your already-occurred problem, however.
posted by wackybrit at 6:16 AM on November 1, 2005

I don't know if POP3 issues are similar to IMAP issues, but I was having difficulty synching my Sent and Trash folders with my IMAP accounts using until I came across this article on how to manually set which folders should be synched.
posted by Robot Johnny at 6:33 AM on November 1, 2005 on 10.4 no longer uses mbox files. There is a small app that can convert the maildirs that it uses now (each message broken into a single file with an index) into mboxes but that might not be useful. I quit using when mboxes went away. I demand a certain amount of portability on principle and the Tiger format doesn't allow this. For the record, I'm using Thunderbird now and it moves painlessly between machines and platforms but doesn't sync automatically.

To resolve this problem and stay with, I'd strongly recommend using IMAP on the server side. .Mac may offer similar functionality, but IMAP can for sure solve things since the mail archive stays on the server.
posted by shagoth at 7:05 AM on November 1, 2005

If is using maildirs, all you have to do is copy one machine's maildir into another. Files that have the exact same name will be overwritten, but that's ok, since they're the same on both machines anyway. Files that are new will just magically show up in the directory.

Maildirs are cool like that.

Warning: I'm just talking about the Unix maildir format. I do NOT know that does it that way. I strongly suggest making backups of both mail stores before fooling around with them. But if it is indeed maildirs, it's dirt-simple.
posted by Malor at 7:45 AM on November 1, 2005

Let me rephrase that, just in case it didn't register.

Maildirs are organized as a bunch of separate files in a directory. Each mail is one file. When new mail comes in, it's given a very long, semi-random and unique filename, so it won't erase anything that's there already.

So you have two directories, each of which has some unique messages that are not in the other. All you have to do is copy the files from one directory into another. If you're copying A to B:

1. New files from A will be added;
2. Files that are the same on both will be overwritten, but they're the same anyway, so who cares;
3. Files that were only on B will be untouched.
4. Result is all files from A+B.

For a true sync, you'd then copy back to A as well.
posted by Malor at 5:51 AM on November 2, 2005

« Older Germanyfilter   |   Can dog food make a dog sick? Newer »
This thread is closed to new comments.