Creating File-Level Backup Job

To back up files and directories of your machine, you must configure a backup job. The backup job settings define what data to back up as well as where and how to back up data.

You can configure one or more backup jobs to back up your data. Configuring several backup jobs may be useful in the following situations:

  • You can configure backup jobs targeted at different backup repositories to keep several copies of your backed-up data at different locations.
  • You can configure several backup jobs and define individual schedule for every job to back up necessary data at the desired time.

To create a backup job, use the following command:

veeamconfig job create --name <job_name> --reponame <repository_name> <objects> [<advanced_options>] [<schedule_options>] [<active_full_backup_options>] [--indexall]

where:

  • <job_name> — name for the created backup job.
  • <repository_name> — name of the backup repository that will be used as a target location for backup files.

If you want to create Veeam Agent backups on a local storage or in a network shared folder, you must create the backup repository in advance, before configuring the backup job. To learn more, see Creating Backup Repository.

If you want to create Veeam Agent backups in the Veeam backup repository, you must connect to the Veeam backup server in advance, before configuring the backup job. To learn more, see Connecting to Veeam Backup Server.

  • --indexall — defines that Veeam Agent for Oracle Solaris must index files in the directories included in the backup. To learn more, see File System Indexing.

For example:

user@srv01:~$ veeamconfig job create --name system\ backup --reponame [vbr01]\ Backup\ Vol\ 01 --includedirs / --excludemasks "*.pdf" --maxpoints 7 --indexall

 

Tip

Consider the following:

  • If a value of a command option contains the space character, specify the value in single quotation marks ('') or double quotation marks (""). Alternatively, use the backslash character (\) as an escape character. For example, this may be required if you want to specify the backup job name, backup repository name or path to a folder you want to back up.
  • After you create the backup job, you can additionally configure the following backup job settings:

 

 

File Inclusion Options

When you create a backup job, you must specify at least one directory that should be included in backup. If you do not want to back up some files and directories in the specified directory, you can exclude specific files and directories from backup.

To define the backup scope for the file-level backup job, you can use the following command-line options:

Option

Description and values

--includedirs

Full path to a directory that must be included in backup, for example: /export/home/user.

You can specify one or more paths to directories in the machine file system. To separate several paths, use the ',' (comma) character, for example: /export/home/user/Documents,/export/home/user/reports.

IMPORTANT Performing bare metal recovery requires a backup that includes the full contents of the root directory. To configure such backup job, set the value of the --includedirs option to /, for example: veeamconfig job create --name system\ backup --reponame VeeamBackup --includedirs /. This backup job generates an additional configuration file required for restoring your files during bare metal recovery. If use excludedirs, includemasks or excludemasks options in backup job settings, mind that no system data is excluded from backup.

--excludedirs

Full path to a directory that must be excluded from backup. The directory specified with this option should be a subdirectory of one of the directories specified with the --includedirs option. Otherwise, the --excludedirs option does not have any effect on backup.

To separate several paths, use the ',' (comma) character, for example, /export/home/user/Documents,/export/home/user/reports.

--includemasks

File name mask that defines files that must be included in backup. You can use the following UNIX wildcard characters for file name masks:

  • '*' — a substitution for zero or more characters in the file name or path. Can be used for any sequence of characters (including no characters). For example, *.pdf.
  • '?' — a substitution of one character in the file name or path. For example, repor?.pdf.
  • '[]' — a substitution of one character in the file name or path with any of the characters enclosed in square brackets (or a range of characters defined with the '-' character). For example: report_201[3456].pdf or report_201[3-6].pdf.

If you use wildcard characters in file name masks, you must specify masks in double quotation marks (""). To separate several masks, use a ',' (comma) character. For example: --includemasks "*.bak,*.pdf".

File inclusion option is applied to all directories that are specified with the --includedirs option. For example, if you include in backup the /export/home/user/Documents directory and files that match the repor?.pdf file name mask, Veeam Agent for Oracle Solaris will back up the /export/home/user/Documents/report.pdf file and will not back up the /export/home/user/reports/report.pdf file.

--excludemasks

File name mask that defines files that must be excluded from backup. You can use the following UNIX wildcard characters for file name masks:

  • '*' — a substitution for zero or more characters in the file name or path. Can be used for any sequence of characters (including no characters). For example, *.pdf.
  • '?' — a substitution of one character in the file name or path. For example, repor?.pdf.
  • '[]' — a substitution of one character in the file name or path with any of the characters enclosed in square brackets (or a range of characters defined with the '-' character). For example: report_201[3456].pdf or report_201[3-6].pdf.

If you use wildcard characters in file name masks, you must specify masks in double quotation marks (""). To separate several masks, use a ',' (comma) character. For example: --excludemasks "*.bak,*.pdf".

File exclusion option is applied to all directories that are specified with the --includedirs option and files that match file name masks specified with the --includemasks option. For example, you may want to specify the following backup scope for the backup job:

  • Include in backup the /export/home/user/Documents directory.
  • Include files that match the report.* file name mask.
  • Exclude files that match the *.odt file name mask.

In this case, Veeam Agent for Oracle Solaris will back up the /export/home/user/Documents/report.pdf file and will not back up /export/home/user/Documents/report.odt and /home/user/reports/report.pdf files.

 

Advanced Backup Job Settings

You can specify the following advanced options for the backup job:

Option

Description and values

--compressionlevel

Data compression level. The default value is 2. Possible values:

  • 0 — None
  • 1 — Dedupe-friendly
  • 2 — Optimal
  • 3 — High
  • 4 — Extreme

NOTE Changing to a higher compression level may require more RAM during backup.

