Login failed because the mailbox you tried to access is being moved

In preparation of a migration from Exchange 2007 to Exchange 2013 (interorg, so new Active Directory and new Exchange deployment) I had to clean up the Exchange 2007 environment. There was one user that had a 4.5GB Mailbox with over 50,000 items in.

Moving this Mailbox from one Mailbox database to another Mailbox database (in the same Exchange 2007 environment) took a long time and after 8 hours I had to stop the move because it was running into office hours. Unfortunately this broke the Mailbox at some point and the user was confronted with the error message “Login failed because the Mailbox you tried to access is being moved”.

Note. Another mailbox in the same Mailbox database was a little over 5GB in size but had ‘only’ 15,000 items in it. Moving this Mailbox to another Mailbox database took 35 minutes.

I did start this particular Mailbox move myself and I did cancel it the next morning, but other than that I had no clue. A Microsoft Escalation Engineer (participating in the MVP Community) advised to have a closer look at the migration log files that can be found in the C:\Program Files\Microsoft\Exchange Server\Logging\MigrationLogs directory. In this directory you can find both .log files as well as .xml files as shown in the following figure:


In the log file you can find a lot of useful information regarding the mailbox move, for example:

[5/27/2014 6:13:18 PM] [0] [kathy.contoso.com] The operation has started.

[5/27/2014 6:13:18 PM] [0] [kathy.contoso.com] Approving object.

[5/27/2014 6:13:18 PM] [0] [kathy.contoso.com] Opening source mailbox.

[5/27/2014 6:13:18 PM] [0] [kathy.contoso.com] Trying to open mailbox:

szServerLegacyDN: /o=HMC45/ou=Exchange Administrative Group (FYDIBOHF23SPDLT)/cn=Configuration/cn=Servers/cn=AMS-MBX3

szUserLegacyDN: /o=HMC45/ou=Exchange Administrative Group (FYDIBOHF23SPDLT)/cn=Recipients/cn=kathy.contoso.com

szServer: AMS-MBX3.hmc45.local

[5/27/2014 6:13:18 PM] [0] [kathy.contoso.com] Open mailbox succeeded.

[5/27/2014 6:13:18 PM] [0] [kathy.contoso.com] Trying to lock mailbox:

szServer: AMS-MBX3.hmc45.local

pguidMdb: {9AFFD8AA-0B3D-460B-97E9-3A99CFAD08B3}

pguidMailbox: {D290B54B-D662-46E0-BF42-268805FA0D9F}

[5/27/2014 6:13:28 PM] [0] [kathy.contoso.com] Mailbox was locked successfully.

[5/27/2014 6:13:28 PM] [0] [kathy.contoso.com] Preparing mailbox to be moved.

Later in this log file I found the following entry

[5/27/2014 6:13:32 PM] [0] [ERROR] Error was found for Kathy Prince (Kathy.contoso.com) because: Error occurred in the step: Preparing mailbox to be moved. Failed to copy basic mailbox information with error: A duplicate mailbox was found due to problems during a Move Mailbox procedure. The duplicate mailbox has been deleted. Try again later., error code: -1056749241

This user’s Mailbox was still in the Mailbox container under Recipient Configuration (in the Mailbox database MBX14) but could also be found in the Disconnected Mailbox container under Recipient Configuration, for example:


If I disabled this Mailbox the identical Mailboxes were listed in Disconnected Mailbox, one in Mailbox database MBX12 and one in Mailbox database MBX14.

One procedure could be (but didn’t work in my case):

· Disable Mailbox.

· Run Clean-MailboxDatabase MBX12.

· Run Clean-MailboxDatabase MBX14.

· Re-attach Mailbox.

You can find information on the Interwebs that this solved the issue in some cases but I was unlucky.

Next step was to permanently delete the disconnected Mailboxes from the Mailbox database. To achieve this set the Keep deleted items and Keep deleted mailboxes both to “0” as shown in the following figure:


You can wait for the Online Maintenance interval to run, or set the Custom Interval to always run as shown in the following figure:


Restart the System Attendant on the Mailbox server and dismount and mount the Mailbox database (not sure if that last step is mandatory, but it did work though) and Online Maintenance is started quickly. You can see this in the eventlog, check for Event ID 700 and Event ID 703.


A couple of hours later I check the Disconnected Mailboxes and the user’s Mailbox was not listed anymore. At this point the user was able to login again, but the Mailbox still have to be moved to another Mailbox database.

Important note: don’t forget to set the Delete Items Retention and Deleted Mailbox Rentention to their original values!

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s