Applies to: Office 365 for professionals and small businesses, Office 365 for enterprises, Live@edu
Topic Last Modified: 2011-12-02
Use E-mail Migration in the Exchange Control Panel to migrate the contents of user mailboxes from an IMAP messaging system to your cloud-based e-mail organization.
To start an IMAP migration, select Manage My Organization > Users & Groups > E-Mail Migration > New. On the Welcome to E-mail Migration page, select IMAP and click Next.
Important For an IMAP migration, you can only migrate a user’s inbox or other mail folders. You can’t migrate contacts or calendar items. Additionally, a maximum of 500,000 items can be migrated from a user’s mailbox.
In this topic
Before you begin
Before you migrate mail from an IMAP server, be sure to plan your e-mail migration carefully, especially if you're migrating lots of users. When you plan, make sure to check out Best practices.
To prepare for the migration:
-
Create a cloud-based mailbox for each user that you will migrate Before you can migrate data from a user's mailbox on the IMAP server, the user has to have a cloud-based mailbox and user ID. Here's how to create new mailboxes and user ID for each user:
-
Obtain the FQDN for your IMAP server You need to provide the FQDN of the IMAP server that you will migrate mailbox data from, for example, imap.contoso.edu.
Tip Use an IMAP client or the PING command to verify that you can use the FQDN to communicate with the IMAP server over the Internet.
-
Configure your on-premises firewall to allow IMAP connections You may have to open ports in your on-premises firewall so network traffic originating from the Microsoft datacenter during the migration is allowed to enter your on-premises organization. For a list of IP addresses used by Microsoft datacenters, see Exchange Online URLs and IP Address Ranges.
-
Decide which folders you don't want to migrate from the IMAP messaging system For example, you may not want to migrate the contents of the Deleted Items and Junk Mail, and shared or public folders.
Important If you're migrating e-mail from an on-premises Microsoft Exchange server, we recommend that you exclude public folders from the migration. If you don't exclude public folders, the contents of the public folders are copied to the cloud-based mailbox of every user.
-
Prepare the CSV file Identify the group of users whose mailboxes you want to migrate. Include these users in the CSV file that will make up the migration batch. If you have to migrate thousands of mailboxes, it's a good idea is to migrate users in several smaller batches. For example, if you have 10,000 accounts to migrate, you could run four batches with 2,500 users each, or you could divide the batches alphabetically, by user type, such as faculty, students, and alumni, by class, such as freshman, sophomore, junior, and senior, or in other ways that will help you keep track of the users you've migrated.
Here are the required attributes for each user:
-
EmailAddress specifies the user ID for the user's cloud-based mailbox.
-
UserName specifies the user logon name for the user's mailbox on the IMAP server.
-
Password is the password for the user's account in the IMAP messaging system.
For the UserName attribute, in addition to the user name, you can use the credentials of a super-user account or administrator account that has the rights to access all mailboxes on the IMAP server. For more information, see Prepare a CSV File to Migrate E-mail from an IMAP Server.EmailAddress,UserName,Password terrya@contoso.edu,terry.adams,1091990 annb@contoso.edu,ann.beebe,2111991 chrisc@contoso.edu,chris.cannon,3281986
Tip Use the CSV file that you used to import new users as the starting point for CSV migration file. For example, if you import 2,000 new users to your organization in the cloud, create a CSV file to migrate mail for those same 2,000 users.
-
EmailAddress specifies the user ID for the user's cloud-based mailbox.
-
Assign the super-user or administrator account permissions to access mailboxes in your Exchange organization If you use administrator credentials in the CSV file, the account that you use must have the necessary permissions to access the on-premises mailboxes. You can assign the Full Access permission for individual mailboxes or assign the Receive As permission for a mailbox database. For more information, see the following:
Exchange 2010
Exchange 2007
Exchange 2003
-
Microsoft Knowledge Base article 268754 - How to assign users or groups full access to other user mailboxes
-
Microsoft Knowledge Base article 821897 - How to assign service account access to all mailboxes in Exchange Server 2003
-
Microsoft Knowledge Base article 268754 - How to assign users or groups full access to other user mailboxes
Run a migration batch
Step 1: Configure your server settings for e-mail migrations
-
Select Manage My Organization > Users & Groups > E-Mail Migration > New.
-
On the Welcome to E-mail Migration page, select IMAP and click Next.
-
Configure the server settings.
Note The server settings you configure will persist on this page the next time you run E-Mail Migration to migrate a new batch of mailboxes.In this field… Do this… * IMAP server
Type the FQDN of the IMAP server for the IMAP messaging system.
Authentication
Select the authentication method used by the IMAP server. Options are
Basic, the default, orNTLM. UseNTLMif it's required by your IMAP server.Encryption
Select the encryption method used by the IMAP server. Options are
None,TLS, orSSL, the default.* Port
Select the TCP port number used to connect to the IMAP server. Use port 143 for unencrypted connections, port 143 for TLS connections, and port 993 for SSL connections.
Number of mailboxes to migrate simultaneously
Specify the number of connections to the IMAP server available to migrate e-mail to cloud-based mailboxes. If the value is set to 3, the default value, you can migrate up to three mailboxes at the same time until all the mailboxes in the migration batch have been migrated. The maximum number of connections is 10. To learn more about how to optimize this setting, see Maximum Number of Connections to Your Mail Server.
-
Click Next. Microsoft Exchange tries to communicate with the IMAP server to verify the server's FQDN and the port used to receive the IMAP requests. If the test connection to the IMAP server is successful, the Exclude specific folders from e-mail migration page is displayed. If the test connection isn't successful, you'll get an error. Verify the configuration settings and try to connect again. You have to connect to the IMAP server to continue.
If you can’t connect to the IMAP server, see this video for troubleshooting tips.
Step 2: Exclude specific folders from e-mail migration
You may not want to migrate the contents of certain folders in users' mailboxes, such as Deleted Items or Junk E-Mail. You can also exclude shared and public folders. Here's how:
-
Click Add folders to exclude. Type the name of the folder and click Add
. Be sure to type the folder name exactly as it appears, for example, Deleted Items.
-
You can add more than one folder to the list. When you are finished adding folders, click OK.
-
Click Next.
Important If you're migrating e-mail from an on-premises Microsoft Exchange server, we recommend that you exclude public folders from the migration. If you don't exclude public folders, the contents of the public folders are copied to the cloud-based mailbox of every user.
Also, folders with a forward slash ( / ) in the name aren't migrated. If users want to migrate folders that contain forward slashes in their names, they have to rename the folders or replace the forward slash with a different character, such as an underscore character ( _ ) or a dash ( - ).
Step 3: Upload a batch of mailboxes to migrate
-
Click Browse to select the CSV file for the migration batch.
-
After you select the CSV file, click Next. Microsoft Exchange checks the CSV file for the following:
-
It isn't empty.
-
It uses comma-separated formatting.
-
It doesn't contain more than 50,000 rows.
-
It isn't larger than 10 MB.
-
It includes the required attributes in the header row:
• EmailAddress, which specifies the Windows Live ID for the user's cloud-based account
• UserName, which specifies the user logon name for the user's mailbox in the IMAP messaging system
• Password, which specifies the password for the user's account in the IMAP messaging system
-
It contains rows with the same number of columns as the header row.
If the CSV file successfully passes these checks, you'll move on to the Start the migration page.
-
It isn't empty.
Step 4: Start the migration
In addition to the checks described in step 3, Microsoft Exchange also checks for data validation errors in the CSV file. If data in any row of the CSV file doesn't meet the property definition for the corresponding attribute in the header, you'll get an error. The migration process isn't terminated if data validation errors are found, but e-mail won't be migrated for the mailboxes that correspond to the rows that have data validation errors. If data validation errors are found, a warning and a link to the validation error report are displayed on the Start the migration page. For more information, see Troubleshoot Migration Validation Errors.
To start the migration:
-
Decide if you want Microsoft Exchange to send a status e-mail message to other users when the migration batch is done running. If so, click the Browse to select one or more users.
-
Review the migration settings.
-
To start processing the migration batch, click Run.
-
To cancel the current migration batch and return to step 1, click Start Over.
-
To start processing the migration batch, click Run.
What happens after you start the migration batch?
After you start the migration, two panes are displayed on the E-Mail Migration tab:
-
Active E-Mail Migration This pane contains the following information about the migration batch in progress:
-
The name of the CSV file used for the migration batch
-
The date and time when the migration batch was started, and the user who started the migration
-
The total number of migrations requested. This number corresponds to the number of rows in the CSV migration file.
-
The number of migration requests from the current migration batch that have been completed. This field is updated throughout the migration.
-
The number of active mailbox migrations. This number corresponds to the number of simultaneous connections that you specified in step 1 of setting up the migration.
-
A link to the Active Mailbox Migration Report, which shows detailed information about each mailbox that is being actively migrated. A compilation of this report, which contains similar information for all the mailboxes in the migration batch, is included in the status e-mail sent to the administrator after the migration batch is finished.
-
The number of mailboxes that failed to be migrated
-
A link to the Error Report for Active Migrations that documents each migration error found during the processing of the current migration batch. For each error, the report includes a suggestion for fixing the error. Use this information to fix the error, and then submit a revised CSV file for a new migration batch. For more information, see Troubleshoot Active Migration Errors.
periodically to refresh this pane during the processing of the current migration batch. When the migration batch is done, the Active E-Mail Migration pane is no longer displayed.
-
The name of the CSV file used for the migration batch
-
E-Mail Migration This pane contains information about the overall migration, which consists of all the migration batches that you've run. It contains the following information:
-
The number of mailboxes from all migration batches that have been migrated and are actively being synchronized with the corresponding on-premises mailbox
-
The number of synchronization errors that have occurred since the migration was started
-
A link to the Error Report for Synchronization Failures, which identifies synchronization failures that are preventing Microsoft Exchange from retrieving new e-mail messages sent to a user's mailbox in the IMAP messaging system. For more information, see Troubleshoot Migration Synchronization Failures.
-
The number of mailboxes from all migration batches that have been migrated and are actively being synchronized with the corresponding on-premises mailbox
Stop a migration batch
To stop a migration batch, in the Active E-Mail Migration pane, click Stop.
You can only stop migration batches that have mailboxes in the process of being migrated or are waiting to be migrated. The migration of any mailbox currently being processed is stopped immediately and is not completed. Also, stopping a migration batch won't affect mailboxes that have been migrated already.
After you stop a migration batch, you receive a status e-mail message that says how many mailboxes were successfully migrated before the batch was stopped. This message also has an attached MigrationErrors.csv file that identifies the rows that were in progress when the migration was stopped and the rows waiting to be migrated.
Start additional migration batches
After the current migration batch is complete, repeat steps 1 through 4 to run additional migration batches. Each migration batch uses its own CSV file.
Complete the migration
After you've run all your IMAP migration batches for the mailboxes you plan to migrate, you're ready to complete the migration. Follow these steps:
-
Configure your MX record to point to your cloud-based e-mail organization Until you change your MX record, e-mail sent to users is still routed to their mailboxes in the IMAP messaging system. When a user mailbox is successfully migrated, the mailbox on the IMAP server and cloud-based mailbox are periodically synchronized until you complete the overall migration. This lets users use their cloud-based account to access e-mail sent to their IMAP mailbox. When you configure your organization's MX record to point to your cloud-based e-mail organization, all e-mail is sent directly to the cloud-based mailboxes.
After you change the MX record and verify that all e-mail is being routed to cloud-based mailboxes, you're ready to complete the migration.
Important It can take from 24 to 72 hours for the updated MX record to be propagated. Wait at least 24 hours after you change the MX record before you complete the migration. Verify that mail is being routed to cloud-based mailboxes before you complete the migration.
-
Complete the overall migration process Click Complete Migration in the E-Mail Migration pane. What happens when you click Complete Migration?
-
Microsoft Exchange runs a final synchronization for all mailboxes. After this, e-mail is no longer synchronized between mailboxes on the IMAP messaging system and cloud-based mailboxes.
-
Microsoft Exchange sends a final status e-mail message after the migration is complete. If there are any errors during the final synchronization process, a MigrationErrors.csv file that lists the errors is attached to this message.
-
Microsoft Exchange runs a final synchronization for all mailboxes. After this, e-mail is no longer synchronized between mailboxes on the IMAP messaging system and cloud-based mailboxes.
Best practices
Here are some tips to optimize your IMAP migration:
-
Increase the connection limits to your IMAP server Many firewalls and e-mail servers have per-user limits, per-IP address limits, and overall connection limits. Before you migrate mailboxes, make sure that your firewall and IMAP server are configured to allow a large, or maximum, number of connections for the following settings:
-
The total number of connections to the IMAP server
-
The number of connections by a particular user. This is important if you use administrator credentials in the CSV migration file because all connections to the IMAP server are made by this user account.
-
The number of connections from a single IP address. This limit is typically enforced by the firewall or the e-mail server.
For more information, see:
-
Exchange 2010: View or Configure IMAP4 Properties
-
Exchange 2007: How to Set Connection Limits for IMAP4
-
Exchange 2003: How to Set Connection Limits
-
The total number of connections to the IMAP server
-
Change the DNS Time-to-Live (TTL) setting on your MX record Before you start migrating mailboxes, change the DNS TTL setting on your current MX record to a shorter interval, such as 3600 seconds (one hour). Then, when you change MX record to point to your cloud-based e-mail organization after all mailboxes are migrated, the updated MX record should propagate more quickly because of the shortened TTL interval.
-
Run one or more test migration batches Run a few small IMAP migration batches before you migrate larger numbers of users. In a test migration, you can do the following:
-
Verify the format of the CSV file.
-
Test the settings used to connect to the IMAP server
-
Verify you can successfully migrate e-mail using super-user credentials, if applicable.
-
Determine the optimal number of simultaneous connections to the IMAP server that minimize the impact on your Internet bandwidth. For more information, see Maximum Number of Connections to Your Mail Server.
-
Verify that folders you exclude aren't migrated to the cloud-based mailboxes.
-
Determine how long it takes to migrate a batch of users.
-
Verify the format of the CSV file.
-
Create mailboxes and migrate e-mail for the same batch of users Use the CSV file that you used to import new users as the starting point for the CSV file. For example, if you import 2,000 new users to your cloud-based e-mail organization, create a CSV file to migrate mail for those same 2,000 users. This is an effective way to organize and manage your migration from an on-premises messaging system to your cloud-based organization.
-
Use super-user or administrator credentials in the CSV file to migrate e-mail This method is the least disruptive and inconvenient for users, and it will help minimize synchronization errors caused when users change the password on their on-premises account. It also saves you from having to obtain or change user passwords. If you use this method, be sure to verify that the administrator account you use has the necessary permissions to access the mailboxes you are migrating.
Tip If you decide to use user credentials in the CSV file, consider globally changing users' passwords and then preventing users from changing their password on their on-premises account before you migrate their mailboxes. If users change their password before their mailbox is migrated to the cloud-based mailbox, the migration will fail. If they change their password after the mailbox is migrated, new e-mail sent to their mailbox on the IMAP server will not be migrated to their cloud-based mailbox.
-
Don't delete mailboxes or change their SMTP addresses during migration The migration system will report an error when it can't find a mailbox that's been migrated. Be sure to complete the migration before you delete or change the SMTP address of a cloud-based or on-premises mailbox that's been migrated.
-
Communicate with your users Give users a heads-up that you are migrating the content of their on-premises mailboxes to your cloud-based organization. Consider the following:
-
Tell users that e-mail messages larger than 35 MB won't be migrated. Ask users to save very large messages and attachments to their local computer or to a removable USB drive.
-
Ask users to delete old or unnecessary e-mail messages from the on-premises mailbox before migration. This helps reduce the amount of data that has to be migrated and can help reduce the overall migration time. Or you can clean up their mailboxes yourself.
-
Suggest that users to back up their Inbox.
-
Tell users which folders won't be migrated.
-
Folders with a forward slash ( / ) in the folder name aren't migrated. If users want to migrate folders that contain forward slashes in their names, they have to rename the folders or replace the forward slashes with a different character, such as an underscore character ( _ ) or a dash ( - ).
-
Tell users when they can use their cloud-based account to access the e-mail that was migrated from their on-premises account. Don't give users access to their cloud-based accounts until you're ready to complete the migration.
Need a good way to provide users with information about their new cloud-based accounts? See Send a Welcome Message to New Users.
-
Tell users that e-mail messages larger than 35 MB won't be migrated. Ask users to save very large messages and attachments to their local computer or to a removable USB drive.
