Sign up for Office 365
Learn more about Office 365
Tim Heeney, Sr. Program Manager, Microsoft Services
Marc Nivens, Sr. Escalation Engineer, Exchange Server Support
Lou Mandich, Sr. Premier Field Engineer, Microsoft Services
If you’ve completed a staged Exchange migration to migrate your organization’s Exchange 2007 on-premises mailboxes to Office 365 and you want to manage cloud-based users from your on-premises organization—using Active Directory—you should convert the on-premises mailboxes to mail-enabled users (MEUs). Why? Two things happen after a mailbox is migrated to the cloud in a staged Exchange migration:
This behavior results in two issues:
So, what is the best solution to resolve these issues? Convert the on-premises mailbox to a mail-enabled user (MEU) in your on-premises organization after the user’s mailbox has been migrated to the cloud. When you convert an on-premises mailbox to an MEU:
We’ve provided a Windows PowerShell script that you can run to convert Exchange 2007 mailboxes to MEUs. When you run this script, the proxy addresses from the cloud-based mailbox are copied to the MEU, which resides in Active Directory. Also, the properties of the MEU enable DirSync to match the MEU with its corresponding cloud mailbox.
We’ve also provided a PowerShell script that collects information from the cloud-based mailboxes.
You can run both of these PowerShell script in the Exchange Management Shell in your on-premises Exchange organization.
Best Practice: It’s recommended that you convert on-premises mailboxes to MEUs for a migration batch. After a staged Exchange migration batch is finished and you have verified that all mailboxes in the batch are successfully migrated and the initial synchronization of mailbox items to the cloud is complete, convert the mailboxes in the migration batch to MEUs.
There are scripts to help you convert mailboxes to MEUs. Click the following links to download the scripts.
Here’s a brief description of what each script does.
This is a Windows PowerShell script that collects information about the cloud mailboxes that you migrated during the staged Exchange migration. It uses a CSV file to scope the batch of users. It’s recommended that you use the same migration CSV file that you used to migrate a batch of users.
When you run the ExportO365UserInfo script:
This a PowerShell script that you run in your on-premises Exchange 2007 organization to convert mailboxes to MEUs. It uses the Cloud.csv file, which is output by the ExportO365UserInfo script.
When you run the Exchange2007MBtoMEU.ps1 script, it does the following for each mailbox listed in input CSV file:
1. Copy ExportO365UserInfo.ps1, Exchange2007MBtoMEU.ps1, and the CSV file used to run the migration batch to the same directory in your on-premises organization.
2. Rename the migration CSV file to migration.csv.
3. In the Exchange Management Shell, run the following command. The script assumes that the CSV file is in the same directory and is named migration.csv.
.\ExportO365UserInfo.ps1
You will be prompted to use the existing session or open a new session.
4. Type n and press Enter to open a new session.
5. Enter the administrator credentials for your cloud-based organization and then click OK.
The script runs and then saves the Cloud.csv file to the current working directory.
6. Run the following command in a new Exchange Management Shell session. This command assumes that ExportO365UserInfo.ps1 and Cloud.csv are located in the same directory.
.\Exchange2007MBtoMEU.ps1 <FQDN of on-premises domain controller>
Example:
.\Exchange2007MBtoMEU.ps1 DC1.contoso.com
The script converts on-premises mailboxes to MEUs for all users included in the Cloud.csv.
7. Verify that the new MEUs have been created. In Active Directory Users and Computers, do the following:
The mailboxes that were converted to MEUs are listed under Search results.
8. Use Active Directory Users and Computers, ADSI Edit, or Ldp.exe to verify that the following MEU properties are populated with the correct information.