How to Schedule Windows Server Backup

If you are using Windows Server Backup to backup Exchange Server then you will want to configure a scheduled back task to automate the process.

Windows Server Backup has scheduling capabilities built in.  You can configure a scheduled backup job by clicking on Backup Schedule in the actions pane of the Windows Server Backup console.

Creating a scheduled backup in Windows Server Backup

Creating a scheduled backup in Windows Server Backup

However you might notice that the scheduling options are limited.  You can either perform a daily backup, or more frequent backups, but not less frequent backups.

Windows Server Backup scheduling options

Windows Server Backup scheduling options

Why would you want to create less frequent scheduled backups of an Exchange server?

Two example scenarios are:

  • Reducing backups to run weekly because the data is already protected by a Database Availability Group
  • Running two different backup jobs on alternating days that backup to two different devices or locations

Fortunately you can schedule your Windows Server Backup jobs to run any time you like simply by creating the jobs manually in Task Scheduler.

Launch Task Scheduler by searching for it in the Start Menu of the server you wish to back up.

Launch Task Scheduler

Launch Task Scheduler

In the Actions pane click on Create Task.

Create a new Scheduled Task

Create a new Scheduled Task

Give the new task a meaningful name, and then configure it to run whether the account is logged on or not.  This allows it to run completely unattended.

Configure the scheduled task security options

Configure the scheduled task security options

On the Triggers tab click on the New button.

Create a new trigger for the scheduled task

Create a new trigger for the scheduled task

The trigger for this task will be the schedule you want to run your backups on.  In this example the Exchange server will be backed up weekly on Saturdays.

Create a schedule for the backup job

Create a schedule for the backup job

On the Actions tab click the New button.

Create a new Action for the scheduled task

Create a new Action for the scheduled task

The action for this scheduled task will be to run wbadmin.exe, which is the command-line tool for managing Windows Server Backup.

The full command being configured for the scheduled task is:

wbadmin start backup -backupTarget:F: -include:D:,E: -allCritical -vssfull -quiet

This command line performs the following:

  • start backup – tells wbadmin.exe to start a backup
  • -backupTarget – this is the target volume to store the backup on, in this case F: (no trailing backslash)
  • -include – these are the volumes to include in the backup job, in this case D: and E: because they are the volumes with Exchange databases and transaction logs on them
  • -allCritical – this tells Windows Server Backup to also include any other volumes or data that are required for a full server recovery, eg the System volume and SystemState. This is optional if you only want to backup the Exchange data.
  • -vssfull – this tells Windows Server Backup to perform a full VSS backup of Exchange and truncate the transaction logs
  • -quiet – runs the command silently with no visual interaction

Configure the wbadmin.exe command line

Configure the wbadmin.exe command line

You can inspect the extra conditions and settings to see if you want to configure anything else for your environment.

The wbadmin command-line for the Exchange backup

The wbadmin command-line for the Exchange backup

Otherwise click OK.  You will be prompted for the password for the user account you configured to run the scheduled task (note: I recommend you use a proper service account for this and not the Administrator account).

Enter the credentials for the scheduled task

Enter the credentials for the scheduled task

The new scheduled backup job will now appear in Task Scheduler.

Exchange backup job in Task Scheduler

Exchange backup job in Task Scheduler

Task scheduler will also display the last run time and result for the scheduled task.