Limited time promo

Cleanup

English

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

Download now Buy licenses
Mar 22, 2022
Backup4all 9.x
We strive to keep our help as accurate as possible. If you notice any inconsistencies or outdated info please let us know.
Backup4all uses for each action a small application that runs independently from the main application. They can be used to create batch files.
The command line parameters for cleanup action are described bellow.

Backup jobs

Syntax

bCleanup [/X ] job_name [-Priority[{1|2|3|4}]

Formatting legend
Italic - Information that must be supplied by the user
Bold - Elements that the user must type exactly as shown
/ - Switches are preceded by slash
[] - Elements between square brackets are optional
| - Vertical line separates possible choices
{} - Items between braces are a set of choices from which the user must choose only one
  • /x - cleans the backup. Supports additional parameters:
  • [/ IE mm.dd.yyyy] - clean the backups older than the specified date
  • [/ IS mm.dd.yyyy] - clean the backups newer then the specified date
  • [/ OT n / OTU {D|W|M|Y}] - n is the number of days (D), weeks (W), months (M) or years (Y)
  • [ /KD ] - keep Differential backups
  • [ /KF ] - keep Full backups
Examples:
To clean all backup versions older than two weeks and keep the full and differential backups of the My Pictures backup job, use:

bCleanup /X "My Pictures" /OT 2 /OTU W /KF / KD - Priority 2

Tags

Syntax

bTagCleanup [/X] tag_name [-Priority[{1|2|3|4}]
Additional parameters can be used:
  • [/ IE mm.dd.yyyy] - clean the backups older than the specified date
  • [/ IS mm.dd.yyyy] - clean the backups newer then the specified date
  • [/ OT n / OTU {D|W|M|Y}] - n is the number of days (D), weeks (W), months (M) or years (Y)
  • [ /KD ] - keep Differential backups
  • [ /KF ] - keep Full backups
The mirror backup jobs will be ignored when running a cleanup for a tag including mirror backup jobs.
Examples:
To clean all backup versions older than two weeks and keep the full and differential backups of the Pictures tag, use:

bCleanup /X "Pictures" /OT 2 /OTU W /KF / KD - Priority 2
To execute a cleanup for Samples tag

bTagCleanup /X "Samples" /OT 2 /OTU W - Priority 2
Backup4all returns exit codes after each task execution (backup, independent test, repair, restore or cleanup).
As a general case, if the action was successful, the exit code is 0, otherwise is different.
Here are the possible exit codes:
  • 0 : action was successful
  • 1 : action has not started, parameter errors, syntax errors, other errors
  • 2 : action finished with errors
  • 3 : action was finished with warnings
  • 4 : independent test was finished with errors
  • 5 : independent test was finished with warnings