How to configure backups to run sequentially

This article applies only to Backup4all. If you don't have it yet, you must download it first.

DOWNLOAD BACKUP4ALL
Mar 13, 2019

Backup4all 7 and older

We strive to keep our articles as accurate as possible. If you notice any inconsistencies or outdated info please let us know.

How to configure backups to run sequentially

This article explains how to configure backup jobs to run sequentially. A backup job (a tag or group of jobs) can be configured to run right after another backup job is finished.

On this page:

A backup job (a tag or group of jobs) can be configured to run right after another backup job is finished. In Backup4all, for each backup job an action can be performed before or after that backup job runs. Since Backup4all supports command line parameters too, that action can be a command line instruction. So the first backup job will have an after-action added that will start the second backup job using command line instructions.

How to configure a set of jobs to run one after the other

When you have a set of jobs that you need to run sequently, since version 5 of Backup4all you can use a tag to set them up. Create a new tag and assign that tag to all jobs you want to run sequently. When you run the backup tag, all jobs containing that tag will be executed one after another.
This solution is useful when you want to manually or scheduled run multiple backup jobs, but you want to use limited computer resources or bandwidth (one job at a time will be executed). The solution can be also used when setting up different scenarios where the backup jobs must run in a specific order.
A backup tag can be scheduled the same way as a backup job. Open the Scheduler (F11) page and create a new scheduled task, selecting the tag to be executed.

How to configure a backup job to start after another backup job finishes

Some situations require running two or more backup jobs (from the same or different backup group) one after the other in order to accomplish a backup scenario. Such a situation is when an user wants to back up to multiple destinations.

For Backup4all 5, 6 and 7:

In the first example, you just need to put bbackup.exe /r job2 in Backup Properties -> Advanced -> Run action after backup section of the Job1. That will start the backup for Job2.

In the second example we will have 2 backup jobs: Job1 and Job2 scheduled to run at the same time, but configured to run one after the other. Job1 will create a text file at the end of the execution, while Job2 will wait for the text file name to appear. When the text file will be generated, that means Job1 was executed and Job2 will start. The text file is deleted after the execution of Job2.

First, you need to create 3 batch files:

  • after_job.bat will contain the following text:
    *type NUL > <path\_to\_backup\_done>\\backupdone.txt*
  • before_job2.bat will contain:
    *@echo off* *:wait IF NOT EXIST <path\_to\_backup\_done>\\backupdone.txt (* *echo Job1 not finished. Sleeping for 5 seconds* *call timeout /T 5* *goto wait* *)*
  • after_job2.bat will contain:
    *del <path\_to\_backup\_done>\\backupdone.txt* Don't forget to replace the "*<path\_to\_backup\_done>*" with the correct path on your computer.

Here are the steps to set up the jobs:

  1. Open Backup4all and go to File -> New.
  2. Type the name of the backup job and select the destination, then press Next.
  3. Select the backup sources and press Next.
  4. Select the backup type and press Advanced mode.
  5. Go to Advanced mode and select the "Run program or action" in the "Run action after backup" section, then choose the "after_job1.bat" file to be executed after the backup.
  6. Press Save.
  7. For the second backup job, repeat steps 1 to 4
  8. Then go to Advanced mode and select the "Run program or action" in the "Run action before backup" section, then choose the "before_job2.bat" file to be executed before the backup.
  9. Then go to Advanced mode and select the "Run program or action" in the "Run action after backup" section, then choose the "after_job2.bat" file to be executed after the backup.

For Backup4all 4:

To have a backup job (Backup_job2) running after a previous backup job (Backup_job1) finished:

  1. Open Backup4all and select File -> New Backup Wizard (Ctrl+N).
  2. On the General page enter a name for the backup (Backup_job1) in the Name field. Click Next.
  3. On the Sources page, add the files and folders to be backed up. Click Next.
  4. On the Destination page, select a destination for backup. Click Next.
  5. On the Type page, select the backup type. By default, the incremental type is selected. Click Next.
  6. Optionally on the Filter page you can add some include/exclude filters. Click Next.
  7. On the Advanced page, go to the Actions tab.
    • In the After backup section, check the Run program/action option and type:
      "C:\Program Files (x86)\Softland\Backup4all Professional 4\b4aSchedStarter.exe" /r "<backup name>"
    • Click Finish.

Video Tutorial how to configure the backup job:

Note: <backup name> is the name of the backup job that you want to run after the current backup job finishes, so in this example that would be Backup_job2.

Configure backup

How to configure a backup tag/group to start after a backup job finishes

A backup tag/group can be configured to start after a backup job finished running using command line instructions.
Step by step instructions on how to start a backup tag/group (New_Tag) after a backup job (Backup_job1) finished running:

  1. Open Backup4all and select File -> New (Ctrl+N).
  2. On the General page enter a name for the backup (Backup_job1) in the Name field. Click Next.
  3. On the Sources page, add the files and folders to be backed up. Click Next.
  4. On the Destination page, select a destination for backup. Click Next.
  5. On the Type page, select the backup type. By default, the incremental type is selected. Click Next.
  6. Optionally on the Filter page you can add some include/exclude filters. Click Next.
  7. On the Advanced page, go to the Actions tab.
    • In the After backup section, check the Run program/action option and type:
    • For Backup4all 7:
      "C:\Program Files (x86)\Softland\Backup4all Professional 7\b4aSchedStarter.exe" /TG "<tag name>"
    • For Backup4all 6:
      "C:\Program Files (x86)\Softland\Backup4all Professional 6\b4aSchedStarter.exe" /TG "<tag name>"
    • For Backup4all 5:
      "C:\Program Files (x86)\Softland\Backup4all Professional 5\b4aSchedStarter.exe" /TG "<tag name>"
    • For Backup4all 4:
      "C:\Program Files (x86)\Softland\Backup4all Professional 4\b4aSchedStarter.exe" /g "<group name>"
  8. Click Finish.

Video Tutorial how to configure the backup tag/group:

Note: <*tag name*> or <*group name*> is the name of the backup tag/group that you want to run after the current backup job finishes. In the example above, instead of *<*group tag*>/<group name>* it should be New_Tag.

Configure backup

Applies to:

Backup4all 4.x - 7.x



POPULAR ARTICLES

Full backup
07 December 2018
USB backup
18 January 2019
Mirror backup
12 October 2018


LATEST ARTICLES

How to clear the backup
14 March 2019
Backup demo
13 March 2019