Showing posts with label Exchange 2013 Recovery Database. Show all posts
Showing posts with label Exchange 2013 Recovery Database. Show all posts

Saturday, January 11, 2014

MapiExceptionTooManyMountedDatabases - Unable to Mount Exchange 2013 Recovery Database

MapiExceptionTooManyMountedDatabases - Unable to Mount Exchange 2013 Recovery Database

While performing recovery of mailbox in Exchange 2013 Server you may come across the below error message after creating recovery database in Exchange Server 2013

The first error message will get disappeared if you wait for few seconds this is due to AD replication time limit

Error Message 1:


[PS] C:\>Mount-Database RDB05
Failed to mount database "RDB05". Error: An Active Manager operation failed. Error: Couldn't find the specified
mailbox database with GUID '3fbd735e-8971-4c35-ab41-7162ea4e16a6'. [Database: RDB05, Server: MBX01.MAIL.COM]
    + CategoryInfo          : InvalidOperation: (RDB05:ADObjectId) [Mount-Database], InvalidOperationException
    + FullyQualifiedErrorId : [Server=MBXV01,RequestId=2f1842f5-5291-4e81-b15c-8be44d51df15,TimeStamp=1/10/2014 6:2
   6:49 AM] BF20CAA1,Microsoft.Exchange.Management.SystemConfigurationTasks.MountDatabase
    + PSComputerName        : MBX01.MAIL.COM

After few second started to get different error message 2 from the previous one as shown below. Thought the product has evaulation copy or not licensed. Verified on running the following command

Get-Exchangeserver -Identity MBX01 | fl *produ*, *valid*


The product is enterprise edition and it is activated already. But still it throw the error message and while verifying the database found there is already recovery database exist and it is mounted. Dismounted the older recovery database and started to mount the new recovery database in Exchange server 2013 and it started to work fine.

Error Message 2:

[PS] C:\>Mount-Database RDB05
Failed to mount database "RDB05". Error: An Active Manager operation failed. Error: The database action failed. Error:
Operation failed with message: MapiExceptionTooManyMountedDatabases: Unable to mount database. (hr=0x8004060e,
ec=-2147219954)
Diagnostic context:
    Lid: 65256
    Lid: 10722   StoreEc: 0x8004060E
    Lid: 1494    ---- Remote Context Beg ----
    Lid: 37952   dwParam: 0x7A7F9E06
    Lid: 39576   StoreEc: 0x977
    Lid: 54768   StoreEc: 0x8004060E
    Lid: 35056   StoreEc: 0x8004060E
    Lid: 48432   StoreEc: 0x8004060E
    Lid: 54336   dwParam: 0x7A7F9E16
    Lid: 1750    ---- Remote Context End ----
    Lid: 1047    StoreEc: 0x8004060E [Database: RDB05, Server: MBX01.MAIL.COM]
    + CategoryInfo          : InvalidOperation: (RDB05:ADObjectId) [Mount-Database], InvalidOperationException
    + FullyQualifiedErrorId : [Server=MBX01,RequestId=a3cebf81-cfc4-48b3-8f3d-29ad2c5db45b,TimeStamp=1/10/2014 6:2
   8:09 AM] 95477B08,Microsoft.Exchange.Management.SystemConfigurationTasks.MountDatabase
    + PSComputerName        : MBX01.MAIL.COM

Moral: In Exchange Server 2013 you can have only one recovery database mounted state and it doesn't support more than one recovery database in the Exchange organization.

Thursday, January 9, 2014

Step by Step Exchange 2013 Database Recovery

Step by Step Exchange 2013 Database Recovery
Step 1: Provide the folder path location to the backup team where the database and log file needs to restore. Note: Make sure you have enough free disk space on the restored location
Step 2: Verify the database health status after the restoration of database file. Run the following command to verify the status
eseutil.exe /mh E:\Recovery\RDB.edb | select-string "State:", "Log Required"
Step 3: If the database is Clean Shutdown move to next step. In case if it is dirty shutdown perform the soft recovery and if it fails move to hard recovery
Step 4: Create Recovery database using the following commands
New-MailboxDatabase -Recovery RDB01 -Server MBX01 -EdbFilePath E:\Recovery\RDB.edb
Step 5: Verify the database is in mounted state
Get-MailboxDatabase RDB01 -status | fl Name, Mounted
Step 6 : Mount the database
Mount-Database RDB01 –Verbose
Step 7 : Verify the database mounted status
Get-MailboxDatabase RDB01 -status | fl Name, Mounted
Step 8: Verify the mailbox statistics of the restored database
To find all mailbox in the recovery database - Get-mailboxstatistics -database RDB01
To find specific mailbox w.r.t to user account or GUID - Get-MailboxStatistics -Database RecoveryDB | ?{$_.DisplayName -like 'Raji*'} | fl DisplayName,MailboxGuid,DisconnectDate
Step 9: Restoring them using the following Exchange PowerShell command based upon your requirement
  • Restoring the complete user mailbox
New-mailboxrestorerequest –sourcedatabase “RDB01” –sourcestoremailbox “Rajis” –targetmailbox “Rajis@mail.com"
  • Restoring the mailbox using guid

New-MailboxRestoreRequest -SourceDatabase “RDB01” -SourceStoreMailbox 4a1d2118-b8cc-456c-9fd9-cd9af1f549d0 -TargetMailbox Raji
  • Restoring the source mailbox to different user mailbox
New-MailboxRestoreRequest -SourceDatabase “RDB01” -SourceStoreMailbox 'Raji' -TargetMailbox Subramanian -TargetRootFolder Restore -AllowLegacyDNMismatch
  • Restoring the mailbox email in a seperate folder (Restore) on the user mailbox

New-MailboxRestoreRequest -SourceDatabase “RDB01” -SourceStoreMailbox 'Raji' -TargetMailbox 'Raji' -TargetRootFolder Restore -IncludeFolders '#Inbox#/#Test#/*' -AllowLegacyDNMismatch
Step 10: Check the status of mailbox restoration when completed check in the user mailbox on all restored emails.
Get-MailboxRestoreRequest
Step 11: Remove the completed mailbox restore using the following PowerShell command
Get-MailboxRestoreRequest -status Completed | Remove-MailboxRestoreRequest
Reference URL
http://technet.microsoft.com/en-us/library/dd876954%28v=exchg.150%29.aspx 
http://technet.microsoft.com/en-us/library/ee332321(v=exchg.150).aspx
http://technet.microsoft.com/en-us/library/ee332351%28v=exchg.150%29.aspx

The blog is written to the share the knowledge mainly on Microsoft Exchange Server and other Microsoft product that experienced on day-to-day life.