Mads Krag Dam - Homepage - MadsD.dk

A part of iSites.dk
Home
Blog
My IT
Husband
Family
Games
Pictures
Contact

Exchange 2010 - Restore mailbox


Written by: Mads Dam - 28.11.2011 - 0 comments

So, sometimes my HR-department makes mistakes and, mistakenly, lay of a person in our HR-management-system. This in turn, makes the AD-user-object, files and mailbox disappear magically via our daily cleanup-powershell-script.

HR corrected the mistake, and it's now up to me to restore the mailbox, among other things.

Here's how I do it:
We used:

  • Exchange 2010 SP1 Rollup Update 6
  • System Center Data Protection Manager 2010
  1. Create a recover database on the mailbox server, that has my DPM agent installed
    New-MailboxDatabase -Recovery -Server MBX001 -Name RDB
    New-MailboxDatabase -Recovery -Server MBX001 -Name RDB -EdbFilePath "M:\RDB\rdb.edb" -LogFolderPath "M:\RDB"

  2. Make sure it is mounted, either via EMC og EMS - Your choice - It might not mount before AD has completed it's replication.

  3. Also make sure it is set, so "This database can be overwritten by a restore" (Right-click -> Properties -> Maintenance in EMC)

  4. In the DPM console - Find the mailbox that you want to recover, right-click it and press recover.

  5. Note, that if the user has been deleted - the mailbox might lie in another database than a possible current one - provided that your system automatically creates a new mailbox for the user, as mine does!

  6. If the user haven't been deleted, but you just need to restore some items from it - Make a note to ask your user from WHEN he/she/it wants it restored from!

  7. Follow the guide in DPM:
    - Recover mailbox to an Exchange server database
    - Specify the Exchange-server where you created the RDB, and the name of the RDB :)

  8. Press Next -> Next -> Next, until it starts recovering the data into the RDB

  9. After it's finished, you now have a mailbox lying around in the recovery database. What you need to do now is merge the recovered database, with the new one.

  10. Find the Global Unique Identifier (guid) and DisplayName of the mailbox you want to copy items from by running this in EMS:
    Get-MailboxStatistics -Database RDB | Select-Object DisplayName,MailboxGuid | Sort-Object DisplayName

  11. Now create a request for the merging - Either by GUID or by DisplayName:
    New-MailboxRestoreRequest -SourceDatabase RDB -TargetMailbox mads -SourceStoreMailbox c4847352-3a53-4f42-b531-d10a25171b03 -AllowLegacyDNMismatch
    New-MailboxRestoreRequest -SourceDatabase RDB -TargetMailbox mads -SourceStoreMailbox "Mads Dam"

  12. Mails should now pour into the target mailbox even while the user is actively using it :)

Inspired by:
Creating a Recovery Database:
http://technet.microsoft.com/en-us/library/ee332321.aspx

Restore Data Using a Recovery Database:
http://technet.microsoft.com/en-us/library/ee332351.aspx

 

 


Comments



No comments


Write a comment


Name:
Website: *no http://
Comment: