From c8c28c8589091e8a65d3c60e17dfeb6e4c99c302 Mon Sep 17 00:00:00 2001 From: Peter Mikus Date: Mon, 17 Feb 2020 08:42:16 +0000 Subject: Fix: Ansible minor bugs Signed-off-by: Peter Mikus Change-Id: I804e78c3b8586dc9e9ca8b7cf4bf97d3744aeedc --- .../testbed-setup/ansible/roles/mellanox/tasks/main.yaml | 10 +++++----- .../ansible/roles/performance_tuning/defaults/main.yaml | 4 ++-- .../ansible/roles/performance_tuning/handlers/main.yaml | 10 +++++----- .../ansible/roles/performance_tuning/tasks/main.yaml | 2 +- .../testbed-setup/ansible/roles/vexx_hosts/tasks/main.yaml | 13 ------------- 5 files changed, 13 insertions(+), 26 deletions(-) (limited to 'resources/tools/testbed-setup/ansible/roles') diff --git a/resources/tools/testbed-setup/ansible/roles/mellanox/tasks/main.yaml b/resources/tools/testbed-setup/ansible/roles/mellanox/tasks/main.yaml index 0971a1a192..030cf59b66 100644 --- a/resources/tools/testbed-setup/ansible/roles/mellanox/tasks/main.yaml +++ b/resources/tools/testbed-setup/ansible/roles/mellanox/tasks/main.yaml @@ -11,8 +11,8 @@ - name: Mellanox Install - Get OFED get_url: - url: "http://content.mellanox.com/ofed/MLNX_OFED-{{ mellanox.version }}/MLNX_OFED_LINUX-{{ mellanox.version }}-{{ ansible_distribution|lower }}{{ ansible_distribution_version }}-{{ ansible_machine }}.tgz" - dest: "/opt/MLNX_OFED_LINUX-{{ mellanox.version }}-{{ ansible_distribution|lower }}{{ ansible_distribution_version }}-{{ ansible_machine }}.tgz" + url: "http://content.mellanox.com/ofed/MLNX_OFED-{{ mellanox_version }}/MLNX_OFED_LINUX-{{ mellanox_version }}-{{ ansible_distribution|lower }}{{ ansible_distribution_version }}-{{ ansible_machine }}.tgz" + dest: "/opt/MLNX_OFED_LINUX-{{ mellanox_version }}-{{ ansible_distribution|lower }}{{ ansible_distribution_version }}-{{ ansible_machine }}.tgz" mode: 0644 when: mellanox_pcis.stdout_lines | length > 0 tags: @@ -21,9 +21,9 @@ - name: Mellanox Install - Extract OFED unarchive: remote_src: true - src: "/opt/MLNX_OFED_LINUX-{{ mellanox.version }}-{{ ansible_distribution|lower }}{{ ansible_distribution_version }}-{{ ansible_machine }}.tgz" + src: "/opt/MLNX_OFED_LINUX-{{ mellanox_version }}-{{ ansible_distribution|lower }}{{ ansible_distribution_version }}-{{ ansible_machine }}.tgz" dest: "/opt/" - creates: "/opt/MLNX_OFED_LINUX-{{ mellanox.version }}-{{ ansible_distribution|lower }}{{ ansible_distribution_version }}-{{ ansible_machine }}" + creates: "/opt/MLNX_OFED_LINUX-{{ mellanox_version }}-{{ ansible_distribution|lower }}{{ ansible_distribution_version }}-{{ ansible_machine }}" register: mellanox_firmware_extracted when: mellanox_pcis.stdout_lines | length > 0 tags: @@ -32,7 +32,7 @@ - name: Mellanox Install - Install OFED command: "./mlnxofedinstall --with-mft --dpdk --force --upstream-libs" args: - chdir: "/opt/MLNX_OFED_LINUX-{{ mellanox.version }}-{{ ansible_distribution|lower }}{{ ansible_distribution_version }}-{{ ansible_machine }}" + chdir: "/opt/MLNX_OFED_LINUX-{{ mellanox_version }}-{{ ansible_distribution|lower }}{{ ansible_distribution_version }}-{{ ansible_machine }}" when: mellanox_pcis.stdout_lines | length > 0 and mellanox_firmware_extracted tags: - install-mellanox diff --git a/resources/tools/testbed-setup/ansible/roles/performance_tuning/defaults/main.yaml b/resources/tools/testbed-setup/ansible/roles/performance_tuning/defaults/main.yaml index 60c16a9915..edec57aba0 100644 --- a/resources/tools/testbed-setup/ansible/roles/performance_tuning/defaults/main.yaml +++ b/resources/tools/testbed-setup/ansible/roles/performance_tuning/defaults/main.yaml @@ -18,6 +18,6 @@ packages_by_arch: grub_cmdline_linux: aarch64: - - 'GRUB_CMDLINE_LINUX="isolcpus={{ grub.isolcpus }} nohz_full={{ grub.nohz_full }} rcu_nocbs={{ grub.rcu_nocbs }} intel_iommu=on nmi_watchdog=0 audit=0 nosoftlockup processor.max_cstate=1"' + - "GRUB_CMDLINE_LINUX=\"isolcpus={{ grub.isolcpus }} nohz_full={{ grub.nohz_full }} rcu_nocbs={{ grub.rcu_nocbs }} intel_iommu=on nmi_watchdog=0 audit=0 nosoftlockup processor.max_cstate=1\"" x86_64: - - 'GRUB_CMDLINE_LINUX="isolcpus={{ grub.isolcpus }} nohz_full={{ grub.nohz_full }} rcu_nocbs={{ grub.rcu_nocbs }} numa_balancing=disable intel_pstate=disable intel_iommu=on iommu=pt nmi_watchdog=0 audit=0 nosoftlockup processor.max_cstate=1 intel_idle.max_cstate=1 hpet=disable tsc=reliable mce=off"' + - "GRUB_CMDLINE_LINUX=\"isolcpus={{ grub.isolcpus }} nohz_full={{ grub.nohz_full }} rcu_nocbs={{ grub.rcu_nocbs }} numa_balancing=disable intel_pstate=disable intel_iommu=on iommu=pt nmi_watchdog=0 audit=0 nosoftlockup processor.max_cstate=1 intel_idle.max_cstate=1 hpet=disable tsc=reliable mce=off\"" diff --git a/resources/tools/testbed-setup/ansible/roles/performance_tuning/handlers/main.yaml b/resources/tools/testbed-setup/ansible/roles/performance_tuning/handlers/main.yaml index 917856b7a0..fa2876b7ac 100644 --- a/resources/tools/testbed-setup/ansible/roles/performance_tuning/handlers/main.yaml +++ b/resources/tools/testbed-setup/ansible/roles/performance_tuning/handlers/main.yaml @@ -1,13 +1,13 @@ --- # file roles/performance_tuning/handlers/main.yaml +- name: Update GRUB + command: update-grub + tags: + - update-grub + - name: Reboot server reboot: reboot_timeout: 3600 tags: - reboot-server - -- name: Update GRUB - command: update-grub - tags: - - update-grub diff --git a/resources/tools/testbed-setup/ansible/roles/performance_tuning/tasks/main.yaml b/resources/tools/testbed-setup/ansible/roles/performance_tuning/tasks/main.yaml index 9fedd27160..e28f9ba6a2 100644 --- a/resources/tools/testbed-setup/ansible/roles/performance_tuning/tasks/main.yaml +++ b/resources/tools/testbed-setup/ansible/roles/performance_tuning/tasks/main.yaml @@ -14,7 +14,7 @@ path: "/etc/default/grub" state: "present" regexp: "^GRUB_CMDLINE_LINUX=" - line: "{{ grub_cmdline_linux[ansible_machine] }}" + line: "{{ grub_cmdline_linux[ansible_machine] | join() }}" notify: - "Update GRUB" - "Reboot server" diff --git a/resources/tools/testbed-setup/ansible/roles/vexx_hosts/tasks/main.yaml b/resources/tools/testbed-setup/ansible/roles/vexx_hosts/tasks/main.yaml index a8aa57323b..decda18649 100644 --- a/resources/tools/testbed-setup/ansible/roles/vexx_hosts/tasks/main.yaml +++ b/resources/tools/testbed-setup/ansible/roles/vexx_hosts/tasks/main.yaml @@ -16,7 +16,6 @@ gateway: "{{ ansible_default_ipv4.gateway }}" profile: "{{ cobbler_profile }}" name_servers: "{{ name_servers }}" - name_servers_search: "{{ name_servers_search }}" kickstart: "/var/lib/cobbler/kickstarts/{{ cobbler_profile }}.seed" kernel_options: '"interface={{ ansible_default_ipv4.interface }}"' netboot_enabled: yes @@ -47,15 +46,3 @@ - cobbler-include - meta: flush_handlers - -- name: Copy netplan network config file - template: - src: "files/netplan_config" - dest: "/etc/netplan/01-netcfg.yaml" - owner: "root" - group: "root" - mode: "0644" - tags: - - copy-interface-file - -- meta: flush_handlers -- cgit 1.2.3-korg