Using the Exchange 2010 Mailbox Export features for Mass Exports to PST files

In Exchange 2007 SP1 thru to Exchange 2010 RTM, the Export-Mailbox command was the replacement for the once-familiar ExMerge utility when it came to exporting mailboxes to PST files.

The main problem with Export-Mailbox for most Exchange administrators is the requirement for Outlook – either on a 32-bit machine with Management Tools for Exchange 2007, or on a 64-bit machine for Exchange 2010. All in all, it wasn’t ideal and certainly didn’t facilitate scripted mailbox exports.

Thankfully, with Exchange 2010 SP1, SP2 and SP3, Export-Mailbox is going the way of the dodo and new cmdlets for Mailbox imports and exports are available. Just like the New-MoveRequest cmdlet, the new import/export command use the Mailbox Replication Service to perform the move via one of the Client Access Servers giving performance benefits, such as ensuring the PST transfer doesn’t have to go via the machine with the Exchange Management Tools/Outlook installed, as was the case previously.

The main aim of this post is to give you an overview of how to use the new mailbox export cmdlets, and then show you how to put them to practical use, both at the command line and with a scheduled task for brick-level backups.

Getting it set up

The basic requirements for using the new feature are pretty straightforward. You need to use an account that’s a member of the organisational management groups, and have the “Mailbox Import Export” role assignment assigned to you or a role group you’re a member of. As the export is done at a CAS server (and if you’ve multiple CAS servers you can’t specify which one in each site will be used) you can’t specify a local drive letter and path – you must specify a UNC path to a network share that the “Exchange Trusted Subsystem” group has read/write access to.

Step One

Create a share on a server, and grant Exchange Trusted Subsystem read/write permission. In this example I’m using a share called Exports on a test server called Azua in my lab environment:


Step Two

Next, you’ll need to grant a user, or group, the Mailbox Import Export role assignment. You can do this using the Exchange Management shell with a single command. In this example, I’m granting my lab domain’s Administrator user the role assignment:


New-ManagementRoleAssignment –Role “Mailbox Import Export” –User AD\Administrator

After you’ve done this, close and re-open the Exchange Management shell, and you’re ready to go!

Exporting a Mailbox

At it’s simplest, use the New-MailboxExportRequest command with the –Mailbox parameter, to specify the mailbox to export along with the –FilePath parameter, to specify the PST file to create and export data to, e.g:

New-MailboxExportRequest -Mailbox Administrator -FilePath "\\AZUA\Exports\Administrator.pst"

In addition, there are some other useful options – such as –BatchName, which allows grouping of requests together, and –ContentFilter, which allows only certain content to be exported to the PST – useful for discovery purposes.  As usual, use the Get-Help New-MailboxExportRequest –detailed command to review the full plethora of options.

After submission of your requests, you can check progress, including the percentage complete, with the two Get-MailboxExportRequest and the Get-MailboxExportRequestStatistics commands. Pipe the former into the latter to get a listing:


Get-MailboxExportRequest | Get-MailboxExportRequestStatistics

After the requests complete, you can remove the requests in a similar fashion, using the Remove-MailboxExportRequest command:


Get-MailboxExportRequest | Remove-MailboxExportRequest
Performing mass exports

One benefit of Powershell is it’s very easy to put together commands enabling mass-exports of PST data with only a few commands. If you really wanted to, you could even use a Powershell script as a secondary brick-level backup!

The Basics

So to check out how to do this, let’s look at it’s simplest – backing up all the mailboxes (assuming it’s a full Exchange 2010 environment) to a single share:


foreach ($i in (Get-Mailbox)) { New-MailboxExportRequest -Mailbox $i -FilePath "\\AZUA\Exports\$($i.Alias).pst" }

In the above example, we’re simply performing a for-each loop through each mailbox and creating a new Mailbox Export Request, using the alias to build the name for the PST.

But – what if we’re in a mixed environment, and only want to target the Exchange 2010 mailboxes?


