Backup job automation

Automation helps to simplify the jobs design and configuration. It also makes daily operation easier.

Important: When creating jobs based on containers, ensure that the configured constructs do not overlap.

Tags

With Veeam you can create jobs based on VM tags, which can help to automate the job configuration. Instead of choosing manually the VMs you want to include in the job, you can include all VMs with a specific tag.

In this way, if you assign a tag used in a job to a new VM, Veeam will include that new VM in the job processing the next time the job runs. No need for any job modification at all when you assign the tag to new VMs.

It is recommended to follow these guidelines:

  • Monitor the number of VMs automatically added to the job to avoid too many VMs being backed up within a single job. See the backup jobs page for guidance on job size.
  • Prefer a single tag per VM for inclusion where possible. Tag combination view lets you require multiple tags by using AND logic. That reduces tag sprawl but makes it easier to leave a VM unprotected if one tag is missing. Monitor unprotected VMs with Veeam ONE.
  • Using tags, you can classify VMs by service levels, using different backup jobs for different service levels.
  • Veeam ONE Business View can manage vSphere tags. It allows creating classification rules and updates corresponding tags in vCenter. Classifications can be defined from CPU, RAM, VM naming convention, folder, resource pool, datastore etc. Business View can also import VM/host/datastore descriptions from a CSV file. This feature can be useful when refreshing VMware tags, for example, to update a CMDB.

A common field pattern is a catch-all job on a higher-level container (folder or datacenter) so VMs that miss their policy tag still get a basic backup until they are correctly tagged.

See VM Tags for requirements (FQDN, certificate, resolution) and the inheritance limitation with containers.


Container based jobs

Adding resource pools, folders, datastores or vSphere tags to backup jobs makes backup management easier.

New machines that are members of such constructs or containers are automatically included in the backup job, and machines removed from the container are immediately removed from job processing. Overlapping constructs may cause undesired results. For instance, when creating jobs based on datastores, VMs with disks residing on multiple datastores included in more than one backup job will cause the VM to be backed up in each job.

Avoid choosing individual ESXi hosts in a backup/replica job when you have a vSphere Cluster with DRS. DRS could migrate VMs automatically (vMotion) from one host to another based on performance or affinity criteria, which could impact the job configuration and could lead a VM to stop being protected by the backup/replica job.

The same could happen when you choose an individual datastore to the backup/replica job, and the datastore belongs to a vSphere Datastore Cluster with Storage DRS. Storage DRS could migrate the VM (Storage vMotion) to another datastore based on performance or capacity criteria, which again could lead the VM to stop being protected by a backup/replica job.

Important: As a general rule, it is recommended to use infrastructure-agnostic containers/constructs in a backup/replica job, like folders or tags, avoiding the use of infrastructure components like hosts, datastores or even clusters to prevent unexpected behaviors and getting the VMs unprotected. Solutions like vRealize Operations Manager / Aria Operations could even migrate VMs from one vSphere cluster to another by using Workload Optimization.


PowerShell and REST API

Tags and containers cover the membership automation most environments need. When you need to create or modify the jobs themselves at scale, or drive them from an external source of truth, use the Veeam PowerShell module or the REST API.

See the PowerShell reference and REST API reference.

The Veeam Community also provides a repository of Open Source (MIT) pre-created scripts: VeeamHub

Note that scripts not supported by Veeam.


References


Back to top

Copyright © 2026 Solutions Architects, Veeam Software.