#700 new

Gmail to Runbox transition problems with MailMate

Reported by Meindert | April 5th, 2014 @ 03:48 AM

In pursuing my goal of going Google-free I am now testing Runbox as an alternative to Gmail. I've opened a trial account at Runbox and moved one e-mail address there. I own the domain, and I changed the DNS records to point the MX record at Runbox, and it's propagated, and I'm able to download mail from Runbox (one odd thing: you have to swap % for @ in your e-mail address to use it as your login name).

The problem I've now run into is the [Gmail]/Archive mailbox. In following the MailMate instructions, I deleted all other labels, created this label on Gmail, and labeled all mail with it. Runbox seems to have tried to import the contents of this "mailbox," but they seem not to like the character "/" anymore than the character "@": they changed the name of the mailbox to [Gmail].Archive.

I get this error from MailMate:

IMAP problem for "mydomain.com - byname@" account

MailMate encountered the following error: "Server response: "M4 NO Invalid mailbox name.". Command attempted "M4 SUBSCRIBE "[Gmail].Archive"".".
Mailbox: "[Gmail]/Archive".

[Retry] [Take Account Offline] [Try Later]

03:46:50 S:
03:46:50 Clearing connection to secure.runbox.com
03:46:50 Synchronizing mailbox (attempting to do it quickly): INBOX/Sent
03:46:50 Selecting mailbox: INBOX/Sent
03:46:50 Clearing connection to secure.runbox.com
03:46:50 Trying to connect to secure.runbox.com on port 993
03:46:52 Successful connection on socket 87.
03:46:52 Initiating secure connection...
03:46:54 Setup of secure connection complete (TLSv1).
03:46:54 Cipher: AES256-SHA SSLv3 Kx=RSA Au=RSA Enc=AES(256) Mac=SHA1
03:46:54 C: D0 LOGIN ••••••••••
03:46:55 S: D0 OK LOGIN Ok.
03:46:55 C: D1 CAPABILITY
03:46:55 S: D1 OK CAPABILITY completed
03:46:55 C: D2 LIST INBOX ""
03:46:56 S: * LIST (\Unmarked \HasChildren) "." ""
03:46:56 S: D2 OK LIST completed
03:46:56 C: D3 SELECT "INBOX.Sent"
03:46:56 S: * FLAGS (\Draft \Answered \Flagged \Deleted \Seen \Recent)
03:46:56 S: * OK [PERMANENTFLAGS (\Draft \Answered \Flagged \Deleted \Seen)] Limited
03:46:56 S: * 0 EXISTS
03:46:56 S: * 0 RECENT
03:46:56 S: * OK [UIDVALIDITY 1396668612] Ok
03:46:56 S: * OK [MYRIGHTS "acdilrsw"] ACL
03:46:56 S: D3 OK [READ-WRITE] Ok
03:46:56 C: D4 NOOP
03:46:57 S: D4 OK NOOP completed
03:46:57 Performing full synchronization.
03:46:57 S: D5 OK FETCH completed.
03:46:57 Completed action. Observed read/write timeouts: 8/8
03:46:57 Synchronizing mailbox (attempting to do it quickly): INBOX/Trash
03:46:57 Selecting mailbox: INBOX/Trash
03:46:57 C: D6 LIST INBOX ""
03:46:58 S: * LIST (\Unmarked \HasChildren) "." ""
03:46:58 S: D6 OK LIST completed
03:46:58 C: D7 SELECT "INBOX.Trash"
03:46:58 S: * FLAGS (\Draft \Answered \Flagged \Deleted \Seen \Recent)
03:46:58 S: * OK [PERMANENTFLAGS (\Draft \Answered \Flagged \Deleted \Seen)] Limited
03:46:58 S: * 0 EXISTS
03:46:58 S: * 0 RECENT
03:46:58 S: * OK [UIDVALIDITY 1396668617] Ok
03:46:58 S: * OK [MYRIGHTS "acdilrsw"] ACL
03:46:58 S: D7 OK [READ-WRITE] Ok
03:46:58 C: D8 NOOP
03:46:59 S: D8 OK NOOP completed
03:46:59 Performing full synchronization.
03:46:59 S: D9 OK FETCH completed.
03:46:59 Completed action. Observed read/write timeouts: 8/8
03:46:59 Creating mailbox
03:46:59 C: M10 LIST "[Gmail]" ""
03:46:59 S: M10 OK LIST completed
03:46:59 Error: Failed to obtain the hierarchy delimiter of non-existing mailbox “[Gmail]” ([Gmail]/Archive).
03:46:59 C: M11 CREATE "[Gmail].Archive"
03:47:00 S: M11 NO Invalid mailbox name.
03:47:00 Error: Server response: “M11 NO Invalid mailbox name.”. Command attempted: “M11 CREATE "[Gmail].Archive"”.
03:47:00 C: M12 SUBSCRIBE "[Gmail].Archive"
03:47:00 S: M12 NO Invalid mailbox name.
03:47:00 Error: Server response: “M12 NO Invalid mailbox name.”. Command attempted: “M12 SUBSCRIBE "[Gmail].Archive"”.
03:47:00 Error code: 1001
03:47:00 Failed action. Reset observed read/write timeouts: 8/8
03:47:00 Trying to disconnect nicely...
03:47:00 C: M13 LOGOUT

