Skip to content

Commit

Permalink
Merge pull request #485 from berndfinger/issue-484
Browse files Browse the repository at this point in the history
sap_hana_install: Solve issue #484
  • Loading branch information
berndfinger authored Sep 29, 2023
2 parents 18a988d + 0c6d021 commit d5b8595
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 7 deletions.
2 changes: 1 addition & 1 deletion playbooks/vars/sample-variables-sap-hana-install.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ sap_hana_install_master_password: 'NewPass$321'

# Instance details
sap_hana_install_sid: 'HDB'
sap_hana_install_instance_number: "00"
sap_hana_install_instance_nr: "00"


# ----------------------------- Optional parameters ------------------------------ #
Expand Down
16 changes: 11 additions & 5 deletions roles/sap_hana_install/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,12 @@ The firewall ports for SAP HANA are defined in member `port` of the first field
member `state` is set to `enabled`, the ports will be enabled. If the member `state` is set to `disabled`,
the ports will be disabled, which might be useful for testing.
Certain parameters have identical meanings, for supporting different naming schemes in playbooks and inventories.
You can find those in the task `Rename some variables used by hdblcm configfile` of the file `tasks/main.yml`.
Example: The parameter `sap_hana_install_number`, which is used by the role to define the hdblm parameter `number`
(= SAP HANA instance number) can be defined by setting `sap_hana_instance_number`, `sap_hana_install_instance_nr`,
`sap_hana_install_instance_number`, or `sap_hana_install_number`. The order of precedence is from left to right.
### Default Parameters
Please check the default parameters file for more information on other parameters that can be used as an input
Expand Down Expand Up @@ -189,7 +195,7 @@ Sample Ansible Playbook Execution
sap_hana_install_software_directory: /software/hana
sap_hana_install_common_master_password: 'NewPass$321'
sap_hana_install_sid: 'H01'
sap_hana_install_instance_number: '00'
sap_hana_install_instance_nr: '00'
roles:
- sap_hana_install
```
Expand All @@ -208,7 +214,7 @@ Sample Ansible Playbook Execution
sap_hana_install_root_password: 'NewPass$321'
sap_hana_install_addhosts: 'host2:role=worker,host3:role=worker:group=g02,host4:role=standby:group=g02'
sap_hana_install_sid: 'H01'
sap_hana_install_instance_number: '00'
sap_hana_install_instance_nr: '00'
roles:
- sap_hana_install
```
Expand All @@ -228,7 +234,7 @@ Sample Ansible Playbook Execution
sap_hana_install_common_master_password: 'NewPass$321'
sap_hana_install_root_password: 'NewPass$321'
sap_hana_install_sid: 'H01'
sap_hana_install_instance_number: '00'
sap_hana_install_instance_nr: '00'
roles:
- sap_hana_install
```
Expand All @@ -242,7 +248,7 @@ You can find more complex playbooks in directory `playbooks` of the collection `
#### Perform Initial Checks

These checks are only performed if `sap_hana_install_force` is set to `true`. Its default value is `false`
- If variable `sap_hana_install_check_sidadm_user` is undefined or set to `y`: Check if user sidadm exists. If yes,
- If variable `sap_hana_install_check_sidadm_user` is undefined or set to `yes`: Check if user sidadm exists. If yes,
abort the role.

- Check if `/usr/sap/hostctrl/exe/saphostctrl` exists and get info on running HANA instances.
Expand Down Expand Up @@ -303,7 +309,7 @@ in a temporary directory for use by the hdblcm command in the next step.

- Set Log Mode key to overwrite value and apply to system.

- Apply SAP HANA license to the new deployed instance if set to `y`.
- Apply SAP HANA license to the new deployed instance if set to `yes`.

- Set expiry of Unix created users to `never`.

Expand Down
2 changes: 1 addition & 1 deletion roles/sap_hana_install/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
- name: Rename some variables used by hdblcm configfile
ansible.builtin.set_fact:
sap_hana_install_sid: "{{ sap_hana_sid | d(sap_hana_install_sid) | d('') }}"
sap_hana_install_number: "{{ sap_hana_instance_number | d(sap_hana_install_instance_number | d(sap_hana_install_number) | d('')) }}"
sap_hana_install_number: "{{ sap_hana_instance_number | d(sap_hana_install_instance_nr) | d(sap_hana_install_instance_number) | d(sap_hana_install_number) | d('') }}"
sap_hana_install_master_password: "{{ sap_hana_install_common_master_password | d(sap_hana_install_master_password) }}"
sap_hana_install_system_usage: "{{ sap_hana_install_env_type | d(sap_hana_install_system_usage) }}"
sap_hana_install_restrict_max_mem: "{{ sap_hana_install_mem_restrict | d(sap_hana_install_restrict_max_mem) }}"
Expand Down

0 comments on commit d5b8595

Please sign in to comment.