sap_hana_install: Inventory based Scale-Out and idempotency validations #1126
+1,744
−994
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Premise
Current workflow of
sap_hana_install
does not execute any tasks on addhosts, be it for new or existing systems, resulting in inconsistent system. All tasks are executed only on managed node, including important configuration tasks like firewall, selinux, etc.This is re-imagined alternative to open #1122 which uses
Inventory
instead ofdelegate_to
tasks, which were causing issue when installing packages on delegated hosts.Changes
This PR introduces split of role workflow into separate runner files for
Install
andAddhosts
along with range of changes:Conceptual changes
FLAG
system of variables to easily detect which host task is running on to differentiate betweenMain
host andAddhosts
.ansible_hostname
for One Host or HA installations.New features
hdblcm
.sapadm
on addhosts, because it is required whenhdblcm
is running inaddhosts
mode as it cannot useroot SSH.
/lss/shared
is mounted.--lss_user_password=
to addhosts hdblcm command as it is required now. It does not accept parameter in config file.Expected new failure states to fail fast
In order of execution:
sap_hana_install_addhosts
are defined but they do not contain valid hosts or only Master.sap_hana_install_addhosts
contains more or less hosts than hosts in play.when: inventory_hostname_short == (groups['hana_primary'] | first)
so we need to align releases!/hana/shared
is not shared filesystem/lss/shared
is not shared filesystem for SPS08Tested
This PR was tested on SLES 15 SPS 6 on AWS with following tests:
NOTE
Workflow Sanity failure for
devel
is caused by newly pushedansible-core 2.21
, because we do not have ignore file for it yet. I will fix this issue after this PR.