How to Export Exchange 2016 Mailboxes to PST – PowerShell

Summary: In this guide, you will learn to export Exchange 2016 mailboxes to PST from the online Exchange database (EDB) using the PowerShell commands in Exchange Management Shell (EMS) and Exchange Admin Center (EAC). We have also mentioned an advanced method to convert Exchange mailboxes from both online and offline Exchange database (EDB) files to PST format with an option to directly export the mailboxes to a Live Exchange server or Office 365 account.

PST or Personal Storage Table, also known as ‘Personal Folder’, is an Outlook data file widely supported and easily imported to any Outlook account, Office 365 mailbox, or Live Exchange Server. This makes exporting Exchange 2016 mailboxes to PST an ideal backup option.

Besides backup, PST also helps in the seamless migration of mailboxes from one user to another.

Methods to Export Exchange 2016 Mailboxes to PST

To export Exchange 2016 mailboxes to PST, you can use the New-MailboxExportRequest PowerShell cmdlet in Exchange Management Shell. However, it can export Exchange 2016 mailboxes to PST from an online or hosted Exchange database only.

Besides, you can’t see any export progress as it’s a command-line interface. Thus, you won’t know if the export request you created has exported the PST successfully or not. On the other hand, Exchange Admin Center (EAC) provides a graphical user interface without any filter option. Also, you can export one mailbox at a time.  

Stellar Converter for EDB software features a graphical user interface, which makes it easy to export PST from EDB files. The software extracts and saves all mailboxes from online and offline EDBs to PST format at your desired location in a few clicks. You can download the demo version for free and try it yourself. The software can also export the mailboxes directly to Office 365 or Live Exchange Server.

Below we have discussed these methods in detail to help you export Exchange 2016 mailboxes to PST with complete integrity and precision.

Steps to Export Exchange 2016 Mailboxes to PST using PowerShell Cmdlets

Using the New-MailboxExportRequest cmdlet, you can manually create a mailbox export request to export either single or multiple mailboxes simultaneously. You can also add filters to the mailbox export request.

However, this option is available only in on-premises Exchange Server 2016. Also, to execute the New-MailboxExportRequest cmdlet, the user should be assigned the Mailbox Import Export role. This role is not assigned to any user by default, including the administrator.

You must also create a UNC path to save the exported PST file.

Step 1: Assign Mailbox Import Export Role

To assign the Mailbox Import Export role to a user, open Exchange Management Shell (EMS) and enter the following command as an administrator,

New-Managementroleassignment –Role “Mailbox Import Export” –User “UserName”

To check if the Mailbox Import Export role is assigned successfully, enter the following command in the EMS window,

Get-ManagementRoleAssignment -Role “Mailbox Import Export” | Format-List RoleAssigneeName

Once the role is assigned successfully, you can execute the New-MailboxExportRequest cmdlet to export Exchange 2016 mailboxes to PST files.

Step 2: Create UNC Folder Path

To create a UNC folder path for saving the exported Exchange 2016 mailboxes to PST files, follow these steps:

  • Create a folder on your Exchange Server.
  • Right-click on the folder and choose to Give access to> Specific People…
  • Choose your username or Everyone from the dropdown and click Add.
  • Choose Read/Write permission or Owner for the folder access and click Share.
  • Copy the shared network path. In this case, it’s \\EXCHANGE19\UNCPathFolder.

This is the shared folder path location we will use to export and save the exported mailboxes as PST files.

PowerShell Commands to Export Exchange 2016 Mailbox to Outlook PST

Below are the commands to backup Exchange mailboxes to PST based on various scenarios. You can also create multiple export requests at once. However, each mailbox export request should have a unique name. Follow the one that meets your backup needs.

NOTE: By default, Microsoft generates ten unique names, and thus, you can create up to ten export requests without providing a unique name. If you need to request more than ten mailbox export requests, you must create a unique name while requesting mailbox export.

EXPORT EXCHANGE 2016 MAILBOX TO PST IN A SHARED FOLDER

You can export a user’s primary mailbox data to a PST file and store it on an Exchange Server’s shared folder. If a shared folder doesn’t exist, create one using the Exchange Admin Center (EAC). Also, ensure read/write permissions. Then execute the following command,

New-MailboxExportRequest -Mailbox Thomson -FilePath “\\SERVER22\MyNetworkPST\Thomson_Recovered.pst”

Thomson is the primary mailbox user. MyNetworkPST is a network shared folder (UNC path) on the Exchange server named SERVER22.

