In this example, we are going to connect/recover a mailbox that we deleted in the previous blog post. As an example, we created a new test user as shown below to connect to a mailbox.

To do this you can use PowerShell to create the user or use Active Directory Users and computers. Right click the OU where you want the user and choose new user. The window below will appear, enter in the relevant information and then click Next >..

Exchange 2010:- move requests with a bit more info using powershell

Now enter in the password for the user and click Next >.

Exchange 2010:- move requests with a bit more info using powershell

Confirm the information and then click the Finish button as shown below:

Exchange 2010:- move requests with a bit more info using powershell

Now head over to the Exchange Admin Center (EAC) and then click on Recipients -> Mailbox and then the 3 … and then you can click on “Connect a mailbox”:

Exchange 2010:- move requests with a bit more info using powershell

A new window will appear and you need to select a server next to “Server name” and then you can click the user listed as shown below and click the icon next to the refresh icon to re-connect it:

Exchange 2010:- move requests with a bit more info using powershell

Or you can use PowerShell and let it do the work for you as shown below, you can use the following command:

  • Connect-Mailbox “edward” -Database “DB Name” -User “Temp user created” -Alias aliasname
Exchange 2010:- move requests with a bit more info using powershell

To get the information regarding a mailbox like the GUID or LegacyDN, you need to run the following command:

  • Get-MailboxDatabase | Get-MailboxStatistics | Where {$_.DisconnectReason -eq “Disabled”} | Format-List DisplayName,MailboxGuid,LegacyDN,Database
Exchange 2010:- move requests with a bit more info using powershell

Now we can perform a restore request using the information from above, you can actually also view it in the EAC in a few previous steps, here is the command:

  • New-MailboxRestoreRequest -SourceStoreMailbox GUID -SourceDatabase DB01 -TargetMailbox “Temp user” -AllowLegacyDNMismatch
Exchange 2010:- move requests with a bit more info using powershell

As you can see above, the status starts Queued, now you can run the following command to find the progress:

  • Get-MailboxRestoreRequest | Get-MailboxRestoreRequestStatistics
Exchange 2010:- move requests with a bit more info using powershell

You can run the command above to monitor the status of the restore.

Hope it helps.

    wpChatIcon

    Discover more from Everything-PowerShell

    Subscribe now to keep reading and get access to the full archive.

    Continue reading