To backup Exchange Server 2013 mailbox database, there is a sufficiently large number of specialized software products, each of which has its strengths and weaknesses. However, most of them are paid, and their price is likely to cause substantial blow to the humble IT budget small companies.
Fortunately, you can use the functionality Windows Server Backup (WSB) Features, which is a built-in backup module in Windows Server 2008/2008 R2. Of course, its functionality supports only a limited quantity of functions and is not so convenient in terms of control but at least in case of some emergency allows not remain without an actual backup of users’ mailboxes.
So, we have the following configuration: a network with Exchange Server 2013 mail server (on Windows Server 2008 R2) with one mailbox database. Our task is to configure Exchange 2013 mailbox store backup by using standard Windows tools.
Several major technical issues regarding backup Exchange 2013 mail databases by means of WSB:
- Backup is performed with a help of Volume Shadow Copy Service at a volume level completely.
- Only local backup launch and management are possible
- Backup copy can be written either on a local disk or over the network to a shared folder
- It is possible to create only full database backup. Incremental and differential backups are not supported.
- Only active DAG database backup is possible.
Windows Server Backup feature is not installed in Windows Server 2008 R2 by default. Let’s install this component from the command prompt:
1 2 3 | Import-Module ServerManager Add-WindowsFeature "Backup-Features" | Add-WindowsFeature "Backup-Tools" |
Using the following command you can check whether Backup Features component is installed:
1 | Get-windowsfeature | where {$_.name -like "*backup*"} |
Database backup Exchange 2013 can be configured from the GUI Server Backup or using Powershell. Consider 2 way.
Let’s import Windows Backup commands in Powershell session:
1 | add-pssnapin windows.serverbackup |
Create new backup policy which will include all backup parameters and update schedule:
1 | $WBPolicyExch = New-WBPolicy |
Assign a drive on which Exchange mail database will be stored ( in our example it’s E:\)
1 | $BackupSrc = New-WBFileSpec –FileSpec E:\ |
Add the drive to the policy
1 | Add-WBFileSpec –Policy $WBPolicyExch –FileSpec $BackupSrc |
Assign a drive or network share, where backup will be stored (don`t assign a system drive or the same drive with a database) :
1 | $WBTargetFolder = New-WBbackupTarget –NetworkPath "\\ny-srvbkp\exchange2013" |
Add backup device to the policy
1 | Add-WBBackupTarget –Policy $WBPolicyExch -Target $WBTargetFolder |
Assign that VSS Full Backup procedure will be used for backup
1 | Set-WBVssBackupOptions -Policy $WBPolicyExch -VssFullBackup |
Check the policy for errors
1 | $WBPolicyExch |
Check mail database status before backup start:
1 | Get-MailboxDatabase mdb001 –Status |
In this case we can see that mailbox database backup was never performed before.
You can start Exchange 2013 mail database backup immediately
1 | Start-WBBackup -Policy $WBPolicyExch |
Or according to the schedule:
1 | Set-WBSchedule –Policy $WBPolicyExch –Schedule 22:00 |
After backup completion WSB will update mail database header and write information about the time of the last successful backup in it.
1 | Get-MailboxDatabase mdboo1 -Status | select Lastfullbackup |
To display backup list use the following:
1 | Get-WBBackupSet |
Use the following to get the last backup task status:
1 | Get-WBJob -previous 1 |
In the next article in this series we show how to recover Exchange 2013 database from backup.