Exchange Hybrid Migration Cheat Sheet

Design

It is recommended to create a new Exchange server that is not hosting any databases and mailboxes. This new Exchange server is configured as endpoint for the Hybrid Configuration in the Wizard. That way after comleting migrations, you can decommission all other Exchange servers and keep the Hybrid Exchange server, that can be used for management purposes.

Mailbox Limitations

Mailbox sixes

  • Mailboxes must be below 50 GB for users targeting an Exchange Online Plan 1
  • Mailboxes must be below 100 GB for users targeting an Exchange Online Plan 2
  • For in-place archive enabled users, this must not be above 100 GB
  • Recoverable items folder must not be above 30 GB

Export users in-place archive mailbox

If you have users with large amount of data in their in-place archive mailbox, you can manually export their in-place archive mailbox content, then instruct the user to delete content of their in-place archive folder. Then you need to clear the removeable folder items (see section in this article about mailbox cleaning).

Assign your user permissions

You need to grant your self permissions to export from the Exchange on-premises server first:

New-RoleGroup "Mailbox Import-Export Management" -Roles "Mailbox Import Export"**
**Add-RoleGroupMember "Mailbox Import-Export Management" -Member MyAdminAccount

Export mailbox in-place archive

New-MailboxExportRequest –Mailbox "initial@domain.dk" -IsArchive –FilePath \\EXCHANGESERVERNAME\PSTFiles\initial-archive.pst

Enable archive auto-expanding feature

For users with Exchange Online Plan 2 and more than 100 GB of archive storage, the auto-expanding feature needs to be enabled.

Command to enable auto-expanding archive for organization:
Set-OrganizationConfig -AutoExpandingArchive
Command to enable auto-expanding archive per mailbox:
Enable-Mailbox user@domain.dk -AutoExpandingArchive

Move user mailbox to Exchange Online

Now then you have exported mailbox in-place archive data and cleaned the mailbox recoverable items, the remote migration job to Exchange Online should be successful.

Import in-place archive mailbox to mailbox in Exchange Online

  1. Sign in to https://purview.microsoft.com 
  2. Navigate to Solutions, Data Lifecycle Management
  3. Navigate to Import
  4. Create new import job
  5. Give the job a name.
  6. Choose to upload your data.
  7. Retrieve the SAS URL for the import job
  8. Copy data from your local repo to the blob storage using the SAS Token and the AzCopy tool (open CMD as administrator, navigate to folder there azcopy.exe is located)
    azcopy copy "C:\local\path" "INSERT_BLOB-SAS-URL_HERE" --recursive=true
  9. Format the mapping file (.csv format)
Workload,FilePath,Name,Mailbox,IsArchive,TargetRootFolder,ContentCodePage,SPFileContainer,SPManifestContainer,SPSiteUrl
Exchange,,user1-archive.pst,user1@domain.dk,TRUE,,,,,
Exchange,,user2-archive.pst,user2@domain.dk,TRUE,,,,,
  1. Save as .csv file (UTF-8 format)
  2. Import the mapping file when you have uploaded files and proceed in the portal. Remember to validate the file.
  3. Now submit the job
  4. Wait until analysis is done.
  5. Then analysis is complete (It can take a while), you can start the import job
  6. Import everything – do not let the job filter out old mails
  7. Submit the job
  8. Now the actual import is running
    image.png
  9. Monitor that the import job is running, it can take a while

Cleanup mailbox recoverable items

If you have users with large mailboxes and you have instrusted them to delete old mails, but they are still present in RecoverableItems folder (usually 30-90 days depending on your database configuration), you can force remove items using below Exchange PowerShell commands.

This command will show sizes for Recoverable Items in the primary mailbox of initial@domain.dk
Get-MailboxFolderStatistics "initial@domain.dk" -FolderScope RecoverableItems | Format-List Name,FolderAndSubfolderSize

This command will show sizes for Recoverable Items in the in-place archive mailbox of initial@domain.dk
Get-MailboxFolderStatistics "initial@domain.dk" -FolderScope RecoverableItems -archive | Format-List Name,FolderAndSubfolderSize

This command will remove all items in Recoverable Items (both primary and in-place archive mailbox of initial@domain.dk. BE AWARE THAT mails CANNOT be recoved after this, ensure proper backup is taken before executing.
Search-Mailbox -Identity "initial@domain.dk" -SearchDumpsterOnly -DeleteContent

Outlook – Enforce Modern Auth

Symptoms


Consider the following scenarios.
Scenario 1:
Microsoft Outlook connects to your primary mailbox in an on-premises Exchange server by using RPC, and it also connects to another mailbox that’s located in Microsoft 365.
Scenario 2:
You migrate your mailbox to Microsoft 365 from an Exchange server that Outlook connects to by using RPC.
In these scenarios, you’re prompted for credentials, and Outlook doesn’t use Modern Authentication to connect to Microsoft 365. After you enter your credentials, they’re transmitted to Microsoft 365 instead of to a token.

Cause

Outlook limits its choices of authentication schemes to schemes that are supported by RPC. But the authentication schemes don’t include Modern Authentication.

Resolution

Create the following registry key to force Outlook to use a newer authentication method for web services, such as EWS and Autodiscover. Microsoft recommend that users force Outlook to use Modern Authentication.

Create a Group Policy that is linked to the OU there users reside (or devices, remember to ensure loopback processing is configured)

Configure the registry setting AlwaysUseMSOAuthForAutoDiscover to a value of 1, in the path HKEY_CURRENT_USER\Software\Microsoft\Exchange.

Picture below for reference:

Comments

Leave a Reply

Your email address will not be published. Required fields are marked *