Initiating backups manually
Once a backup policy is defined, the backups will occur automatically according the defined schedule. However, there are occasions when an on-demand or one-off backup is necessary—for instance before performing system maintenance or installing new software.
In this recipe, we will show how to perform an on-demand backup using the existing backup policy outside of the predefined schedule. Additionally, we will create a one-off backup policy to back-up the files and folders in C:\InetPub
and store them on the E:\
drive.
Getting ready
For this recipe, we will be using a system configured for backups similar to the previous recipe Configuring backup policies.
How to do it...
Initiate the default backup policy.
Get-WBPolicy | Start-WBBackup
Monitor the backup using
Get-WBSummary
command:Get-WBSummay
When executed, the status is displayed, as shown in the following screenshot:
Perform a one-off backup of
C:\InetPub
using the following command:$myPol = New-WBPolicy $mySpec =...