SOLVED: Office 365 mailbox not showing in Exchange hybrid server admin center
How to fix an issue where an Office 365 user mailbox shows in Exchange online but not on the Exchange hybrid server (on-premises) using PowerShell Enable-RemoteMailbox
I recently had to troubleshoot an issue where a user mailbox still exists in Office 365 even though the Exchange online license had been removed from the user account. The orphaned mailbox shows in Exchange online but does not show in the on-premises Exchange hybrid server admin center. In this case, the mailbox also had litigation hold enabled
Problem: Office 365 mailbox not showing on Exchange hybrid server
The Office 365 user account has an Office 365 E3 license with only Microsoft 365 Apps selected - no Exchange online license.
The mailbox still exists in Office 365 Exchange online
Mailbox does not exist on Exchange hybrid server on-premises
Solution: Steps to fix Office 365 not showing in Exchange admin center
1. Temporarily re-enable the mailbox
On Exchange hybrid server
Open Exchange Management Shell
Temporarily re-enable the mailbox for the user account
Enable-RemoteMailbox user@domain.com -RemoteRoutingAddress user@domain.mail.onmicrosoft.com
2. Run AD connect sync
On AD connect server
Run AD Sync
Start-ADSyncSyncCycle -PolicyType Delta
3. Temporarily re-assign Exchange online license
In Office 365 admin portal
https://portal.office.com
Temporarily re-assign an Exchange online license to the user account in Office 365
4. Remove holds on the mailbox
# Connect to Exchange online PowerShell Connect-EXOPSSession -UserPrincipalName admin@domain.com # Remove holds on the mailbox Set-Mailbox user@domain.com -SingleItemRecoveryEnabled $false Set-Mailbox user@domain.com -RetentionHoldEnabled $false Set-Mailbox user@domain.com -LitigationHoldEnabled $false
5. Remove Office 365 licenses
Remove all licenses from the user account in Office 365
6. Disable mailbox on Exchange hybrid
On Exchange hybrid server
Open Exchange Management Shell
Disable-Remotemailbox user@domain.com
7. Run AD sync again
On AD connect server
Run AD Sync
Start-ADSyncSyncCycle -PolicyType Delta
Re-assign an Office 365 E3 license (M365 apps only) to the user account
This problem was most likely caused by the user being under litigation hold and removing the Office 365 Exchange online license before running Disable-Remotemailbox on the Exchange hybrid server.
Running Disable-RemoteMailbox removes Exchange attributes from the AD user and removes the mailbox in Office 365.
Making changes enabling and disabling mailboxes without waiting for AD sync can also cause issues.
Comments