FixesOffice 365

Restore Inactive Mailbox – Office 365

Firstly you need to get the GUID:

Get-Mailbox -InactiveMailboxOnly | FL Name,DistinguishedName,ExchangeGuid,PrimarySmtpAddress

This command shows you all Inactive Mailboxes

Now you need to create a new Mailbox and attach the inactive mailbox to it:

$InactiveMailbox = Get-Mailbox -InactiveMailboxOnly -Identity b5b91f7c-6827-4f95-8a53-205fa47bc5ae
 New-Mailbox -InactiveMailbox $InactiveMailbox.DistinguishedName -Name Freya.YoungJ -FirstName Freya -LastName YoungJ -DisplayName "Freya YoungJ" -MicrosoftOnlineServicesID Freya.YoungJ@animatrixcapital.co.uk -Password (ConvertTo-SecureString -String 'Password12' -AsPlainText -Force) -ResetPasswordOnNextLogon $false

Now convert the mailbox to shared and you are done.