Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Click here to return to the 'How to import an .imapmbox into Mail.app' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
How to import an .imapmbox into Mail.app
Authored by: sosventures on Aug 23, '05 09:18:59AM

Not sure why the above didn't work for me (I am using Mail 2.0.3, Tiger 10.4.2).

However, I have an alternate solution that is super easy.

Somehow my .Mac IMAP account got blasted and I lost all my mail in my inbox and on my Inbox on my Apple Mail on my laptop.

Fortunately I had backed up 2 weeks prior, so I just lost 2 weeks of mail activity. Using Backup, I could see all the individual messages under my ~/Library/Mail/Mac-USERNAME/INBOX.imapmbox on my backup disk.

Struggled for hours trying to restore, discovered that mail doesn't want to import imapmbox files, as mentioned above.

But for some reason, with the current version of Mail, all you need to do is copy the imapmbox directory into the ~/Library/Mail/Mailboxes folder. It appears that the only thing you have to do is rename it with a .mbox extension.

That's about it. Quit mail, re-enter. Mail will refresh, your new mailbox will pop up, with ZERO messages. You then need to go to the Apple Mail/Mailbox/Rebuild menu option and a while later all the mail shows up.

This also apparently works on nested mailboxes, although I didn't test it sufficiently to verify. (Rename all the .imapmbox extensions to .mbox extensions... it may be necessary to futz... at first it wouldn't rebuild it for me, then I flattened my nested test by a layer (creating more branches at the /Mailbox level) and it worked.

Fabulous undocumented feature. (Of course, it would be better if you could just import the directory, but you can't).

Obviously, at your own risk. Hope it saves you hundreds of hours of lost work!
Good luck.
Sean

Steps summary:
1. Rename Imap mailbox directory to xyzzy.mbox, replacing all instances of .imapmbox with .mbox (and approving it when it tells you not to)
2. Move it to ~/Library/Mail/Mailboxes/
3. (Quit &) Start Mail
4. Select the xyzzy mail folder from the mailbox selections on the left frame
5. Select "REBUILD" option from the MAILBOX menu


---
Darkness cannot drive out darkness; only light can do that. Hate cannot drive out hate; only love can do that.
Martin Luther King, Jr.



[ Reply to This | # ]
How to import an .imapmbox into Mail.app
Authored by: grommond on Aug 31, '05 02:33:33PM

I seem to have the problem folks are saying isn't solved by this hint. I've got 10.3 IMAP mailbox caches on my local machine that I'd like to bring into 10.4 mail. I tried both of the suggestions above, both yielded zero message folders. Any ideas?



[ Reply to This | # ]
How to import an .imapmbox into Mail.app
Authored by: mcmillen on Sep 13, '05 11:53:47AM

A method that appears to work for backup purposes (ie. if you do it in advance, rather than being caught with only .imapmbox files as the result of an accident) is described at

http://www.macforumz.com/modules.php?name=Forums&file=viewtopic&t=134395&ex=-Subject-trouble-Mail-imapmbox-files-mbox-files-

It boils down to this: when you drag an IMAP mailbox into the "On My Mac" area in the Mail window, it automatically converts it to a local .mbox file, stored in ~/Mail/Mailboxes. (This may cause a lot of network access, as it needs to download all the contents of the IMAP folder to create the local copy. This seems to be happening, for me, even when I've recently synchronized the IMAP account.)

Anyway, once you have those folders created, they can be archived, and read back into Mail later, if you need them as backups. So for active and accessible IMAP accounts, this is an easy fix. For dead accounts, see the other comments, above. And pray.



[ Reply to This | # ]
How to import an .imapmbox into Mail.app
Authored by: deeraeya2 on Aug 03, '09 03:29:00PM

Just wanted to thank you for posting this tip. This had been annoying me for ages, anytime I wanted to archive IMAP mail, Mail.app was re-downloading everything. Since IMAP tends to get random disconnects etc when doing 10000+ emails that sucks, not to mention was very slow.

I can confirm that the re-name to *.mbox, copy and rebuild method in the parent works on Mail 3.6 in 10.5.7

Hazzah!



[ Reply to This | # ]