foreach ($i in (Get-Mailbox | Where {$_.ExchangeVersion.ExchangeBuild.Major -eq 14})) { New-MailboxExportRequest -Mailbox $i -FilePath "\\AZUA\Exports\${$i.Alias).pst" }

In this example above, now, we’ve added a clause to only select the mailboxes where the Exchange Major Build is 14 – Exchange 2010. Simple!

Moving on from such wide-targeting, you may want to target just a pre-defined list, using a CSV file. To do this, simply create a CSV file with the column “Alias”, and list the Mailbox alias fields you wish to export. Then, using the Import-CSV command we can use this CSV file to create the requests:


foreach ($i in (Import-Csv .\exports.csv)) { New-MailboxExportRequest -Mailbox $i.Alias -FilePath "\\AZUA\Exports\$($i.Alias).pst" }
Performing Mass Exports as a scheduled task

Now you’ve seen the basics of how easy it is to perform mass mailbox exports using the New-MailboxExportRequest command, I’ll finish off with a final example showing how to use this mass export feature as part of a scheduled task.

This script is aimed at backing up all the mailboxes on a single database, or a single server. After creating the requests, it waits for the requests to complete then, if you’ve specified a report directory, it will write reports showing completed and incomplete (i.e. failed!) requests. Finally it removes the requests it created.

To use the script, you need to alter the config section and specify either a server or a database, a share to export to, a share to write a report to after the process has completed and you can choose whether to remove each mailbox’s associated PST file or leave as-is at each export – merging the contents.

You’ll see the content of the script below and at the bottom of the post I’ve zipped it up along with a bootstrap CMD file you could use when setting up a schedule task. As always – use at your own risk and test out in your lab environment first. Happy Exporting!

# Exchange 2010 SP1 Mailbox Export Script
# Steve Goodman. Use at your own risk!

# Settings #

# Pick ONE of the two below. If you choose both, it will use $Server.
$Server = “server”
$Database = “”

# Share to export mailboxes to. Needs R/W by Exchange Trusted Subsystem
# Must be a UNC path as this is run by the CAS MRS service.
$ExportShare = “\\server\share”

# After each run a report of the exports can be dropped into the directory specified below. (The user that runs this script needs access to this share)
# Must be a UNC path or the full path of a local directory.
$ReportShare = “\\server\share”

# Shall we remove the PST file, if it exists beforehand? (The user that runs this script needs access to the $ExportShare share)
# Valid values: $true or $false
$RemovePSTBeforeExport = $false

# Code #

