Importing and exporting PST files is a common task for many Microsoft Exchange Server administrators. This can be done via Outlook, PowerShell and in some cases also via Exchange Management Console. This guide will cover the basic usage of the New-MailboxImportRequest
cmdlet to create mailbox import requests, as well as the viewing and clean-up of existing import requests in Microsoft Exchange 2010, 2013, 2016 and 2019.
See Exporting PST Files in Exchange Server 2010, 2013, 2016 and 2019 to learn about exporting.
Requirements
- The user performing the export must be a member of a role group which has the
Mailbox Import Export
role added. The easiest way of achieving this is running this script in PowerShell or the Exchange Management Shell:
New-ManagementRoleAssignment -Role "Mailbox Import Export" -User "<user name or alias>"
- The location to which you will export the PST file must be a shared folder on the local network (accessable by a UNC path).
New Mailbox Import Request
New-MailboxImportRequest -Mailbox <user> -FilePath \\<server FQDN>\<shared folder name>\<PST name>.pst
See New-MailboxImportRequest – Microsoft Docs for full specifications on the usage of the cmdlet.
Manage & Clean Up Import Requests
List All Import Requests
Get-MailboxImportRequest
List All Import Requests With Statistics
Get-MailboxImportRequest | Get-MailboxImportRequestStatistics
Log Failures to Text File
Get-MailboxImportRequest -Status Failed | Get-MailboxImportRequestStatistics -IncludeReport | Format-List > MailboxImportRequestFailures.txt
Remove Completed Import Requests
Get-MailboxImportRequest -Status Completed | Remove-MailboxImportRequest
This guide has covered the basics of importing PST files into Microsoft Exchange 2010, 2013, 2016 and 2019. See Exporting PST Files in Exchange Server 2010, 2013, 2016 and 2019 to learn about exporting.
Excepting Requirements command … to any of other commands I got the following error: How to fix it this missing Commands ?
New-MailboxImportRequest : The term ‘New-MailboxImportRequest’ is not recognized as the name of a cmdlet, function,
script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is
correct and try again.
At line:1 char:1
+ New-MailboxImportRequest
+ ~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : ObjectNotFound: (New-MailboxImportRequest:String) [], CommandNotFoundException
+ FullyQualifiedErrorId : CommandNotFoundException
Which version of Exchange Server are you running here? Make sure you’re trying to run the commands in Exchange Management Shell, not just standard Windows PowerShell.