Tuesday, 29 November 2011

Backing up Ex2010 mailboxes to PST

Exchange 2010 SP1 has a new command to import and export to a PST.

First you need to give yourself permissions to do this with the following command:

New-ManagementRoleAssignment –Role “Mailbox Import Export” –User “<username>”

You will need to close down and open up the console again to gain access to the commands below.

Then you need to run the following to actually Export for a PST

New-MailboxExportRequest -Mailbox user@domain.com -FilePath \\path\to\file.pst 

If it's a backup of the archive you're after add -IsArchive on the end

You can check on the progress of the backup with:

Get-MailboxExportRequest

or

Get-MailboxExportRequestStatistics username\MailboxExport -IncludeReport | fl | Out-File c:\temp\output.txt

For full details.

You can clear any old Mailbox requests with:

Remove-MailboxExportRequest -Identity "username\MailboxExport"

or 

Get-MailboxExportRequest | Remove-MailboxExportRequest

to remove them all (and be prompted)

Very simple!

I hope this article helps you out... please click on an advert to show your appreciation.