How to copy Online Archive data back into the mailbox

4

Here are some field notes from a recent Exchange 2010 Retention and Archive case. We had to get data back from the Online Archive and back into the users mailbox, to it’s original location.

There are several ways of getting data back from an Exchange Online Archiving into the Mailbox of the user. One way is having the user copy the data back manually from his/her archive into their inbox using drag and drop.

Another way, which is described in this post – is to do it centrally on the Exchange 2010 Server using the New-MailboxExportRequest and New-MailboxImportRequest PowerShell commands.

To get statistics about the Archive content, see my blog post: Exchange 2010 Archive Mailbox Statistics PowerShell script.

Permissions to use the cmdlets

Make sure you have the permissions to run the Export and Import cmdlets.

Run the Exchange Management Shell elevated as Administrator

If your account does not have permissions to run the New-MailboxExportRequest and New-MailboxImportRequest cmdlets, then run the follow RBAC command:

New-ManagementRoleAssignment -Role "Mailbox Import Export" –User DomainAdminAccount

 

Export the archive to a PST file

The mailbox used in the example below is “IT”.

Run the following cmdlet to Export the Online Archive of the mailbox IT to a PST file located on a fileshare:

New-MailboxExportRequest –Mailbox IT  -IsArchive -FilePath filesharePSTITarchive.pst

It is important to remember the parameter “-IsArchvie” which states that it is the online archive of the IT mailbox that gets exported.

Check status of the Export using the cmdlet:

Get-MailboxExportRequest

 

 

Import the exported PST file into the mailbox

The mailbox used in the example below is still “IT”.

Run the following cmdlet to Import the PST file (containing the Online Archive) into the IT mailbox and to the original location of the content:

New-MailboxImportRequest -Mailbox IT -FilePath filesharePSTITarchive.pst

If you want to import the content of the PST file into e.g. a specific folder within the mailbox, use this command instead:

New-MailboxImportRequest -Mailbox IT -FilePath filesharePSTITarchive.pst -TargetRootFolder "RecoveredFiles"

Check status of the Export using the cmdlet:

Get-MailboxImportRequest

 

Reference information about using Export and Import cmdlets

Here is some reference information about using those cmdlets below:

About Author

Peter is an Exchange specialist with over 15+ years of experience with Exchange Server and certified Microsoft Certified Master (MCM) and Microsoft Certified Solutions Master (MCSM) on Exchange Server. He has been awarded the Microsoft MVP award, every year since 2007. He is active in the Microsoft community and User Group Leader for CoLabora (a danish UC & Cloud User Group). He works as an Cloud & Infrastructure Architect and Consulent, with primary focus on Exchange, Office 365, Azure and Skype for Business.

4 Comments

  1. Hi Peter,

    This is not possible, We have mailboxes on On-Prem and archive mailbox on O365, Please i was not able to export the pst using “IsArchive” command. Please let us know how do i do it.??

    I guess its not possible.

  2. Hi Peter,
    Excellent article on this, but there is a catch that I found…

    Using Outlook client, if an end-user does a Ctrl+A and try to move all the emails back into the main mailbox from online archive, the operation fails with an error “Items cannot be found as they may have been already moved or deleted” I am guessing that this fails due to the fact that Online Archive is indeed online folder and data is not completely downloaded to the client.

    Using Outlook on web for O365, there is no option for us to do a “Select All” and move all emails at one shot. This is possibly to move what is manually selected or a “select all that is displayed” mode. This is a tedious procedure if one wants to move thousands of emails from online archive to the main mailbox.

    Please suggest if there is a workaround or if there is any easier way to achieve this.

  3. Hi,

    I used the import\export requests and imported the PST into a new folder. after checking the size of the folder using Get-MailboxFolderStatistics it was different than the size of the PST!

    I checked the import request status and it was Completed.

    Any clues ?

Leave A Reply

Copyright 2005-2015 - Peter Schmidt.