Skip to content

Commit

Permalink
sap_hana_preconfigure: Fix check mode for largesend.conf - ppc64le
Browse files Browse the repository at this point in the history
Fixes issue #955.

Signed-off-by: Bernd Finger <bfinger@redhat.com>
  • Loading branch information
berndfinger committed Feb 5, 2025
1 parent 734b1b1 commit 092f668
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions roles/sap_hana_preconfigure/tasks/sapnote/2055470.yml
Original file line number Diff line number Diff line change
Expand Up @@ -69,16 +69,19 @@
# Note: The sole purpose of the following two tasks is to collect the current value(s) of the kernel parameters
# in '/etc/sysctl.d/ibm_largesend.conf' so that the "Reload kernel parameters from file ..." task
# can correctly report its 'changed' state. See also https://github.com/sap-linuxlab/community.sap_install/issues/752 .

- name: Construct the command for getting all current parameters of file '/etc/sysctl.d/ibm_largesend.conf'
ansible.builtin.command: awk 'BEGIN{FS="="; printf ("sysctl ")}{printf ("%s ", $1)}' /etc/sysctl.d/ibm_largesend.conf
register: __sap_hana_preconfigure_register_ibm_largesend_sysctl_command
changed_when: false
when: not ansible_check_mode

# Reason for noqa: The command module tries to run the complete string as a single command
- name: Get all currently active values of the parameters of file '/etc/sysctl.d/ibm_largesend.conf' # noqa command-instead-of-shell
ansible.builtin.shell: "{{ __sap_hana_preconfigure_register_ibm_largesend_sysctl_command.stdout }}"
register: __sap_hana_preconfigure_register_ibm_largesend_sysctl_p_output_old
changed_when: false
when: not ansible_check_mode

- name: Reload kernel parameters from file '/etc/sysctl.d/ibm_largesend.conf'
ansible.builtin.command: sysctl -p /etc/sysctl.d/ibm_largesend.conf
Expand Down

0 comments on commit 092f668

Please # to comment.