To learn more about available data compression levels, see Data Compression.

--blocksize

Data block size in kilobytes. The default value is 1024. Possible values are 256, 512, 1024, 4096 or 8192.

NOTE Changing to a larger block size may require more RAM during backup.

To learn more about available sizes of data blocks, see Data Compression.

--maxpoints

Number of restore points that you want to store in the backup location. By default, Veeam Agent keeps 7 latest restore points. When the new restore point that exceeds the specified number is created, Veeam Agent will remove the earliest restore point from the backup chain.

--prejob

Path to the script that will be executed at the start of the backup job.

--postjob

Path to the script that will be executed after the backup job completes.

--setencryption

Defines that data encryption option is enabled for the job. When you use the veeamconfig job create command with the --setencryption option, Veeam Agent will prompt you to specify a password for data encryption and hint for the password.

You cannot use this option if you want to save backup files on a Veeam Backup & Replication repository. Encryption options for Veeam Agent backup jobs targeted at a Veeam backup repository are managed by a backup administrator working with Veeam Backup & Replication. To learn more, see Setting Up User Permissions on Backup Repositories.

--deleteold

Number of days to keep the backup created with the backup job in the target location. If Veeam Agent does not create new restore points for the backup, the backup will remain in the target location for the specified number of days. When this period is over, the backup will be removed from the target location.

By default, the retention period for old backups is 30 days.

You can specify this option only for backup jobs targeted at a Veeam Backup & Replication repository.

 

Schedule Settings

If you use Veeam Agent version 4.0, you can specify schedule options for the backup job to create backups daily or on specific weekdays at specific time.

Option

Description and values

--weekdays

[For weekly schedules] Specifies the weekdays when the backup job must run. If you want to run the backup job more than once during the week, the list of weekdays must be separated by a comma (','). Possible values are:

  • Mon — Monday
  • Tue — Tuesday
  • Wed — Wednesday
  • Thu — Thursday
  • Fri — Friday
  • Sat — Saturday
  • Sun — Sunday

--daily

[For weekly schedules] Defines that the backup job must start daily at specific time.

--thisday

[For monthly schedules] Specifies the day of the month when the backup job must run. Possible values: from 1 to 31 or Last.

Note that if the specified value is greater than the number of days in the month, the backup job will not run that month. For example, if you schedule the backup job for the 31st day of the month, Veeam Agent will not create backups during shorter months.

--weeknumber

[For monthly schedules] Specifies the week of the month when the backup job must run. Possible values: First, Second, Third, Fourth or Last. This option must be used in combination with the --monthlyweekday option.

--monthlyweekday

[For monthly schedules] Specifies the day of the week when the backup job must run. You can select only one weekday. Possible values are:

  • Mon — Monday
  • Tue — Tuesday
  • Wed — Wednesday
  • Thu — Thursday
  • Fri — Friday
  • Sat — Saturday
  • Sun — Sunday

--months

[For monthly schedules] Specifies the months when the backup job must run. If you specify more than one month, the list must be separated by a comma (,) — for example: Jan,Apr,Jul,Oct. If you do not specify this option, the backup job will run every month.

--every

[For periodic schedules] Specifies the period of time in minutes or hours between the runs of the backup job. The period must be specified in the HH: MM format — for example, 06:00.

--at

[For weekly and monthly schedules] Specifies the time of day in the HH:MM format when the backup job must start — for example: 20:00.

After the backup job is created, Veeam Agent for Oracle Solaris automatically enables backup schedule. To learn about how to configure backup schedule for an existing backup job, see Configuring Backup Schedule.

Active Full Backup Schedule Settings

You can specify schedule options for the backup job to create active full backups on specific weekdays or days of the month.

If you use Veeam Agent version 4.0, you can specify schedule options for the backup job to create active full backups on specific days of the week or month.

Option

Description and values

--weekdays-full

[For weekly schedules] Specifies the weekdays when the backup job must create an active full backup. If you want to create an active full backup more than once during the week, the list of weekdays must be separated by a comma (','). Possible values are:

  • Mon — Monday
  • Tue — Tuesday
  • Wed — Wednesday
  • Thu — Thursday
  • Fri — Friday
  • Sat — Saturday
  • Sun — Sunday

--thisday-full

[For monthly schedules] Specifies the day of the month when the backup job must create an active full backup. Possible values: from 1 to 31 or Last.

Note that if the specified value is greater than the number of days in the month, the backup job will not create an active full backup that month. For example, if you schedule active full backups for the 31st day of the month, Veeam Agent will not create active full backups during shorter months.

--weeknumber-full

[For monthly schedules] Specifies the week of the month when the backup job must create an active full backup.. Possible values: First, Second, Third, Fourth or Last. This option must be used in combination with the --monthlyweekday option.

--monthlyweekday-full

[For monthly schedules] Specifies the day of the week when the backup job must create an active full backup. You can select only one weekday. Possible values are:

  • Mon — Monday
  • Tue — Tuesday
  • Wed — Wednesday
  • Thu — Thursday
  • Fri — Friday
  • Sat — Saturday
  • Sun — Sunday

--months-full

[For monthly schedules] Specifies the months when the backup job must create an active full backup. If you specify more than one month, the list must be separated by a comma (,) — for example: Jan,Apr,Jul,Oct. If you do not specify this option, the backup job will create an active full backup. every month.

After the backup job is created, Veeam Agent for Oracle Solaris automatically enables active full backup schedule. To learn about how to configure active full backup schedule for an existing backup job, see Configuring Active Full Backup Schedule.

Page updated 8/30/2024

Page content applies to build 4.6.0.1772