To install the SQL Backup Pro server components, run SQBServerSetup.exe. This file is copied to the SQL Backup Pro program folder (%Program Files%\Red Gate\SQL Backup <version number> for 32-bit servers, %Program Files (x86)%\Red Gate\SQL Backup <version number> for 64-bit servers) when the SQL Backup Pro user interface is installed.

To install the server components unattended, call SQBServerSetup.exe from the command line with /VERYSILENT and /SUPPRESSMESSAGEBOXES. For example:

SQBServerSetup.exe /VERYSILENT /SUPPRESSMSGBOXES

The server components will be installed on the local instance using the default settings unless you specify otherwise using the parameters described below.

SQL Backup Pro server components installation parameters

ParameterDescription
/VERYSILENT

Performs an installation without launching the SQL Backup (server components) Setup wizard. All the values that would normally be entered in the wizard must be defined at the command line, otherwise the default values will be used.

Use in combination with /SUPPRESSMSGBOXES.

/SUPPRESSMESSAGEBOXESSuppresses any warning or information boxes that would appear. No information will be returned if an error arises. Use in combination with /VERYSILENT.
/I <instance>Specifies the instance to install on. If this parameter is not specified, the default instance is used. Do not specify more than one instance.
/PATH <folder>

Installs the server components in the specified directory. When installing on a cluster, the directory can be a shared drive.

If this parameter is not specified, the server components are installed in the default location (%ProgramFiles%\Red Gate\SQL Backup <version number>\<instance name> on 32-bit machines and %ProgramFiles(x86)%\Red Gate\SQL Backup <version number>\<instance name> on 64-bit machines).

/SVCUSER <name> | <enc_name>

Specifies the user account used to log on to the SQL Backup Agent service (the startup account). Use either clear-text or an encrypted format.

If this parameter is not specified, the account the SQL Server instance is currently running as is used.

For details of the permissions required by the SQL Backup Agent service startup account, see Permissions.

/SVCPW <password> | <enc_password>

Specifies the password for the user account used to log on to the SQL Backup Agent service (the startup account). Use either clear-text or an encrypted format. Must be used with /SVCUSER.

The password may only include 7-bit ASCII characters. If the password contains any other characters, the SQL Backup Agent service will not start.


/SQLUSER <name> | <enc_name>

Specifies that the SQL Backup Agent service should connect to the SQL Server using the specified SQL Server authenticated account. Use either clear-text or an encrypted format.

If this parameter is not specified, Windows authentication is used.

For details of the permissions required by the SQL Server authenticated account, see  Permissions.

/SQLPW <password> | <enc_password>

Specifies the password for the specified SQL Server authenticated account. Use either clear-text or an encrypted format. Must be used with /SQLUSER.

The password may only include 7-bit ASCII characters. If the password contains any other characters, the installation will fail.


/DATAPATH <folder>

Specifies the location in which the SQL Server Compact database is created. The SQL Server Compact database stores SQL Backup Pro backup and restore information.

If this parameter is not specified, the Compact database is created in the default location: %ProgramData%\Red Gate\SQL Backup\Data (Windows Vista, Windows 2008 and later) or %ALLUSERSPROFILE%\Application Data\Red Gate\SQL Backup\Data (Windows XP and Windows 2003).

/LOGPATH <folder>

Specifies the location in which the SQL Backup Pro logs are stored. SQL Backup Pro creates a log for each backup or restore process it runs.

If this parameter is not specified, the logs are stored in the default location:%ProgramData%\Red Gate\SQL Backup\Log (Windows Vista, Windows 2008 and later) or %ALLUSERSPROFILE%\Application Data\Red Gate\SQL Backup\Log(Windows XP and Windows 2003).

/CLUSTERINSTALLInstalls SQL Backup Pro server components as a clustered service. SQL Server must be installed as a clustered resource on the host machine.
/CLUSTERUSER <name> | <enc_name>Specifies the user name of the user that the installer will run as for clustering registration. Use either clear-text or an encrypted format. Use in combination with/CLUSTERINSTALL.
CLUSTERPW <password> | <enc_password>