if ($Server)
if (!(Get-ExchangeServer $Server -ErrorAction SilentlyContinue))
throw “Exchange Server $Server not found”;
if (!(Get-MailboxDatabase -Server $Server -ErrorAction SilentlyContinue))
throw “Exchange Server $Server does not have mailbox databases”;
$Mailboxes = Get-Mailbox -Server $Server -ResultSize Unlimited
} elseif ($Database) {
if (!(Get-MailboxDatabase $Database -ErrorAction SilentlyContinue))
throw “Mailbox database $Database not found”
$Mailboxes = Get-Mailbox -Database $Database
if (!$Mailboxes)
throw “No mailboxes found on $Server”

if (!$Mailboxes.Count)
throw “This script does not support a single mailbox export.”

# Pre-checks done

# Make batch name
$BatchName = “Export_$($date.Year)-$($date.Month)-$($date.Day)_$($date.Hour)-$($date.Minute)-$($date.Second)”

Write-Output “Queuing $($Mailboxes.Count) mailboxes as batch ‘$($BatchName)'”

# Queue all mailbox export requests
foreach ($Mailbox in $Mailboxes)

if ($RemovePSTBeforeExport -eq $true -and (Get-Item “$($ExportShare)\$($Mailbox.Alias).PST” -ErrorAction SilentlyContinue))
Remove-Item “$($ExportShare)\$($Mailbox.Alias).PST” -Confirm:$false
New-MailboxExportRequest -BatchName $BatchName -Mailbox $Mailbox.Alias -FilePath “$($ExportShare)\$($Mailbox.Alias).PST”

Write-Output “Waiting for batch to complete”

# Wait for mailbox export requests to complete
while ((Get-MailboxExportRequest -BatchName $BatchName | Where {$_.Status -eq “Queued” -or $_.Status -eq “InProgress”}))

sleep 60

# Write reports if required
if ($ReportShare)
Write-Output “Writing reports to $($ReportShare)”
$Completed = Get-MailboxExportRequest -BatchName $BatchName | Where {$_.Status -eq “Completed”} | Get-MailboxExportRequestStatistics | Format-List
if ($Completed)
$Completed | Out-File -FilePath “$($ReportShare)\$($BatchName)_Completed.txt”
$Incomplete = Get-MailboxExportRequest -BatchName $BatchName | Where {$_.Status -ne “Completed”} | Get-MailboxExportRequestStatistics | Format-List
if ($Incomplete)
$Incomplete | Out-File -FilePath “$($ReportShare)\$($BatchName)_Incomplete_Report.txt”

# Remove Requests
Write-Output “Removing requests created as part of batch ‘$($BatchName)'”
Get-MailboxExportRequest -BatchName $BatchName | Remove-MailboxExportRequest -Confirm:$false

Command file contents:

C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe -command ". 'c:\Program Files\Microsoft\Exchange Server\V14\bin\RemoteExchange.ps1'; Connect-ExchangeServer -auto; .\MassExport.ps1"

Download as ZIP

292 thoughts on “Using the Exchange 2010 Mailbox Export features for Mass Exports to PST files

  1. Always loved this script, thought i had asked here before but cant find it.How can i make it so it tags the date on the PST

    2014-07-04-Alias.pst ?

    I have tried a few things using $date but cant get anything to work.

  2. I’ve been tasked to export the dumpster items for all my users, is there a way to specify a target database while using the -Dumpsteronly command?

  3. I love this script. I have modified it to include a module that removes lync accounts and a module that removes users from their AD groups thus turning it into a true powerhouse script for terminations.

    I have not been successful however in passing the get-mailboxexportrequest -status complete to the disable-mailbox command.

    When I try it the simple way: get-mailboxexportrequest -status completed | disable-mailbox it returns errors that it can’t find the mailbox on the DC because it is using the display name lastname, firstname (I think). I have tried it a couple other ways but haven’t been able to figure out the correct syntax to pass the $mailbox.mail identity parameter to the disable command for the completed requests.

    Can you give me some insight here? Still very new to powershell.

  4. Pingback: EDB to PST in exchange 2010 and 2013 | Welcome to my personal Web Site

  5. Hello, Thank you for this script. The exports did work for some time. But now I receive two logs. One with completed exports and one with incomplete exports. How can I find out why some mailboxes cannot be exported (or partially) suddenly ?

    Thank you in advance.

  6. You mention that if you leave the PST files the next time it will merge the contents and on the report it has an entry for SyncStage: SyncFinished. So New-MailboxExportRequest does a incremental if you leave the PST files?

  7. Pingback: C7 Solutions | Merge Exchange 2010 Personal Archive Back to Primary Mailbox

  8. Thanks for the useful information about Exmerge.exe utility, a free utility designed by Microsoft to export mailboxes to PSTs. But due to the limited features, it sometimes fails to complete the task successfully. If mailboxes has some corrupted items, this utility does not work and escape the items. However, there are some third party EDB to PST conversion tools exist on the web, like this:

    This program offers complete, safe and accurate conversion of Exchange mailboxes to PST files. One of the best features of this tool that I liked is it allows batch mailboxes conversion i.e. we can easily export multiple mailboxes into corresponding PST files at a time. A free trial version is also available of the product.

    Curtis Hollister

  9. foreach ($i in (Import-Csv .\exports.csv)) { New-MailboxExportRequest -Mailbox $i.Alias -FilePath \\EXG01\ExportPST\$($i.Alias).pst” }

    Go into second line >> ?

    create the exports.csv


    But No out put?

  10. Everytime I use foreach ($i in (Import-Csv .\exports.csv)) { New-MailboxExportRequest -Mailbox $i.Alias -FilePath “\\AZUA\Exports\$($i.Alias).pst” } I get and error saying ‘Parameter values of type Microsoft.Exchange.Configuration.Tasks.MailboxOrMialUserIDParameter can’t be empty.
    It does run and exports the mailbox but it creats a file like this @{UserName}.Alias.pst


  11. Pingback: FAQ » Using the Exchange 2010 SP1 and SP2 Mailbox Export features for Mass Exports to PST files

  12. This looks like it will help me with what I need. Can it be adapted to use a foreach with an imported .csv file and how would you do that?

  13. Many Thanks … great Tutorial

    Please update the script with the online archive -isArchive.
    Would be nice to have the possibility to safe it too.

    • Just add -isArchive at the end of New-MailboxExportRequest -BatchName $BatchName -Mailbox $Mailbox.Alias -FilePath “$($ExportShare)\$($Mailbox.Alias).PST”

  14. Working great, anyone seen the problem when running the new-mailboxexportrequest cmd the second time it fails on openening PST file larger then 1 gb with the error Header file length is zero.
    Great helpfull page btw.

  15. Hello Steve, I’m currently working on a bulk script for hosted exchange. Is there a posibility to use the users mail address instead of the Exchange alias for the PST filename? Almost every organisation has an office mail address.

  16. Might be a silly question, but how do you specify a database? Ive got a revoery database mounted alrady, with the emails in it. I guess Get-MailBoxDatabase somehow?

  17. Steve – does having $RemovePSTBeforeExport set to false mean that the script will simply merge new data into an existing PST?

  18. Great Script i am having one strange issue though, when i run the batch file i get an error stating that the term ‘.\massexport.ps1’ is not recognized as the name of a cmdlet, i believe i have set the ps1 file correctly by putting in the correct logging path and server name ect. it just seems that it doesnt want to run the PS1 file. I am in a administrator account and i have granted the administrator role assignment of exchange management shell.

    I must admit this is my first experience with exchange management shell so i do apologise if i am missing a basic step.

  19. Pingback: Exchange 2010 SP1/SP2 – Export mailbox to PST | timdotexe

  20. Hello,

    Great script, thanks a lot.


    The single line “foreach ($i in (Get-Mailbox)) { New-MailboxExportRequest -Mailbox $i -FilePath “\\AZUA\Exports\$($i.Alias).pst” }” works fine.

    But the whole script “MassExport” does not generate any output…
    It just start the PS, and write the line “.\MassExport.ps1” then… nothing.

    Could you please help ?

    Thanks in advance.

  21. Hy, thanks for your tips running very fine on sbs2011. But i can’t run it as scheduled task ! The task starts at the right hour but few hours later, still running but nothing exported ! I tried with maximum rights but no effects ! The time for complete execution takes about 1 hour.
    Any idea ?

  22. Pingback: Exporting mailboxes to PST-files the easy way | ConsultingExperts

  23. Good explanation in simple way. Thanks for sharing. Recently we exported more than 5000 exchange mailboxes into outlook .pst files with the help of a third party edb to pst converter as given here:

    The software is really very easy to use and perform quick and complete conversion of mailboxes to PST files.

  24. Thanks for the good description. it was the first usefull description I’ve found, that realy works!!!!!!!

  25. How can I configure BadItemLimit into this script? Have 200+ Mailboxes to export and a lot of them have bad mail!

  26. The error should have read

    There are no available servers running the Microsoft Exchange Mailbox Replication service

  27. I have follwed your article and all has been running well. However, now I get the following error message

    There are no available servers running the Microsoft There are no available servers running the Microsoft

    Both Microsft Exchange Repliaction and Net.TCP Port Sharing services are started. Permissions are set correctly on the share.

    I have also run the method manually for one mailbox with same error message

    Any thoughts?

  28. Exchange Export script not an incremental export like exmerge, it will take more time to export mail box. i used to take backup though exmerg in exchange 2003,i used to take weekely full backup and daily incremental backup. it was good tool for me but export scrpit not good one. please advise can be do same with any other tool please help me

  29. This is a great write up. Unfortunately it was a horrible decision on MS. Was having outlook installed a pain, YES.

    Though i could do SO MUCH more with Export-Mailbox than the new crap-tastic New-MailboxExportRequest.

    On occasion we have been directed by our security team to remove 1 EMAIL from everyone’s mailbox that made it past our spam and anti-virus protection.

    I could easily delete 1 message from a mailbox by Subject string and DELETE.

  30. Pingback: Exchange 2010 SP1/SP2 – Export mailbox to PST without contacts | timdotexe

  31. Pingback: Exchange 2010 SP1/SP2 – Export mailbox to PST | timdotexe

  32. From what you say its actually possible to export mailboxes that reside in another server? even if its an Exchange 2003 server (in the same org?). that would be very helpful. Also is there a size limit like there was in the old utility EXEMERGE?

        • Nevermind, I reread what you typed…You weren’t stating that ExMerge could support large psts, but that the newer export functionality in Exchange 2010 does…

          My bad.

  33. This was the best! Thanks very much for the help with mass exports, I liked the old exmerge to pst file nightly as a good practice but it seemed trickey under 2k10 SP2 til now.

  34. Thanks for sharing some great tips, thanks for sharing and making it simple enough for anyone to be able to understand!
    It will help me write my Custom writing service

  35. Thanks for sharing some great tips, thanks for sharing and making it simple enough for anyone to be able to grasp!
    It will help me write my Custom writing service

  36. Hi Steve,

    your skript Is perfect,

    but I’ve a little problem with an export on filter :
    New-MailboxExportRequest -Mailbox archiv-gesamt-mail -Contentfilter {(Received -lt “01/08/2012”) -and (Received -gt ’01/01/2011′) -and (To -eq ‘*mustermann*’)} -FilePath \\srv-it-01\edv\mustermann.pst
    I get an empty pst.
    I opened an discusion on technet:

    Maybe you have some tips ?

  37. Can’t thank you enough for this great script. I’m using it in SBS 2011 as part of a backup/disaster recovery strategy. This is a great replacement for exmerge!

    I’m kind of a powershell beginner and I wasn’t exactly sure where to put your two script files, so I put them in a separate folder I use for my scripts. As long as MassExport.cmd and MassExport.ps1 both reside in the same folder it worked from an Administrator Command Prompt right out of the box. But I had trouble getting it to run as a scheduled task – even with “Run with highest privileges checked”, and “Run whether user is logged on or not” selected. For me the solution turned out to be quite simple; I just needed to add the path to my script folder in the “Start in (optional)” field on the Scheduled Tasks Actions tab.

    Keep up the great work, Steve!

  38. Thanks for the auspicious writeup. It in fact used to be a entertainment account it.
    Glance advanced to far added agreeable from you!

    However, how could we communicate?

  39. Hi Steve

    the script works like a charm for all my DBs except one containing 200 big mailboxes, I get the following errors for every single one of them, I don’t have a CAS array

    [PS] C:\Windows\system32>New-MailboxExportRequest -Mailbox AzzurriBilling -FilePath “\\azz-email03\f$\pst\AzzurriBilling
    .pst” -verb
    VERBOSE: [07:26:40.603 GMT] New-MailboxExportRequest : Active Directory session settings for ‘New-MailboxExportRequest’
    are: View Entire Forest: ‘False’, Default Scope: ‘azzurri.local’, Configuration Domain Controller:
    ‘WE-DC02.azzurri.local’, Preferred Global Catalog: ‘WE-DC02.azzurri.local’, Preferred Domain Controllers: ‘{
    WE-DC02.azzurri.local }’
    VERBOSE: [07:26:40.603 GMT] New-MailboxExportRequest : Runspace context: Executing user:
    azzurri.local/Azzurri/Users/IT/Marco Basso, Executing user organization: , Current organization: , RBAC-enabled:
    VERBOSE: [07:26:40.603 GMT] New-MailboxExportRequest : Beginning processing &
    VERBOSE: [07:26:40.603 GMT] New-MailboxExportRequest : Instantiating handler with index 0 for cmdlet extension agent
    “Admin Audit Log Agent”.
    VERBOSE: [07:26:40.619 GMT] New-MailboxExportRequest : Current ScopeSet is: { Recipient Read Scope: {{, }}, Recipient
    Write Scopes: {{, }}, Configuration Read Scope: {{, }}, Configuration Write Scope(s): {{, }, }, Exclusive Recipient
    Scope(s): {}, Exclusive Configuration Scope(s): {} }
    VERBOSE: [07:26:40.619 GMT] New-MailboxExportRequest : Searching objects “AzzurriBilling” of type “ADUser” under the
    root “$null”.
    VERBOSE: [07:26:40.619 GMT] New-MailboxExportRequest : Previous operation run on domain controller
    VERBOSE: [07:26:40.634 GMT] New-MailboxExportRequest : Searching objects “DB01_Service” of type “MailboxDatabase” under
    the root “$null”.
    VERBOSE: [07:26:40.634 GMT] New-MailboxExportRequest : Previous operation run on domain controller
    VERBOSE: [07:26:40.650 GMT] New-MailboxExportRequest : [DEBUG] MDB a22c425c-8598-4fa5-ac61-318a7f0a4de1 found to belong
    to Site: azzurri.local/Configuration/Sites/Weybridge
    VERBOSE: [07:26:40.665 GMT] New-MailboxExportRequest : [DEBUG] MRSClient: attempting to connect to
    VERBOSE: [07:26:41.882 GMT] New-MailboxExportRequest : [DEBUG] MRSClient: connected to ‘AZZ-EMAIL01.azzurri.local’,
    version caps:07
    VERBOSE: [07:26:41.882 GMT] New-MailboxExportRequest : Processing object “RequestGuid
    (01f56db0-93e0-4505-9bdb-312e98aee7b6), RequestQueue: (a22c425c-8598-4fa5-ac61-318a7f0a4de1)”.
    VERBOSE: [07:26:42.272 GMT] New-MailboxExportRequest : Couldn’t connect to the source mailbox. –>
    MapiExceptionUnknownUser: Unable to make connection to the server. (hr=0x80004005, ec=1003)
    Diagnostic context:
    Lid: 59431 EMSMDB.EcDoConnectEx called [length=121]
    Lid: 34855 EMSMDB.EcDoConnectEx returned [ec=0x3EB][length=56][latency=31]
    Lid: 59505 StoreEc: 0x3EB
    Lid: 52465 StoreEc: 0x3EB
    Lid: 60065
    Lid: 33777 StoreEc: 0x3EB
    Lid: 59805
    Lid: 52209 StoreEc: 0x3EB
    Lid: 56583
    Lid: 52487 StoreEc: 0x3EB
    Lid: 19778
    Lid: 27970 StoreEc: 0x3EB
    Lid: 17730
    Lid: 25922 StoreEc: 0x3EB
    VERBOSE: [07:26:42.272 GMT] New-MailboxExportRequest : Admin Audit Log: Entered Handler:OnComplete.
    Couldn’t connect to the source mailbox.
    + CategoryInfo : NotSpecified: (0:Int32) [New-MailboxExportRequest], RemotePermanentException
    + FullyQualifiedErrorId : E120321A,Microsoft.Exchange.Management.RecipientTasks.NewMailboxExportRequest

    VERBOSE: [07:26:42.272 GMT] New-MailboxExportRequest : Ending processing &
    [PS] C:\Windows\system32>

    it worked just fine for all other DBs, any ideas?

  40. Hey Steve, I had your script running beautifully until a couple weeks ago. Now I get the following error:

    Failed to communicate with the mailbox database.
    + CategoryInfo : ResourceUnavailable: (0:Int32) [New-MailboxExportRequest], QuotaExceededException
    + FullyQualifiedErrorId : 3A738D45,Microsoft.Exchange.Management.RecipientTasks.NewMailboxExportRequest

    I’m thinking that an exchange or windows update may have killed it. Any ideas? Any help is appreciated. Thanks!!


      • I get the same error. In the script we use the “Server” variable. I tried it with the Database variable and I got the same error. We are on Exchange Version 14.1 (Build 218.15)

        • We get connected and it starts to queue the mailbox as a batch and then every mailbox fails.

          VERBOSE: Connecting to ~OURSERVER~
          VERBOSE: Connected to ~OURSERVER~.
          Queuing 432 mailboxes as batch ‘Export_2012-7-3_16-13-41’
          Failed to communicate with the mailbox database.
          + CategoryInfo : ResourceUnavailable: (0:Int32) [New-MailboxExportRequest], QuotaExceededException
          + FullyQualifiedErrorId : 70AB83B8,Microsoft.Exchange.Management.RecipientTasks.NewMailboxExportRequest

        • Has anything else changed? What is your Exchange environment like, Single Server or multiple server with split CAS/HT and MBX roles? Does restarting the Microsoft Exchange Mailbox Replication Service have any effect?

          • I found the week it started happening (June 2nd – June 9th). No patches or reboots happened in that time. We only have a single server running Exchange 2010. Restarting that service didn’t fix anything. I found the following errors in the APPLICATION EVENT LOG when I run the script. Is some sort of System Mailbox full preventing the export to run?

            WARNING, Source: MSExchangeIS, Event ID: 8528, Task Catergory: General

            The mailbox for /o=~OURCOMPANY~/ou=Exchange Administrative Group (FYDIBOHF23SPDLT)/cn=Recipients/cn=SystemMailbox{8f96cb50-2c6d-4879-91f7-399afe5cd2cc} has exceeded the maximum mailbox size. This mailbox cannot send or receive messages. Incoming messages to this mailbox are returned to sender. The mailbox owner should be notified about the condition of the mailbox as soon as possible.

            ERROR, Source: MSExchange Management Application, Event ID: 5000, Task Catergory: AdminAuditLog

            Succeeded: False
            Error: Microsoft.Exchange.Data.Storage.QuotaExceededException: Failed to communicate with the mailbox database. —> Microsoft.Mapi.MapiExceptionShutoffQuotaExceeded: MapiExceptionShutoffQuotaExceeded: Unable to save changes. (hr=0x80004005, ec=1245)\nDiagnostic context:\n Lid: 55847 EMSMDBPOOL.EcPoolSessionDoRpc called [length=1227]\n Lid: 43559 EMSMDBPOOL.EcPoolSessionDoRpc returned [ec=0x0][length=252][latency=0]\n Lid: 23226 — ROP Parse Start —\n Lid: 27962 ROP: ropWriteStream [45]\n Lid: 17082 ROP Error: 0x4DD \n Lid: 28769 \n Lid: 21921 StoreEc: 0x4DD \n Lid: 27962 ROP: ropExtendedError [250]\n Lid: 1494 —- Remote Context Beg —-\n Lid: 26426 ROP: ropWriteStream [45]\n Lid: 5721 StoreEc: 0x4DD \n Lid: 60223 \n Lid: 1750 —- Remote Context End —-\n Lid: 26849 \n Lid: 21817 ROP Failure: 0x4DD \n Lid: 17361 \n Lid: 19665 StoreEc: 0x4DD \r\n at Microsoft.Mapi.MapiExceptionHelper.ThrowIfError(String message, Int32 hresult, SafeExInterfaceHandle iUnknown, Exception innerException)\r\n at Microsoft.Mapi.MapiProp.SaveChanges(SaveChangesFlags flags)\r\n at Microsoft.Exchange.MailboxReplicationService.MoveObjectInfo`1.CreateMessage(T obj, GetAdditionalProperties getAdditionalPropertiesCallback)\r\n at Microsoft.Exchange.MailboxReplicationService.MoveObjectInfo`1.CreateMessage(T obj)\r\n at Microsoft.Exchange.MailboxReplicationService.Report.c__DisplayClass1.b__0()\r\n at Microsoft.Exchange.MailboxReplicationService.MapiUtils.RetryOnObjectChanged(GenericCallDelegate del)\r\n at Microsoft.Exchange.Management.RecipientTasks.NewRequest`1.InternalProcessRecord()\r\n at Microsoft.Exchange.Configuration.Tasks.Task.ProcessRecord()\r\n — End of inner exception stack trace —
            Run Date: 2012-07-04T17:34:03
            OriginatingServer: EXCHANGESERVER (14.01.0355.001)

            Microsoft.Exchange.Data.Storage.ConnectionFailedTransientException: Cannot open mailbox /o=~OURSERVER~/ou=Exchange Administrative Group (FYDIBOHF23SPDLT)/cn=Configuration/cn=Servers/cn=EXCHANGESERVER/cn=Microsoft System Attendant. —> Microsoft.Mapi.MapiExceptionLogonFailed: MapiExceptionLogonFailed: Unable to open message store. (hr=0x80040111, ec=-2147221231)

          • I fixed it. When I cleared out all of the MailboxExportRequests, one of the FAILED entries was in error. Once I cleared that entry (through ADSI edit) it all ran fine.

  41. Hey Steve, the script above was working great up until a couple of weeks ago. I get the error:

    Failed to communicate with the mailbox database.
    + CategoryInfo : ResourceUnavailable: (0:Int32) [New-MailboxExportRequest], QuotaExceededException
    + FullyQualifiedErrorId : 3A738D45,Microsoft.Exchange.Management.RecipientTasks.NewMailboxExportRequest

    Any ideas? It was working beautifully but I think maybe an exchange or windows update killed it. Any help would be GREATLY appreciated. Thanks again

  42. hi,im getting the following error,can you please help:
    Cannot validate argument on parameter ‘Mailbox’. The argument is null. Supply a non-null argument and try the command a
    + CategoryInfo : InvalidData: (:) [New-MailboxExportRequest], ParameterBindingValidationException
    + FullyQualifiedErrorId : ParameterArgumentValidationError,New-MailboxExportRequest

  43. I’m ready to start learning/using Power Shell with Exchange 2010. I want to use it for brick level backup of certain mailboxes as described above. I want to make sure that using New-MailboxExportRequest to a pst file is just copying the contents of a mailbox to a pst. I don’t want to remove the contents or the mailbox.

  44. hi,steven
    When Run This Script,Some Mailbox have this Error

    the server or shared name specified in the path may be invalid or the file could be locked


  45. Hello Steve,

    Perfect command for export all mailbox to pst !!

    I run the command, but it works only few mailbox and getting error for “Can’t open mailbox” where i try to single one by one its works.
    I checked the event vwr i found two critical errors;
    Process Microsoft.Exchange.RpcClientAccess.Service.exe (PID=2700). User ‘Sid~NT AUTHORITY\SYSTEM~RCA~false’ has gone over budget ‘931’ times for component ‘RCA’ within a one minute period. Info: ‘Policy:[Fallback], Parts:CAS:930;’. Threshold value: ‘100’.
    Cmdlet failed. Cmdlet New-MailboxExportRequest, parameters {Mailbox=AD.COM/Users/Admin, FilePath=\\Macsrv\DBSTRG\Admin.pst}.

    I’ve 5 database with running Exchange std sp1 version
    pls help me to come out the issue.


  46. Hello Steve,

    thank you very much for your support.
    After a complete Restart of the Hub-Cas Server in our DAG, all Export- and Import Features works fine!

    Thank you for your great instructions on your Website,


Comments are closed.