Help Center
Choose product document...
Veeam Agent for Linux 1.0
User Guide

Backup Job Scripts

You can instruct Veeam Agent for Linux to run custom scripts within the backup job session:

  • Pre-job and post-job scriptsVeeam Agent for Linux runs these scripts before the backup job starts and after the backup job completes. You can use pre-job and post-job scripts, for example, to configure email notifications about jobs performed by Veeam Agent for Linux.
  • Pre-freeze and post-thaw scripts (in the server mode only) — Veeam Agent for Linux runs these scripts before and after creating a snapshot. For example, the pre-freeze script may quiesce the file system and application data to bring the Linux OS to a consistent state before Veeam Agent for Linux creates a snapshot. After the snapshot is created, the post-thaw script may bring the file system and applications to their initial state.

Script settings are enabled at the job level. If Veeam Agent for Linux operates in the server mode and you want to configure multiple backup jobs, you can specify individual scripts for each job.

Scripts must be created beforehand. You must specify paths to them in the job settings. Veeam Agent for Linux supports scripts in the SH file format.

Pre-Job and Post-Job Scripts

You can instruct Veeam Agent for Linux to run custom pre-job and post-job scripts. Veeam Agent for Linux executes the pre-job script directly before the backup job starts. After the backup job completes, Veeam Agent for Linux executes the post-job script.

Veeam Agent for Linux starts the backup job regardless of the pre-job script result. If the pre-job script fails to execute, Veeam Agent for Linux will always start the backup job. Then, after the backup job completes, Veeam Agent for Linux will execute the post-job script.

The script is considered to be executed successfully if "0" is returned.

The default time period for script execution is 10 minutes. After this period expires, Veeam Agent for Linux stops executing the script and displays a warning message in the job session. If the script fails to execute before the timeout expires, Veeam Agent for Linux does not display warning messages in the job session.

Pre-Freeze and Post-Thaw Scripts

You can instruct Veeam Agent for Linux to run custom pre-freeze and post-thaw scripts. Veeam Agent for Linux executes the pre-freeze script before creating a snapshot. After the snapshot is created, Veeam Agent for Linux executes the post-thaw script.

The script is considered to be executed successfully if "0" is returned.

The default time period for script execution is 10 minutes. After this period expires, Veeam Agent for Linux stops executing the script.

By default, if the pre-freeze or post-thaw script fails to execute, Veeam Agent for Linux does not start the backup job. However, you can instruct Veeam Agent for Linux to ignore errors that occur during the script execution process. To allow Veeam Agent for Linux to start backup jobs regardless of the script execution result, in the /etc/veeam/veeam.ini configuration file, uncomment the ignoreFreezeThawFailures parameter and set its value to true.

If Veeam Agent for Linux is set up to ignore script errors, and the pre-freeze or post-thaw script fails to execute, Veeam Agent for Linux will start the backup job. After the job successfully completes, Veeam Agent for Linux will display the Warning status for the job session.

Backup Job Scripts Note:

You can specify pre-freeze and post-thaw scripts only if Veeam Agent for Linux operates in the server mode. If these scripts were enabled for the job while Veeam Agent for Linux operated in the server mode, and then Veeam Agent for Linux has switched to another mode (for example, to the free mode after the license has expired), the backup job will be failing. You will need to delete the existing job and create a new backup job without pre-freeze and post-thaw scripts enabled.

 

Veeam Large Logo

User Guide

Veeam Backup & Replication Documentation

Veeam ONE Documentation

Veeam Management Pack Documentation

Veeam Agent for Microsoft Windows Documentation