#office 365 exchange online dual mailbox

1.  put mailbox in hold

Set-Mailbox username -LitigationHoldEnabled $true

Get-Mailbox username |fl *lit*

2. get mailbox guid and object id

Get-Mailbox username |fl userprincipalname,guid

Get-MsolUser -UserPrincipalName [email protected] |fl

3. remove mailbox/user

Remove-MsolUser -ObjectId e2e7b9db-df8f-45a1-b9b8-910625b3f32d

Remove-MsolUser -ObjectId e2e7b9db-df8f-45a1-b9b8-910625b3f32d -RemoveFromRecycleBin

get-msoluser -ObjectId -ReturnDeletedUsers

Wait for AD Sync, re-create account in 365…

Migrate the mailbox from exchange to online again.

4. get mailbox guid (new)

Get-Mailbox username | fl name,GUID

5. restore/merge

New-mailboxrestoreRequest -sourcemailbox [Guid of old mailbox] -targetmailbox [GUID of new mailbox] -allowLegacyDNMismatch

Get-mailboxrestorerequest