In Hybrid Exchange scenarios, if an Active Directory user has been synced to Microsoft 365 without an on-prem mailbox being created first and you assign a Microsoft 365 license to the user, an Exchange Online mailbox will be established. If you come back to On-Prem Exchange Server and create a mailbox, then a mailbox will exist in both locations.
Where you want to remove the Exchange Online mailbox and keep the On-Prem Exchange Server mailbox, follow the below steps.
- Confirm that the Exchange Online mailbox does not contain content that should be kept.
- In Microsoft 365, remove the Exchange Online P1 or P2 license that the user has assigned.
- Wait until the Online Mailbox has been soft-deleted for the user. Exchange Admin Center should remove the mailbox from https://admin.exchange.microsoft.com/#/mailboxes
- Confirm that Azure AD Connect has performed a sync and that the user object appears as a Mail Contact in Exchange Online. Exchange Admin Center should display a mail user at https://admin.exchange.microsoft.com/#/contacts
- Open Exchange Online PowerShell and connect to you tenancy.
- Type the command:
Set-User <user@domain.com> -PermanentlyClearPreviousMailboxInfo
NOTE: This will permanently remove the Exchange Online mailbox from the service. - Wait a few minutes, then reassign the Exchange Online P1 or P2 license to the user.
For more information, see:
Permanently Clear Previous Mailbox Info
https://techcommunity.microsoft.com/t5/exchange-team-blog/permanently-clear-previous-mailbox-info/ba-p/607619
Comments
0 comments
Please sign in to leave a comment.