Skip to content

Commit 0407101

Browse files
Update Blog “highly-available-nfs-workload-on-hpe-greenlake-for-private-cloud-enterprise-using-serviceguard-for-linux”
1 parent 80d2cf2 commit 0407101

File tree

1 file changed

+8
-22
lines changed

1 file changed

+8
-22
lines changed

content/blog/highly-available-nfs-workload-on-hpe-greenlake-for-private-cloud-enterprise-using-serviceguard-for-linux.md

Lines changed: 8 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -67,8 +67,6 @@ terraform {
6767
}
6868
```
6969

70-
``
71-
7270
You can find out more about the HPE GreenLake Terraform provider from its Terraform Registry page:
7371

7472
https://registry.terraform.io/providers/HPE/hpegl/latest This page also provides a link to the GitHub repository corresponding to this provider.
@@ -323,17 +321,14 @@ resource "hpegl_vmaas_instance" "my_quorum" {
323321

324322
3 VMs need to be created to setup SGLX. 2 VMs will be used to create Serviceguard for Linux nodes where the NFS service will be up and running. The third VM will act as a quorum server for the Serviceguard cluster to ensure that split brain of the cluster does not impact the availability of the monitored workload.
325323

326-
327324
**Note:** You can get information about each of the resource statements supported by the hpegl provider from [GitHub](https://github.com/hpe/terraform-provider-hpegl/tree/main/docs/resources).
328325

329-
330326
**Note:** An existing Serviceguard Quorum Server in your environment can be used instead of provisioning a third VM, provided the Quorum Server is reachable to the 2 VM’s that were created.
331327

332328
### Terraform init
333329

334330
Before you can use Terraform, you need to initialize it from the configuration file we have created. This is done with the following step:
335331

336-
337332
`terraform init`
338333

339334
### Terraform ready to plan
@@ -345,7 +340,9 @@ Once you agree with the plan and confirm, you can apply the configuration.
345340

346341
The command you need to use is now:
347342

348-
`terraform apply`
343+
```shell
344+
terraform apply
345+
```
349346

350347
This will rerun the plan command, then prompt you to confirm before it starts building what is in the plan:
351348
Here is some sample output from the terraform apply command:
@@ -391,8 +388,6 @@ Checkout the stable branch. For ex: to checkout branch 1.0,
391388

392389
`git checkout Stable-v1.0`
393390

394-
``
395-
396391
To upgrade to the latest version of the playbooks:
397392

398393
`git pull https://github.com/HewlettPackard/serviceguard.git`
@@ -405,30 +400,25 @@ We should configure the version of Serviceguard to be installed, in this case SG
405400

406401
`sglx_version : 15.10.00`
407402

408-
409403
Now provide the Serviceguard for Linux ISO location on the controller node
410404

411-
```
405+
```yaml
412406
sglx_inst_upg_mode: iso
413407
sglx_inst_upg_additional_params:
414408
..
415409
iso_params:
416410
iso_location: <absolute path of the iso on ansible controller node>
417411
```
418412
419-
420-
421413
Next, install Serviceguard NFS add-on.
422414
423-
```
415+
```yaml
424416
sglx_add_on_inst_upg_params:
425417
sglx_addon: nfs
426418
```
427419
428-
429420
Serviceguard installation mandates a replicated user configuration. As part of the installation, a replicated user for Serviceguard Manager (sgmgr) is created on the hosts and the password for the same can be configured under the below parameter.
430421
431-
432422
`sglx_sgmgr_password: "{{ vault_sglx_sgmgr_password }}"`
433423

434424
Ansible vault will be used to encrypt this password, run the command as below
@@ -437,7 +427,7 @@ Ansible vault will be used to encrypt this password, run the command as below
437427

438428
The generated output must be substituted in
439429

440-
```
430+
```yaml
441431
vault_sglx_sgmgr_password: !vault |
442432
$ANSIBLE_VAULT;1.1;AES256
443433
34363834323266326237363636613833396665333061653138623431626261343064373363656165
@@ -447,13 +437,9 @@ vault_sglx_sgmgr_password: !vault |
447437
3863
448438
```
449439

450-
``
451-
452-
``
453-
454440
Once these parameters are populated, one can modify the hosts file to add the 2 VMs that were provisioned earlier where the cluster will be formed, and the quorum server that was provisioned earlier. In this case, it’s as shown below
455441

456-
```
442+
```yaml
457443
[sglx-storage-flex-add-on-hosts]
458444
drbd-0-808
459445
drbd-1-808
@@ -469,7 +455,7 @@ drbd-1-808
469455

470456
When the parameters specified above are configured, playbook `site.yml` can be run from the directory where the repository is cloned on the ansible control node.
471457

472-
```
458+
```shell
473459
cd serviceguard/ansible-sglx
474460
ansible-playbook -i hosts -v --vault-password-file <path_to_vault_password_file> site.yml
475461
```

0 commit comments

Comments
 (0)