In the Exchange Management Shell (EMS), you use the New-MailboxRestoreRequest cmdlet to restore a PST file to a specific mailbox in a database. You can also use this cmdlet when restoring a soft-deleted mailbox from one Exchange mailbox store to another user in the same Exchange mailbox store or another one. It is to be noted that the command New-MailboxRestoreRequest will work if your Exchange mailbox database is live and accessible.
You will not be able to perform any restore if you have any issues with your Exchange mailbox database. This is where the Get-MailboxRestoreRequest command comes in handy. You can use this PowerShell command to get information on the restore requests. This will show all the requests on the mailbox, their status, and the number of restores done, thus helping in troubleshooting any issues with restoring or migrating the mailboxes. Let’s see how to use this command with different parameters.
How to Run the Get-MailboxRestoreRequest Cmdlet?
First, you need to make sure that you have the right permissions for running the command. You need to ensure that the following Role is assigned to the username you are using to run the command and its parameters.
When you run the command as given below, it will show all the restore requests.
Get-MailboxRestoreRequest
If you are running a lot of restores, your list will be quite long. To know the restore status of a specific user, you need to add the Identity parameter to the command (see the below example).
Get-MailboxRestoreRequest -Identity <first name>\MailboxRestore
Let’s say, you need to get the requests which are in progress and queued in a particular Exchange mailbox database. For this, you need to use the RequestQueue parameter in the command as given below.
Get-MailboxRestoreRequest -RequestQueue <database name>
If you like to have in return all the requests that have a particular name for the restore request, you can use the below command. If you also want the restores which are suspended, you need to add the suspend parameter at the end (see the below example).
Get-MailboxRestoreRequest -Name "RestoreToMBD01" -Suspend $true
If you have created a restore batch, you can use the BatchName parameter to specify the batch name to return the status of the restore requests by the specified batch.
If you need to return the restore requests which came from a specific database, you can use the SourceDatabase parameter at the end, along with the name of the database.
What if something goes wrong?
As said, the Get-MailboxRestoreRequest command is ideal to investigate and get more information in case something went wrong with the restore or other functionalities. It might happen that failed or completed restore request was still visible on the mailbox and you will be stopped from exporting the mailbox to PST or migrating to a new Exchange Server or mailbox database.
In addition, the restore request may fail due to issues with the Exchange Server, corrupt or missing transaction log or database, or any other issue. In such cases, intervention from a senior administrator is required to troubleshoot the issues.
Alternatively, you can easily skip the troubleshooting and the issue itself by using the applications, such as Stellar Repair for Exchange. This application allows you to open multiple mailbox databases and browse through them. You can open any database – be it healthy or in dirty shutdown state and then granularly export mailboxes and other data to PST and other file formats.
You can also use the application to export your mailboxes to a new Exchange Server mailbox database, a new Exchange Server, or even Microsoft 365 tenant. The application is not limited to user mailboxes but it can also process archive mailboxes, shared mailboxes, disabled mailboxes, and even public folders.
Was this article helpful?