Comments and changes to this ticket

  • Meindert

    Meindert April 5th, 2014 @ 03:50 AM

    Of course, the whole [Gmail]/Archive thing is just a clumsy hack to deal with Gmail. Ideally, after transitioning to another e-mail provider, I'd just like to get rid of that mailbox, right?

  • benny

    benny April 5th, 2014 @ 02:08 PM

    I assume you got into this problem when you dragged the “[Gmail]/Archive” mailbox into the Runbox account?

    I think you can fix it by renaming “[Gmail]/Archive” into “Archive” in MailMate. Then when MailMate retries it should successfully create the mailbox server-side and start uploading messages. Afterwards (it'll take a long time) you should keep this mailbox. When you use the “Archive” button in MailMate, this is the mailbox that is going to be the default destination.

    Does that make sense to you?

    For the record, I cannot see why the server rejects the mailbox name as invalid. This is output when trying to create the same mailbox on my own server:

    C: M6 CREATE "[Gmail].Archived"  
    S: M6 OK Create completed.  
    C: M7 SUBSCRIBE "[Gmail].Archived"  
    S: M7 OK Subscribe completed.
  • Meindert

    Meindert April 8th, 2014 @ 07:12 AM

    No I don't think I dragged anything--do you mean dragging something inside MailMate?

    What I did was go to the account in Gmail's webmail interface, make sure that there were no labels, create a [Gmail]/Archive label, and assign all e-mail to that. In Runbox I think I just created the account and then added the account to MailMate. I may have created a [Gmail]/Archive label in Runbox, but I don't think so, I don't remember doing it, and trying it now Runbox will not accept either a [Gmail]/Archive or [Gmail].Archive mailbox name (making just an Archive mailbox is fine though, so Runbox seems to be rejecting slashes and periods or maybe square brackets in mailbox names.

    I can see that this is going to be one of those he said/she said issues where I'll have to go back and forth between here and Runbox's support until I figure it out.

  • benny

    benny April 8th, 2014 @ 01:01 PM

    Yes, I meant how you moved messages from the Gmail account to the Runbox account.

    In any case, based on your log I think renaming “[Gmail]/Archive” into “Archive” in MailMate should fix the issue. As you state it seems Runbox enforces some limitations on mailbox names, but that is not a problem since you don't need to have a mailbox named “[Gmail]”.

  • Meindert

    Meindert April 8th, 2014 @ 01:17 PM

    I don't understand the steps I need to take. Here's how I've assumed it works:

    I manage to get all my e-mail into MailMate (by deleting labels in Gmail, making the [Gmail]/Archive label, and putting everything in that ... and waiting for MailMate to download it all.

    Then I sign up for Runbox (or another IMAP provider), point my DNS MX to them, create identically named e-mail address accounts, enter the new passwords and stuff into MailMate.

    Then, I assumed, I just wait for synchronization.

    If this won't work, ... what? I rename [Gmail]/Archive in MailMate to Archive? Is that what you're saying? And then wait until synchronization?

  • benny

    benny April 8th, 2014 @ 01:39 PM

    No! This is not how it works (in any email client). I thought I wrote this to you somewhere, but now I cannot find it: You migrate by having both the Gmail account AND the Runbox account in MailMate at the same time. You then drag messages or mailboxes from Gmail to Runbox. You should NOT change the IMAP account that MailMate accesses with the same settings because that does not work well with IMAP. But you probably cannot go back now, so let us take it from there.

    IMAP: Each mailbox has a unique value (UIDVALIDITY). If this changes it is a sign to the email client that it is not longer the same mailbox. The email client MUST then delete its local cache of emails for that mailbox and then fetch any messages located on the server.

    In other words, I think what you did should have triggered MailMate to delete any messages locally for mailboxes with the same name at Gmail and Runbox, because for MailMate it looks like the old mailboxes were deleted and some new ones took their place. Now, Gmail and Runbox do not share many mailbox names (apart from INBOX) and that might “save” you.

    And yes, I think you can fix it by renaming “[Gmail]/Archive” in MailMate to “Archive”, but I also think it'll be safer if you create the “Archive” mailbox and then move the messages instead. If you do the latter then you can start out by moving a small number of messages and see if they appear on the server as expected.

    (Finally, I hope you still have the Gmail account and all messages in that account. That'll allow you to start over if everything fails.)

    Sorry if I have been unclear in previous comments.

  • Meindert

    Meindert April 9th, 2014 @ 07:38 AM

    O.K., I think I understand now.

    Don't panic--my Gmail-to-Runbox test involved an unused e-mail address that only has seven e-mails in it's archives, mostly in the nature of "Welcome to Gmail" and "Welcome to Runbox."

    I'll pick another unused Gmail account, make a new Runbox account, and try dragging messages and/or mailboxes. Assuming it works, I'll abandon and delete the trial Runbox account and start again with a proper, paid-for Runbox account.

  • Meindert

    Meindert April 9th, 2014 @ 07:40 AM

    By the way, Runbox does have a automated transfer service, but I've read here and there that such services are not always reliable (I believe I read someone complaining somewhere that Fastmail choked on his large mailbox when he tried to transfer it). I feel safer in getting my Gmail on my own Macintosh as a first step.

  • benny

    benny April 9th, 2014 @ 08:08 AM

    • State changed from “new” to “resolved”

    Ok, I'm glad there is no risk of lost emails. Doing it with MailMate (or another IMAP email client) also allows you to move messages in smaller batches and verify that it works as expected.

    With respect to the original problem in this ticket I'll mark it as resolved, but you can still add comments about the migration process if you like.

  • Meindert

    Meindert April 9th, 2014 @ 08:23 AM

    A couple of things I'm unsure about:

    1. Is it O.K. in MailMate/IMAP clients to have two accounts for the same e-mail address (but different mail servers)?

    2. Can I delete an account in MailMate without MailMate trying to delete the account at Gmail (in order to start with a fresh account in MailMate)?

    With regard to (1), the MX nameserver only points to one of the online accounts at any given time. Right now it's going to Gmail. I assume that doesn't really make any different to MailMate? As long as I give it an IMAP and an SMTP server, it operates independently of the nameserver?

    So my plan is to delete the current account in MailMate just to start fresh. (It started out pointed at Gmail, and now it's pointed at Runbox, so I'm not sure how screwed up it is.)

    Then I'd create two new accounts for the e-mail address.

    Then I'd update them (especially Gmail). Then I'd drag mail in MailMate from Gmail to Runbox, creating new mailboxes if necessary, which would be created on Runbox automatically upon a synchronization. Right?

  • benny

    benny April 9th, 2014 @ 08:35 AM

    1. Yes. As long as username+servername for the IMAP server is a unique combination then it's fine. (One caveat: If you actually list the same email address for the two accounts then MailMate is going to be confused about which one to use when creating messages, but for migration purposes you don't even need to list an email address.)

    2. Yes, removing an account in MailMate only clears the local cache (this can be slow for large accounts). If you have any messages (for example, drafts) which are not uploaded to the server then MailMate won't delete them unless explicitly told to do so.

    The nameserver trick is bad (for any email client): MailMate doesn't know that you change the IMAP account behind its back. The behavior of MailMate in this scenario is unknown, but it's going to be similar to removing part of the account and leaving other parts of the account in some kind of limbo.

    Your plan sounds perfect.

  • Meindert

    Meindert April 10th, 2014 @ 05:37 AM

    Someone should write an RFC for an extension to the IMAP standard that allows for automated account migration.

  • Meindert

    Meindert April 17th, 2014 @ 08:02 AM

    I've done this to transition mail from Gmail to an ISP where the domain's website is hosted:

    • Do the settings at the ISP to get the mail account set up, including choosing a password.

    • Flip the switch on the nameserver MX records (I don't think the timing of this is important).

    • Select and drag, in MailMate, all the messages in the Gmail-hosted mailbox to the ISP-hosted mailbox.

    Now the problem: Duplicate messages.

    Is the Gmail-linked account re-downloading the e-mail messages after the drag? I dragged, it took a while, and I noticed messages still in the Gmail mailbox, and I selected again and re-dragged. And I probably did it a third time. If there is re-downloading, maybe I did this before the re-download was completed (because I did a quick sanity check for duplicates and didn't see any).

    Assuming that MailMate/IMAP is duplicating, how do I avoid it? Do I wait until the MX nameserver propagation is 100 percent done before dragging messages? (But that wouldn't help ... would it?) Do I edit the IMAP account settings in MailMate to fake server values to break things amd make re-downloading impossible?

    And how do I fix things so that the ISP doesn't have the duplicate messages? Can I clean things up there somehow?

    EDIT 1:

    Displaying the "Msg ID" column, I don't see any duplicates.

    But sorting by "Date Received," many of the messages have duplicates.

    EDIT 2:

    I just had a brainstorm: Should I have right-clicked the Gmail mailboxes and chosen "Take Offline" prior to dragging the mail to a new mailbox?

    And then after confirming the transition, deleted the Gmail mailboxes in MailMate, and go online to Gmail to delete them there also ....

  • Meindert

    Meindert April 17th, 2014 @ 08:04 AM

    (A message deduping function in MailMate would really help in situations like this, unless that would somehow trigger the IMAP singularity and cause the planet to get sucked into a black hole.)

  • Meindert

    Meindert April 24th, 2014 @ 05:52 AM

    I am just about to pull the plug on my main Gmail account, and delete it from Google. I have a corresponding account for it in MailMate. I bought a Runbox account to move it to and created a second MailMate account for that. I dragged the messaged in MailMate from the old to the new. They synchronized.

    The only remaining thing is that the number of messages in the two Archive mailboxes in the two accounts in MailMate are slightly different:

    Gmail: 35,883
    Runbox: 35,490

    I de-duped the Gmail account, and there weren't any.

    My options:

    1. Just forget about the 400 or so message discrepancy and nuke the Gmail account. 1 percent, how important could it be?

    2. Drag all 35,883 messages over to the Runbox Archive mailbox again, wait 24 hours for syncing, and see what happens; de-dupe if necessary.

    3. Edit the Gmail account to point to Runbox. I think you said that this is a very, very bad idea.

    4. Attempt to manually compare the contents of the Archive mailboxes somehow (sorting and comparing last message on umpteenth page-up, looking for differences?)

    5. Something else I haven't thought of.

    The nameserver is long since changed and propagated to Runbox. I don't think 400 e-mails could have come in to Gmail before the propagation completed, and examining the recent messages in both accounts, there aren't that many in the past week.

  • benny

    benny April 24th, 2014 @ 09:30 AM

    First of all, I suggest keeping the Gmail account for a while until you are 99.9% sure nothing is lost and everything has been uploaded to Runbox.

    I don't think 2 is a good option. Far too inefficient. Don't do 3 and I don't even know why you would do that :-) That leaves a combination of 4/5:

    Create a smart mailbox where you only list the Gmail Archive mailbox in the Mailboxes pane. In the conditions pane you should put:

    [Message-ID] “is not in” [Runbox ▸ Archive] [Message-ID]

    In other words, the mailbox is going to show you any message with a Message-ID in Gmail which does not have a Message-ID in Runbox.

  • Meindert

    Meindert April 24th, 2014 @ 12:28 PM

    Wow, I had no idea you could do that with smart mailboxes. MailMate is really deep. (You should start to keep a list of tricks like this to pitch to some of the geekier Mac bloggers as ideas for posts to promote MailMake. Or have a section on the website called MailMate Recipes for inspiration.)

    However ...

    I tried it and I got zero results. Then I changed "is not in" to "is in" and got zero results, which seems impossible--it has to be one or the other.

    My Gmail account is mostly saying "unavailable" (although the data is all locally downloaded), if that makes a difference; doesn't seem like it would. I tried adding "Any" and "Subject" "contains" "[common word]", and got results in the smart mailbox. Maybe there's a glitch in the Message-ID implementation in smart mailboxes?

    EDIT: There are three Message IDs in the menu, two with a hyphen, one without. I used the one without. I'll try the others now.

    EDIT 2: The first Message-ID works. Are the other two supposed to be there?

    EDIT 3: I found 670 messages that weren't in the Runbox mailbox, and I'm copying them now.

    By the way, another question: Given that I originally selected and dragged all the messages in the Gmail Archive mailbox to the Runbox Archive mailbox, shouldn't that have been a move, not a copy? If so, then I must have screwed something up somewhere, given that they remained on Gmail.

  • benny

    benny April 24th, 2014 @ 12:41 PM

    MailMate lists every header found in every message. One of the 'hyphen'-variants must have been different than the other one (different kind of hyphen or spelling perhaps?). I only have one variant in my own message store.

    And yes, it should have been a “move” by default. That worries me a bit. Only holding down ⌥ would make it a copy. The move should have been reflected just after moving and then the actual work would be done in the background. I guess this was also not the case, i.e., the messages did not first disappear and then reappear? (Note that the messages would probably still be in “[Gmail]/All Mail” after the move.)

    Did moving the 670 messages work as expected?

  • Meindert

    Meindert April 25th, 2014 @ 03:23 AM

    I see--so the list was generated from headers on my own e-mail corpus. At any rate, I'm beginning to realized all the cool stuff I can do with smart mailboxes in MailMate.

    The messages moved as expected: the MM Gmail count was less by 670, MM Runbox was more by about 800 (which must include incoming mail and spam overnight), and Runbox Webmail matches MM Runbox. Gmail Webmail, which should not be receiving any more new e-mail since the MX records changed, is about 1,400 less since yesterday, not 670, and that's conversations, I guess, not messages. I don't know what's going on there, but I guess I don't really care at this point.

    Now on to moving three more, smaller accounts to Runbox.

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป

Mac OS X email client.

Shared Ticket Bins

People watching this ticket