You can export a user’s primary mailbox data to a PST file and store it on an Exchange Server’s shared folder. If a shared folder doesn’t exist, create one using the Exchange Admin Center (EAC). Also, ensure read/write permissions. Then execute the following command,

New-MailboxExportRequest -Mailbox Thomson -FilePath “\\SERVER22\MyNetworkPST\Thomson_Recovered.pst”

Thomson is the primary mailbox user. MyNetworkPST is a network shared folder (UNC path) on the Exchange server named SERVER22.

EXPORT THE USER’S ARCHIVE TO PST

To export a user’s archive to PST in Exchange 2016, enter the following command in the EMS.

New-MailboxExportRequest -Mailbox Thomson -FilePath “\\SERVER22\MyNetworkPST\Thomson_Archive.pst” –IsArchive

This command exports Thomson’s archive to the PST file on the MyNetworkPST network shared folder located on Exchange Server SERVER22.

EXPORT EXCHANGE MAILBOX TO PST BY APPLYING FILTER

If you want to export and backup only certain mailbox items to PST, you can use filters while creating a mailbox export request. By adding –The contentFilter parameter in the New-MailboxExportRequest cmdlet, you can export mailbox messages based on date, keyword matches, etc.

In the following example, ‘target‘ and ‘sales‘ are the keywords we look for in the body of the message for the Thomson user mailbox received before May 2, 2015.

New-MailboxExportRequest -Mailbox Thomson -ContentFilter {(body -like “*target*”) -and (body -like “*sales*”) -and (Received -lt “02/05/2015”)} -FilePath \\SERVER22\MyNetworkPST\Thomson_MyCompanyReports.pst

EXPORT ALL MAILBOX ITEMS ON EXCHANGE 2016 TO PST

Finally, if you wish to export all mailbox items from a mailbox on Exchange 2016, enter the following command in the Exchange Management Shell (EMS).

New-MailboxExportRequest -Mailbox Thomson -IncludeFolders “#Inbox#” -FilePath \\SERVER22\MyNetworkPST\Thomson\ThomsonData.pst

The command exports all the Thomson mailbox messages and folders to the PST file ThomsonData.pst.

EXPORT ALL MAILBOXES TO THE CORRESPONDING PST

If you want to back up all the mailboxes in your organization that reside on the Exchange 2016 server, use these commands in EMS.

Get-Mailbox

The above command lists all the mailboxes in your organization. Then type following command,

foreach ($Mailbox in (Get-Mailbox)) { New-MailboxExportRequest -Mailbox $Mailbox -FilePath \\SERVER22\MyNetworkPST\Thomson\$($Mailbox.Alias).pst”}

This exports all mailboxes to corresponding PST files at the entered location.

Check Mailbox ExportStatus

To check the detailed status of ongoing export and requests, enter the following command in the EMS,

Get-MailboxExportRequestStatistics

You can also remove the current mailbox export request by executing Remove-MailboxExportRequest cmdlet before starting a new export request with the default request name.

CONCLUSION

Though the New-MailboxExportRequest cmdlet does the job, there are chances of missing mail items or failure and PST file corruption during and after export. That’s because large PST files are prone to damage due to integrity issues. However, corruption may also occur due to a network issue. Plus, you can’t see the actual progress and estimate a timeline for export. It may take several hours or days to finish the mailbox export request, which leaves you vulnerable.

Also, you can add filters but can’t preview the mailbox items before exporting them to PST. You can only preview it in Outlook only after export. And if something is missing, you will have to execute the entire process again by changing the filters.

To ease up the Exchange 2016 to PST backup process and avoid PST corruption or data loss, you can export the Exchange mailboxes to corresponding PST files at a granular level using an EDB converter software. The GUI-based software can extract, preview, and export mailboxes and all mail items from offline or online Exchange 2016 databases to PST without dismounting. Thus, you can expect no downtime. Also, there’s no file size limitation, and you can use a filter to export single, multiple, or certain mail items or mailboxes at up to 4x faster speeds with Parallel Processing. Further, you can also export mailboxes from offline EDB to a Live Exchange server or Office 365 and other file formats such as EML, MSG, RTF, PDF, and HTML.

To avoid all the hassle, it’s highly recommended that you try Stellar Converter for EDB software.

3 Comments

  1. Brandon June 10, 2016
  2. Paco August 22, 2017
    • Admin August 25, 2017

Leave a Reply

Your email address will not be published. Required fields are marked *