The term 'New-MailboxExportRequest' is not recognized

In this article, we will discuss the issue that why the New-MailboxExportRequest command doesn't work in Exchange Management PowerShell while the User has full access to the file path and is part of the Mailbox Import Export ManagementRoleAssignment.

Let's see how Exchange Mailbox export works and how we can solve "The term 'New-MailboxExportRequest' is not recognized" error.

How to Export a Mailbox in Exchange 2010 Using Exchange Management Shell

Step 1: Open Exchange Management Console.

Step 2: Run the following command to provide proper rights to import or export a mailbox:

New-ManagementRoleAssignment -Role "Mailbox Import Export" -User Administrator

Step 3: Create a shared folder and assign full rights to the "Exchange Trusted Subsystem" group.

Step 4: Now if you run the following command to export a mailbox, you will definitely get the error "The term 'New-MailboxExportRequest' is not recognized":

New-MailboxExportRequest -Mailbox "TestMailBox" -FilePath "\\Testex01\c$\get\TestExport01.pst"

The term 'New-MailboxExportRequest' is not recognized as the name of a cmdlet, function, script file, or operable program.

Solution

Step 5: Close Exchange Management Shell and open it again so the user will have the proper rights which we assigned in Step 2. Run the above command again:

New-MailboxExportRequest -Mailbox "TestMailBox" -FilePath "\\Testex01\c$\get\TestExport01.pst"

Step 6: You will see success and mailbox export started and is in the queue. You can see the status with:

Get-MailboxExportRequest

Export an Archive Mailbox

To export an archive mailbox in Exchange 2010, you can use the -IsArchive parameter. Below is the full command:

New-MailboxExportRequest -Mailbox "TestMailBox" -IsArchive -FilePath "\\Testex01\c$\get\TestExport01.pst"

Note: This will only export the archive mailbox, not the actual mailbox. You have to run both commands separately to export both.