Schedule sequential backups or images

Applies to: Standard, Professional and Server Editions of Macrium Reflect only.

 

Overview

Using VBScript you can schedule multiple backups or images and run them one after the other. This creates a problem because you cannot know how long each backup will take and therefore, when you can start the next. One solution is to create a single VBScript file that runs all the backups or images sequentially.

To create a VBScript to run backups sequentially

  1. Step through the backup or image wizard and create the required XML backup definitions files.

  2. In the Backup Definition Files tab, right-click a backup definition file and choose Generate a VB Script File from the shortcut menu.



    The VBScript generation dialog box appears.

  3. Leave the options as defaults but change the file name for clarity.

  4. Select the VBScript Files tab, right-click the new file and select Edit from the shortcut menu.



    The VBScript file opens in the system default text editor, generally this is Notepad.

  5. For clarity, switch off word wrap. In notepad, choose Edit > Word Wrap.

  6. Find the line of code that starts the backup and copy and paste it once for each backup or image you want to run.

    The line looks like this:

    ExitCode = Backup ("""C:\Program Files\Macrium\Reflect\reflect.exe"" -e -w <BACKUP_TYPE> ""C:\Backups\backup1.xml""")

  7. For each copy of the line change the xml file name to represent the backup you want to run. For example:

    ExitCode = Backup ("""C:\Program Files\Macrium\Reflect\reflect.exe"" -e -w <BACKUP_TYPE> ""C:\Backups\backup1.xml""")
    ExitCode = Backup ("""C:\Program Files\Macrium\Reflect\reflect.exe"" -e -w <BACKUP_TYPE> ""C:\Backups\backup2.xml""")
    ExitCode = Backup ("""C:\Program Files\Macrium\Reflect\reflect.exe"" -e -w <BACKUP_TYPE> ""C:\Backups\backup3.xml""")
     

  8. Save the file.

  9. Execute or schedule the VBScript source file in exactly the same way as a backup definition file. See Schedule backups.