- Large Enterprise environment w/ 100's of SQL Servers
- Multiple Vbr servers, each handling a subset of the SQL Servers
- Dedicated SQL Server instance(s) for daily restore/CHECKDB testing.
Since the config is "global", multiple concurrent restores targeting potentially different VBR hosts is a disaster waiting to happen.
Some options:
- support multiple named profiles in the config tool and add a -VbrProfile to select at restore time.
- add a -configFile argument and user is responsible for generating/copying config files (not ideal, but 100% workable)
Powershell script to setup a new Vbr host:
Code: Select all
##################################################################
#
# VeeamAddVbrServer.ps1
# - Copies the Veeam executable directory and updates config.
#
##################################################################
param(
[Parameter(Mandatory=$true)]
[string]$vbrHost, # fqdn
[switch]$force
)
$srcFolder = "C:\Program Files\Veeam\Plugins\Microsoft SQL\"
$targetFolder= "C:\Program Files\Veeam\Plugins\Microsoft SQL_$($vbrHost.split(".")[0])"
if(-Not (Test-Path $targetFolder) -or $force)
{
Write-output "Copying Veeam to [$targetFolder] "
Copy-Item -Path $srcFolder -Destination $targetFolder -Recurse -Force
Write-output "Updating Veeam configuration in [$targetFolder] "
. "$targetFolder\MSSQLConfigTool.exe" --set-host $vbrHost
}
else
{
Write-output "[$targetFolder] exists."
}