How to backup Exchange 2013 mailbox database on Windows Server 2008 R2 SP1

It is possible to backup Exchange 2013 mailbox databases with Windows backup, however, there are some limitations in functionality. For normal LAB or small bussiness it is fine solution.

Exchange Backup limitations

  • Only Full backup is possible with log truncation (incremental backups do not flush logs)
  • Normal backup performance option does always full backup, but only differences are stored in the disk, while using file block mode.
  • After initial full backup every other backup of the same volume to the same target is incremental unless the following two conditions are fulfilled:
  • 14 incremental backups have occurred since the last full backup
  • More than 14 days have passed since the last full backup ( http://technet.microsoft.com/en-us/library/dd759145.aspx )

Configuring Windows backup

Installation

Windows Server Backup feature is not installed by default on W2k8 R2 SP1 server.

  • To gather status use the following Powershell command:
Get-windowsfeature | where {$_.name -like "*backup*"}
  • To install Windows Server Backup features run the following commands from Powershell. These commands will install needed features to run Exchange backup via command line tool Wbadmin.
Add-WindowsFeature "Backup-Features" Add-WindowsFeature "Backup-Tools"

  • In backup/restore of Exchange servers we will use Powershell commands. Run the following command to import WB command to Powershell session.
add-pssnapin windows.serverbackup
  • Add new disk for Exchange backups. In script there is used “Backup Disk” as volume name. (Depends on the HW you use, please use your HW guidance)

  • To succesfully configure Windows Server Backup we must first define backup policy:
$WBPolicyFull = New-WBPolicy         # Create new WB policy object
$WhatToBackup = New-WBFileSpec –FileSpec E:    # Define what to backup
Add-WBFileSpec –Policy $WBPolicyFull –FileSpec $WhatToBackup  # Adding what to backup to backup policy
$WBTarget = New-WBbackupTarget –NetworkPath "\Servernamesharenamepath"  # Selected backup disk will be set as target
Add-WBBackupTarget –Policy $WBPolicyFull -Target $WBTarget   # Adding target to WB policy
Set-WBVssBackupOptions -Policy $WBPolicyFull -VssFullBackup   # Set method to use WSS Full Backup
  • To check policy:
$WBPolicyFull
  • Status of mailbox database before initial full backup
Get-MailboxDatabase <identity> -Status

  • Policy configured in previous step might be started directly
Start-WBBackup -Policy $WBPolicyFull

  • Or scheduled
Set-WBSchedule –Policy $WBPolicyFull –Schedule 21:00
  • After initial full backup the mailbox database is changed

  • To list backup sets:
Get-WBBackupSet
  • To list job result:
Get-WBJob -previous 1

Example

add-pssnapin windows.serverbackup
$WBPolicyFull = New-WBPolicy
$WhatToBackup = New-WBFileSpec –FileSpec E:
Add-WBFileSpec –Policy $WBPolicyFull –FileSpec
$WhatToBackup $WBTarget = New-WBbackupTarget –Networkpath "\backend1g$Full"
Add-WBBackupTarget –Policy $WBPolicyFull -Target
$WBTarget Set-WBVssBackupOptions -Policy
$WBPolicyFull -VssFullBackup
Start-WBBackup -Policy $WBPolicyFull

Results


		
Advertisements

Exchange – Essential Articles

Mailbox Limits

Backups