In this article we would like to share the Advantages of Database Portability. Database Portability which was first introduced in Exchange Server 2007 in the year 2006. Now the same options are available in Exchange Server 2010 and Exchange Server 2013. It is very useful in a disaster recovery scenario.
Recently I was handling an issue of Moving large mailbox across servers. Each mailbox size was more than 5 GB and it was failing. Since the users were high profile users. Taking chances on the mailboxes were almost impossible. So the only options available with us was to move them to other server with minimum downtime and at the same time keeping all the folders and other custom settings intact.
Test Lab Scenario
Exchange Server 2010 with SP3
Server Names : MBX1 (Source), MBX2 (Target).
Database Names : Finance (Source), Finance2 (New Target – Dismounted).
Points to remember
- Downtime is required.
- Valid database backup is must. Either online or offline copy.
In figure 1 the mailbox is online on Active Source Database.
In figure 2 the database is mounted and online. We have to dismount the database post performing a valid backup. In our scenario we have taken offline copy. Offline copies are easy to restore. To perform an offline copy dismount the database and copy the files as shown below.
In figure 3 we can see the database files. The location of the files can be located by going to the properties of the Database Name in EMC or by PowerShell using the below command.
Get-MailboxDatabase –identity finance | fl *path*
Copy the database files only and restore it in the target server. Post restoring the database files it is always a best practices to check the health of the database files. To do that open PowerShell command and type the below command.
The database shows as clean shutdown. So we are good to go.
Now in the target server right click the Database and go to properties and select “Maintenance” tab and select “This database can be overwritten by a restore”. Post which rename the database files as per the target database name. In our scenario we have renamed it from “Finance” to “Finance2”. Post which copy the database files to the database location. In our scenario it is “c:\Finance2\Finance2.edb” as shown below.
Now before moving ahead some preliminary checks are important.
Now its time to move the mailbox from source database to target database. It is always a best practices to check with –whatif command by running the below command.
Get-Mailbox –Database Finance | Set-Mailbox –Database Finance2 –whatif
Once confirmed remove the –whatif command and rerun it again.
Get-Mailbox –Database Finance | Set-Mailbox –Database Finance2
It will prompt for confirmation. Select your desired options. In our case we have selected “A” as shown below.
Now lets confirm if the mailbox has been moved to target database by running the below command again.
Now its time to mount the target database as shown below.
Post mounting the database check the queues if there is any emails stuck in the queues run the below command via Exchange PowerShell.
Get-queue QueueName | Retry-Queue –Resubmit $true
In figure 10 Mailbox Moved without any data loss and custom settings.
I hope it helps in dealing with large mailbox moves across servers and sites.
Applies to : Exchange Server 2007, Exchange Server 2010, Exchange Server 2013