Since Veeam has recently published the Veeam ONE 10 and Veeam Backup & Replication 10 RTM Build for Partners and Service Providers, I wanted to get my Veeam Availability Suite 10 unattended installation Ansible Role ready for this major release.
Besides the necessary adjustments for Veeam Availability Suite 10, I have taken care of a problem with the SQL Express setup for Veeam ONE and Veeam Backup & Replication. I had recently discovered a problem: The setup of the SQL Express 2016 only worked fine if the user was logged in to the destination server. The Ansible community on Reddit was very helpful to get this problem solved (thanks to jborean93). It is necessary to run the setup as an explicit user. Ansible can do this via privilege escalation “become” in runas mode and the additional flag logon_type=batch.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
- name: SQL - Install SQL Express 2016 SP2
win_package:
path: "{{ vbr_source }}Redistr\\x64\\SqlExpress\\2016SP2\\SQLEXPR_x64_ENU.exe"
product_id: SQL 2016 Express
arguments:
- '/q'
- '/ACTION=Install'
- '/IACCEPTSQLSERVERLICENSETERMS'
- '/FEATURES=SQL'
- '/INSTANCENAME=VEEAMSQL2016'
- '/SQLSVCACCOUNT={{ sql_username }}'
- '/SQLSVCPASSWORD={{ sql_userpassword }}'
- '/SECURITYMODE=SQL'
- '/SAPWD={{ sql_sapassword }}'
- '/ADDCURRENTUSERASSQLADMIN'
- '/UPDATEENABLED=0'
- '/TCPENABLED=1'
- '/NPENABLED=1'
become: yes
become_flags: logon_type=batch
vars:
ansible_become_method: runas
ansible_become_user: "{{ vbr_username }}"
ansible_become_pass: "{{ vbr_userpassword }}"
|
The handling of the veeam_setup Ansible Role is unchanged. But the Role is now able to run the Veeam ONE 10 and Veeam Backup & Replication 10 RTM Build unattended installation.
Just download the veeam_setup Ansible Role from the Ansible Galaxy and create your Playbook.
This Playbook example installs Veeam Backup & Replication 1o with mostly default settings, just the installation source is modified.
1
2
3
4
5
6
7
8
9
10
11
12
13
|
- name: Veeam Backup & Replication v10 RTM Community Edition Setup
hosts: veeam
gather_facts: no
vars:
vbr_download: false
vbr_setup: true
vbr_source: "E:\\"
vbr_update: false
one_setup: false
one_source: "D:\\"
one_update: false
roles:
- veeam_setup
|
You can find all possible parameters of the Ansible Role in the Defaults YML or the README.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
---
# defaults file for veeam_setup
## Choose Setup
vbr_download: false
vbr_setup: false
vbr_update: false
one_setup: false
## VBR Parameters
one_source: "E:\\"
one_username: "svc_one"
one_userpassword: "ChangeM3!"
one_update_file: "VeeamONE_9.5.4.4587_Update#4a.exe"
one_update_id: "Veeam ONE Update 4a"
vbr_url: "https://download2.veeam.com/VeeamBackup&Replication_9.5.4.2615.Update4.iso"
vbr_checksum: "8a594cec74059f9929ea765ac5e70a49da6fc93803b567cbb9d74fbb1a49a6cc"
vbr_destination: "C:\\install\\"
vbr_destination_file: "vbr.iso"
vbr_source: "D:\\"
vbr_username: "svc_vbr"
vbr_userpassword: "ChangeM3!"
vbr_update_file: "veeam_backup_9.5.4.2866.update4b_setup.exe"
vbr_update_id: "Veeam VBR Update 4b"
sql_username: "svc_sql"
sql_userpassword: "ChangeM3!"
sql_sapassword: "ChangeM3!"
|
My Development and Test environment
My Ansible Development setup slightly changed since my prior blog post.
Ansible Control Machine:
- CentOS 8.1 (4.18.0-147.3.1.el8_1.x86_64)
- Ansible 2.9.3
- Python 3.6.8
Target Server:
To access the Ansible Control Machine and develope the Role in Visual Studio Code, I have switched to the Visual Studio Code Remote Development Extension Pack. This setup is way more comfortable than the remote execution of the Ansible Extension.
Required modifications
To get the Ansible Role ready for the Veeam Availability Suite 10 unattended installation just a few changes have been required.
- Veeam ONE 10 and Veeam Backup & Replication 10 have switched to SQL Express 2016 SP2
- Veeam ONE setup parameter for EULA has changed for all packages
Veeam Backup & Replication 10 unattended installation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
|
---
# vbr_setup tasks file for veeam_setup
- name: Pre - Install 2012 System CLR Types
win_package:
path: "{{ vbr_source }}Redistr\\x64\\SQLSysClrTypes.msi"
state: present
- name: Pre - Install 2012 Shared management objects
win_package:
path: "{{ vbr_source }}Redistr\\x64\\SharedManagementObjects.msi"
state: present
- name: Pre - Create Local Service and RunAs User
win_user:
name: "{{ vbr_username }}"
password: "{{ vbr_userpassword }}"
password_never_expires: yes
state: present
groups:
- Administrators
- name: SQL - Create Local SQL User
win_user:
name: "{{ sql_username }}"
password: "{{ sql_userpassword }}"
password_never_expires: yes
state: present
groups:
- Users
- name: SQL - Install SQL Express 2016 SP2
win_package:
path: "{{ vbr_source }}Redistr\\x64\\SqlExpress\\2016SP2\\SQLEXPR_x64_ENU.exe"
product_id: SQL 2016 Express
arguments:
- '/q'
- '/ACTION=Install'
- '/IACCEPTSQLSERVERLICENSETERMS'
- '/FEATURES=SQL'
- '/INSTANCENAME=VEEAMSQL2016'
- '/SQLSVCACCOUNT={{ sql_username }}'
- '/SQLSVCPASSWORD={{ sql_userpassword }}'
- '/SECURITYMODE=SQL'
- '/SAPWD={{ sql_sapassword }}'
- '/ADDCURRENTUSERASSQLADMIN'
- '/UPDATEENABLED=0'
- '/TCPENABLED=1'
- '/NPENABLED=1'
become: yes
become_flags: logon_type=batch
vars:
ansible_become_method: runas
ansible_become_user: "{{ vbr_username }}"
ansible_become_pass: "{{ vbr_userpassword }}"
- name: Install VBR Catalog
win_package:
path: "{{ vbr_source }}Catalog\\VeeamBackupCatalog64.msi"
state: present
arguments:
- 'VBRC_SERVICE_ACCOUNT_TYPE=1'
- 'ACCEPT_THIRDPARTY_LICENSES=1'
- name: Install VBR Server
win_package:
path: "{{ vbr_source }}Backup\\Server.x64.msi"
state: present
arguments: "VBR_SERVICE_ACCOUNT_TYPE=1 VBR_SQLSERVER_AUTHENTICATION=1 VBR_SQLSERVER_SERVER=(local)\\VEEAMSQL2016 VBR_SQLSERVER_USERNAME=sa VBR_SQLSERVER_PASSWORD={{ sql_sapassword }} ACCEPT_THIRDPARTY_LICENSES=1 ACCEPTEULA=YES"
- name: Install VBR Console
win_package:
path: "{{ vbr_source }}Backup\\Shell.x64.msi"
state: present
arguments:
- 'ACCEPTEULA=YES'
- 'ACCEPT_THIRDPARTY_LICENSES=1'
- name: Install VBR Explorer for ActiveDirectory
win_package:
path: "{{ vbr_source }}Explorers\\VeeamExplorerForActiveDirectory.msi"
state: present
arguments:
- 'ACCEPT_EULA=1'
- 'ACCEPT_THIRDPARTY_LICENSES=1'
- name: Install VBR Explorer for Exchange
win_package:
path: "{{ vbr_source }}Explorers\\VeeamExplorerForExchange.msi"
state: present
arguments:
- 'ACCEPT_EULA=1'
- 'ACCEPT_THIRDPARTY_LICENSES=1'
- name: Install VBR Explorer for Oracle
win_package:
path: "{{ vbr_source }}Explorers\\VeeamExplorerForOracle.msi"
state: present
arguments:
- 'ACCEPT_EULA=1'
- 'ACCEPT_THIRDPARTY_LICENSES=1'
- name: Install VBR Explorer for SharePoint
win_package:
path: "{{ vbr_source }}Explorers\\VeeamExplorerForSharePoint.msi"
state: present
arguments:
- 'ACCEPT_EULA=1'
- 'ACCEPT_THIRDPARTY_LICENSES=1'
- name: Install VBR Explorer for SQL
win_package:
path: "{{ vbr_source }}Explorers\\VeeamExplorerForSQL.msi"
state: present
arguments:
- 'ACCEPT_EULA=1'
- 'ACCEPT_THIRDPARTY_LICENSES=1'
|
Veeam ONE 10 unattended installation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
|
---
# one_setup tasks file for veeam_setup
- name: Pre - Enable firewall
win_firewall:
state: enabled
profiles:
- Domain
- Private
- Public
- name: Pre - Configure firewall rule "Reporter Console"
win_firewall_rule:
name: VeeamONE_ReporterConsole
localport: 1239
action: allow
direction: in
protocol: tcp
state: present
enabled: yes
- name: Pre - Configure firewall rule "Business View"
win_firewall_rule:
name: VeeamONE_BusinessView
localport: 1340
action: allow
direction: in
protocol: tcp
state: present
enabled: yes
- name: Pre - Configure firewall rule "Agent"
win_firewall_rule:
name: VeeamONE_Agent
localport: 2805
action: allow
direction: in
protocol: tcp
state: present
enabled: yes
- name: Pre - Configure firewall rule "Server SMB"
win_firewall_rule:
name: VeeamONE_ServerSMB
localport: 445
action: allow
direction: in
protocol: tcp
state: present
enabled: yes
- name: Pre - Create Local Veeam ONE Service User
win_user:
name: "{{ one_username }}"
password: "{{ one_userpassword }}"
password_never_expires: yes
state: present
groups:
- Administrators
- name: Pre - Create Local SQL Service User
win_user:
name: "{{ sql_username }}"
password: "{{ sql_userpassword }}"
password_never_expires: yes
state: present
groups:
- Users
- name: Pre - Install 2012 System CLR Types
win_package:
path: "{{ one_source }}Redistr\\x64\\SQLSysClrTypes.msi"
state: present
- name: Pre - Install 2012 Shared management objects
win_package:
path: "{{ one_source }}Redistr\\x64\\SharedManagementObjects.msi"
state: present
- name: Pre - Install XML Parser
win_package:
path: "{{ one_source }}Redistr\\x64\\msxml6_x64.msi"
state: present
- name: Pre - Install SQL Native Client
win_package:
path: "{{ one_source }}Redistr\\x64\\sqlncli.msi"
state: present
arguments: "IACCEPTSQLNCLILICENSETERMS=YES"
- name: Pre - Install ReportViewer
win_package:
path: "{{ one_source }}Redistr\\ReportViewer.msi"
state: present
- name: Pre - Install IIS
win_feature:
name: Web-Server
state: present
include_sub_features: yes
include_management_tools: yes
- name: Pre - Install SQL 2016 Express
win_package:
path: "{{ one_source }}Redistr\\x64\\SqlExpress\\2016SP2\\SQLEXPR_x64_ENU.exe"
product_id: SQL 2016 Express
arguments:
- '/q'
- '/ACTION=Install'
- '/IACCEPTSQLSERVERLICENSETERMS'
- '/FEATURES=SQL'
- '/INSTANCENAME=VEEAMSQL2016'
- '/SQLSVCACCOUNT={{ sql_username }}'
- '/SQLSVCPASSWORD={{ sql_userpassword }}'
- '/SECURITYMODE=SQL'
- '/SAPWD={{ sql_sapassword }}'
- '/ADDCURRENTUSERASSQLADMIN'
- '/UPDATEENABLED=0'
- '/TCPENABLED=1'
- '/NPENABLED=1'
become: yes
become_flags: logon_type=batch
vars:
ansible_become_method: runas
ansible_become_user: "{{ one_username }}"
ansible_become_pass: "{{ one_userpassword }}"
- name: Install ONE Monitor Server
win_package:
path: "{{ one_source }}Monitor\\VeeamONE.Monitor.Server.x64.msi"
state: present
# Veean Documentation wrong, VM_VC_SELECTED_TYPE=2 is not default!
arguments: "ACCEPT_THIRDPARTY_LICENSES=1 ACCEPT_EULA=1 VM_MN_SERVICEACCOUNT={{ one_username }} VM_MN_SERVICEPASSWORD={{ one_userpassword }} VM_MN_SQL_SERVER=localhost\\VEEAMSQL2016 VM_MN_SQL_AUTHENTICATION=1 VM_MN_SQL_USER=sa VM_MN_SQL_PASSWORD={{ sql_sapassword }} VM_BACKUP_ADD_LATER=1 VM_VC_SELECTED_TYPE=2"
- name: Install ONE Reporter Server
win_package:
path: "{{ one_source }}Reporter\\VeeamONE.Reporter.Server.x64.msi"
state: present
arguments: "ACCEPT_THIRDPARTY_LICENSES=1 ACCEPT_EULA=1 VM_RP_SERVICEACCOUNT={{ one_username }} VM_RP_SERVICEPASSWORD={{ one_userpassword }} VM_RP_SQL_SERVER=localhost\\VEEAMSQL2016 VM_RP_SQL_AUTHENTICATION=1 VM_RP_SQL_USER=sa VM_RP_SQL_PASSWORD={{ sql_sapassword }} VM_BACKUP_ADD_LATER=1 VM_VC_SELECTED_TYPE=2"
- name: Install ONE Reporter Web UI
win_package:
path: "{{ one_source }}Reporter\\VeeamONE.Reporter.WebUI.x64.msi"
state: present
arguments: "ACCEPT_THIRDPARTY_LICENSES=1 ACCEPT_EULA=1 VM_RP_SERVICEACCOUNT={{ one_username }} VM_RP_SERVICEPASSWORD={{ one_userpassword }} VM_RP_SQL_SERVER=localhost\\VEEAMSQL2016 VM_RP_SQL_AUTHENTICATION=1 VM_RP_SQL_USER=sa VM_RP_SQL_PASSWORD={{ sql_sapassword }}"
- name: Install ONE Monitor Client
win_package:
path: "{{ one_source }}Monitor\\VeeamONE.Monitor.Client.x64.msi"
state: present
arguments: "ACCEPT_THIRDPARTY_LICENSES=1 ACCEPT_EULA=1"
- name: Install ONE Agent
win_package:
path: "{{ one_source }}Agent\\VeeamONE.Agent.x64.msi"
state: present
arguments: "ACCEPT_THIRDPARTY_LICENSES=1 ACCEPT_EULA=1 VO_AGENT_TYPE=1 VO_BUNDLE_INSTALLATION=1 VO_AGENT_SERVICE_ACCOUNT_NAME={{ one_username }} VO_AGENT_SERVICE_ACCOUNT_PASSWORD={{ one_userpassword }}"
|
Veeam Availability Suite 10 News
Nikola Pejková has created this great list of Veeam Availability Suite 10 Blog Posts created by my Veeam Vanguard fellows:
Additional Blog Posts:
Updates
25.02.2020 - Version 0.8 of the Ansible Role
Since the publication of the blog post the Ansible Role got a few new features:
- SQL Express Setup executes in RunAs-Mode (Fix a weird behavior)
- A License File can be applied during the unattended installation
- The SQL Express installation is optional
- The SQL instance can be configured (e.g. remote SQL)
- The download task uses per default the Veeam Backup & Replication 10 ISO
- Unattended installation was tested with v10 GA
- Minor debug enhancements
Tweak for the SQL Express Setup:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
- name: SQL - Install SQL Express 2016 SP2
win_package:
path: "{{ vbr_source }}Redistr\\x64\\SqlExpress\\2016SP2\\SQLEXPR_x64_ENU.exe"
product_id: SQL 2016 Express
arguments:
- '/q'
- '/ACTION=Install'
- '/IACCEPTSQLSERVERLICENSETERMS'
- '/FEATURES=SQL'
- '/INSTANCENAME=VEEAMSQL2016'
- '/SQLSVCACCOUNT={{ sql_username }}'
- '/SQLSVCPASSWORD={{ sql_userpassword }}'
- '/SECURITYMODE=SQL'
- '/SAPWD={{ sql_sapassword }}'
- '/ADDCURRENTUSERASSQLADMIN'
- '/UPDATEENABLED=0'
- '/TCPENABLED=1'
- '/NPENABLED=1'
become: yes
become_flags: logon_type=batch
vars:
ansible_become_method: runas
ansible_become_user: "{{ vbr_username }}"
ansible_become_pass: "{{ vbr_userpassword }}"
when: sql_setup | bool
|
Thanks to jborean93: SQL Express Setup via WinRM
New Defaults file:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
|
---
# defaults file for veeam_setup
## Choose Setup
vbr_download: false
vbr_license: false
vbr_setup: false
vbr_update: false
one_setup: false
one_license: false
one_update: false
## VBR Parameters
one_source: "E:\\"
one_destination: "C:\\install\\"
one_destination_license: "license.lic"
one_source_license: "/data/license.lic"
one_username: "svc_one"
one_userpassword: "ChangeM3!"
one_update_file: "" #VeeamONE_9.5.4.4587_Update#4a.exe
one_update_id: "" #Veeam ONE Update 4a
vbr_url: "https://download2.veeam.com/VeeamBackup&Replication_10.0.0.4461.iso"
vbr_checksum: "26ddcc3df046af1ca1458b3040fc9024b4361ae1e51e1cf4516afe53fb024650"
vbr_destination: "C:\\install\\"
vbr_destination_file: "vbr.iso"
vbr_destination_license: "license.lic"
vbr_source_license: "/data/license.lic"
vbr_source: "D:\\"
vbr_username: "svc_vbr"
vbr_userpassword: "ChangeM3!"
vbr_update_file: "" #veeam_backup_9.5.4.2866.update4b_setup.exe
vbr_update_id: "" #Veeam VBR Update 4b
sql_setup: true
sql_instance: "(local)\\VEEAMSQL2016"
sql_username: "svc_sql"
sql_userpassword: "ChangeM3!"
sql_sapassword: "ChangeM3!"
|