Specifies the password of the user that the installer will run as for clustering registration. Use either clear-text or an encrypted format. Must be used with/CLUSTERUSER.

The password may only include 7-bit ASCII characters. If the password contains any other characters, the installation will fail.


/CLUSTERNODESpecifies a cluster-based install on a secondary node (rather than the primary node). The server components will not be installed on other nodes in the cluster.
/LOGWrites information from the installation to a log file, which can be found in %TEMP% as "Setup Log yyyy-mm-dd #nnn.txt"
/EXITCODEFILE <file>Logs the outcome of the installation to the specified text file using the exit codes listed below.

Example 1 

The following command installs SQL Backup Pro server components in the default location on the local instance, specifies the account the SQL Backup Agent service should run as, and specifies that it should use SQL Server authentication to connect to the local instance (the specified accounts should have sysadmin privileges):

SQBServerSetup.exe /VERYSILENT /SUPPRESSMSGBOXES /SVCUSER "user name" /SVCPW "password" /SQLUSER "user name" /SQLPW "password"

Note that the /SQLUSER and /SQLPW parameters are only necessary if you want the SQL Backup Agent service to connect to the SQL Server instance using SQL authentication rather than Windows authentication.

Example 2

The following command installs SQL Backup Pro server components on the SQL2008 server in D:\SQLBackup\ServerComponents, specifies the locations of the data and log stores (D:\SQLBackup\ServerComponents\SQBData and D:\SQLBackup\ServerComponents\SQBLog respectively), and specifies the account the SQL Backup Agent service should run as:

SQBServerSetup.exe /verysilent /SUPPRESSMSGBOXES /i (SQL2008) /Path D:\SQLBackup\ServerComponents /DATAPATH D:\SQLBackup\ServerComponents\SQBData /LOGPATH D:\SQLBackup\ServerComponents\SQBLog /svcuser "SQLBACKUPSERVICEUSER" /svcpw "password"

The SQL Backup Agent service will connect to the SQL Server using the Windows authentication of the startup account, because SQL Server authentication has not been specified.

SQL Backup exit codes

Exit codeDefinition
0Installation was successful.
Pre-installation failures
5Another installation is in progress. Try again later.
6000Current user has insufficient permissions to modify Windows Services.
6010Windows 2003 Itanium edition requires SP1 to be installed before installing SQL Backup Pro server components.
6020The user account specified for the SQL Backup Agent service to log on as could not be verified.
6030The user account specified for the SQL Backup Agent service to log on as was ambiguous. Ensure the account details are fully qualified.
6040The password for the SQL Backup Agent service user account was invalid.
6100The user account specified for the SQL Backup Agent service to log on as does not have permission to log on as a service.
6110Unable to grant 'log on as a service' rights.
6200SQL authenticated user name or password is invalid.
6210SQL authenticated account is not a member of the sysadmin role.
Post-installation failures
8192SQL Backup Agent service executable (SQBCoreService.exe) is not installed.
16384The version of the SQL Backup Agent service is incorrect.
32768The SQL Backup Agent service could not be registered correctly.
65536The SQL Backup Agent service was unable to start within 1 minute.
131072The SQL Backup Pro extended stored procedure dynamic-link library (xp_sqlbackup.dll) was not installed correctly.
262144

The version of the SQL Backup Pro extended stored procedure dynamic-link library (xp_sqlbackup.dll) is incorrect.

524288Unable to confirm that the SQL Backup Pro extended stored procedure dynamic-link library (xp_sqlbackup.dll) was registered correctly (connection error).
1048576Some SQL Backup Pro extended stored procedures were not registered correctly.
2097152The installer could not set the SQL Backup Agent service's instance (-I) flag.

The exit codes can be combined to form a bitmask. For example, a value of 278528 would mean that the versions of the SQL Backup Agent service and the SQL Backup Pro extended stored procedure dynamic-link library are incorrect.

You may find this Simple Talk article about installing SQL Backup Pro on multiple servers using SQL Multiscript useful.