Show pageOld revisionsBacklinksExport to PDFBack to top This page is read only. You can view the source, but not change it. Ask your administrator if you think this is wrong. ====== Export/Import users mailbox into PST file using PowerShell ====== Grant admin user the privilege to import/expoer mailboxes <code bash| Add role>New-ManagementRoleAssignment -Role "Mailbox Import Export" -User Administrator</code> Create a network share with **Exchange Trusted Subsystem** group r/w permissions Check the mailbox size: <code powershell| Get mailbox size>get-mailboxstatistics username | format-table displayname,TotalItem*</code> Export mailbox to PST, and see the export status <code powershell| Export mailbox to PST> New-MailboxExportRequest -Mailbox username -FilePath \\server\share\file.pst Get-MailboxExportRequest Get-MailboxExportRequest -Name MailboxExport | fl Get-MailboxExportRequest | Get-MailboxExportRequestStatistics Get-MailboxExportRequest | where {$_.status -eq "Completed"} Get-MailboxExportRequest | where {$_.status -eq "Completed"} | Remove-MailboxExportRequest </code> Import PST into the new mailbox - first line imports into root, the second line creates a folder and imports into that folder <code powershell| Import PST into mailbox> New-MailboxImportRequest -FilePath \\server\share\file.pst -Mailbox uname New-MailboxImportRequest -FilePath \\server\share\file.pst -Mailbox uname -TargetRootFolder "Old data" Get-MailboxImportRequest Get-MailboxImportRequest | Get-MailboxImportRequestStatistics Get-MailboxImportRequest | where {$_.status -eq "Completed"} | Remove-MailboxImportRequest </code> Export all mailboxes <code powershell| export all mailboxes> foreach ($Mailbox in (Get-Mailbox)) { New-MailboxExportRequest -Mailbox $Mailbox -FilePath "\\<server FQDN>\<shared folder name>\$($Mailbox.Alias).pst" } </code> Suspend and resume export request <code powershell> Suspend-MailboxExportRequest -Identity "Ayla\MailboxExport" Resume-MailboxExportRequest -Identity kweku\export </code> windows/servers/exchange/export_mailbox.txt Last modified: 2019/10/31 09:14by 127.0.0.1