Here’s a guide to automate the installation of your Veeam Agents for Windows (VAW) with PowerShell and Batch scripts. Basically, I used Clint’s guide to automate the deployment of Veeam Agent for Windows. But I did some modifications for an end-user environment because the license and configuration files did not work with his PS script. The issue is you need to use those credentials would be in the Config.XML file so only an Administrator account would need to be used to install via the script. Depend on your context, end-user would use other credentials to run the script. You can follow this guide to automate Veeam Agent for Windows below…
One very interesting thing with Veeam Agent is the ability to monitor the agents via your centralized Veeam Backup & Replication console. You need to to upgrade your Veeam Backup Server to Veeam B&R 9.5 Update 2, (version 126.96.36.1998) then you will be able to manage/track your jobs from Veeam B&R console.
Infrastructure relying on 10 physical sites:
- Two Datacenters (DC1/DC2) 1km far from each other running a VMware stretched cluster on HPE 3PAR, this is the logical primary Datacenter (production – headquarters),
- 2 x 10Gb/s between each primary site and the DRP site (Disaster Recovery),
- Others branch offices are backing up with Veeam Agents for Windows on-premise (50 agents are split into 10 physical sites). Low bandwidth WAN.
Veeam production infrastructure overview:
- 1 physical Veeam Backup server is doing Direct SAN Proxy (Use Storage snapshots – FC), Repository ReFS, WAN Accelerator (cache SSD)
- 1 NAS is running on the DRP site (10 Gbps),
- Interaction proxy (gateway) and Mount Server on remote offices – Veeam Agent for Windows – WAN Accelerator “many-to-one”.
Backup process is :
- First, backup from HPE 3PAR to local site repository (ReFS) using Direct SAN and Storage Snapshots integration (headquarters),
- Then, at the end of the backup window, starting a Backup Copy job from primary site copying the freshly done backup to a NAS at the DRP site,
- Branch offices are backing up on-premise to a CIFS repository with Veeam Agent for Windows,
- VAW’s destination is Veeam B&R server located at the headquarters (DC1/DC2), it allows to monitor agents from Veeam Backup console and create Backup Copy Jobs. So, realizing offsite backup of branch offices to DRP site. We are able to use WAN Accelerator.
Goal: Simplify the deployment of VAW on physical sites (ROBO).
Realizing VAW template (“Config.xml”):
First, you have to realize a Veeam Agent for Windows template by utilizing the new configuration CLI / API tool that’s now available.
You can follow this step by step guide to install Veeam Agent for Windows.
Then, from an elevated command prompt CD to and run (you can follow Clint’s guide):
C:\Program Files\Veeam\Endpoint Backup\Veeam.Agent.Configurator.exe -Export
It exports your exact VAW configuration including all job settings. The file is located here: C$:\ProgramData\Veeam\Endpoint\!Configuration .
You can easily update or change it as necessary the file without having to export the configuration again (SMTP notifications, from:, to: etc.).
PowerShell file structure configuration:
First, you can head to the VeeamHUB @GitHub to grab a copy of the sample script that Clint is providing. Then, follow Clint’s guide to set up PowerShell file structure (license directory, Config.XML directory, VAW .exe directory etc.).
Veeam Agent for Windows deployment – Running the PowerShell script:
You have to connect to the target server on which VAW needs to be deployed, then open a PowerShell terminal.
Run this command line:
Set-ExecutionPolicy -ExecutionPolicy Unrestricted
Steps 2 and 3 don’t work (the issue is you need to use those credentials would be in the Config.XML file so only an Administrator account would need to be used to install via the script.). So, during Veeam Agent for Windows is installing, you have to select “NO” when the wizard requests to import the license.
Then, from an elevated CMD command prompt, run:
cd "C:\Program Files\Veeam\Endpoint Backup"
Veeam.Agent.Configurator.exe -license /f:"\\VAW-LICENSE-FILE-DIRECTORY\veeam_agent_windows_subscription.lic"
Veeam.Agent.Configurator.exe -import /f:"\\VAW-CONFIG-XML-FILE-DIRECTORY\Config.xml"
Checking VAW configuration:
Finally, you can check Veeam Agent for Windows configuration including import of license file and all job settings (Backup Server destination, email notifications etc.).
Run VAW software and click on “ABOUT” tab:
Then, click on “SETTINGS” tab and “Configure and test” button:
Check « Preconfigured by system administrator » setting is implemented:
From the main interface, click on “Configure backup”:
Once setup wizard is open, click on “Backup Server” tab and enable the “Specify your personal credentials:” option. Then, enter the service account and the corresponding password.
Hope this guide will help you! Veeam Agents (Windows and Linux) are powerful. They can allow you to backup your physical workloads and workstations. Next Veeam Backup and Replication v10 release will allow to manage and monitor your Veeam Backup and Replication environment and the whole of your workstations and standalone servers from only one interface!
Differences between VAW editions:
- Windows Server 2016 support
- Source-side encryption
- Optional periodic Active Full backup
- Configurable compression and block size
- Improved backup performance for file level backup mode
- Option to skip bad blocks enabled by default
Workstation (in addition to Free)
- 24.7.365 support
- Backup cache for mobile users
- Backup directly to Veeam Cloud Connect
- Remote management and configuration API
- Optional periodic synthetic full backup
Server (in addition to Workstation)
- Application-aware processing engine (same functionality as in Veeam Backup & Replication 9.5)
- File system indexing (including the integration with Veeam Backup Enterprise Manager catalog search and 1-Click FLR)
- Server-focused job scheduler (same as in Veeam Backup & Replication 9.5)
Veeam Availability Suite 9.5 first full availability solution! Full description!
You can learn more about Veeam Backup & Replication 9.5 here.
You can learn more about Veeam Availability Suite 10 and VeeamON 2017 announcements here.
Veeam Agent for Windows step by step installation guide.
If you need to disable UAC Server on Windows Server 2016 Script Guide.