From bddb498aab2517c4d02e9ed16371000b6700afe3 Mon Sep 17 00:00:00 2001 From: Mark Goddard Date: Fri, 12 Apr 2024 10:17:19 +0100 Subject: [PATCH 1/2] Fix Dell OS6 and Dell OS9 switch configuration Previously the dellos6_config and dellos9_config modules accepted the name of a template file as their 'src' parameter, or a string containing the actual config. Now they only accept the config string. Kayobe passes the name of a template file, resulting in a strange error from the switch about an invalid command dellos6-config.j2 or dellos9-config.j2. This change fixes the issue in the same way it was fixed for Dell OS10 switches, by using the template lookup plugin to evaluate the config file template. Change-Id: Ic14e2b75c785b4db03b5e659e5a2be2ee83eace3 Closes-Bug: #2061102 (cherry picked from commit 67f09241e07b3119bb17ed59df2b40aa3c9dced9) --- ansible/roles/dell-switch/tasks/main.yml | 4 ++-- releasenotes/notes/bug-2061102-cbc4c65c14c09d55.yaml | 6 ++++++ 2 files changed, 8 insertions(+), 2 deletions(-) create mode 100644 releasenotes/notes/bug-2061102-cbc4c65c14c09d55.yaml diff --git a/ansible/roles/dell-switch/tasks/main.yml b/ansible/roles/dell-switch/tasks/main.yml index 07fd3d923..39aead5e3 100644 --- a/ansible/roles/dell-switch/tasks/main.yml +++ b/ansible/roles/dell-switch/tasks/main.yml @@ -3,14 +3,14 @@ local_action: module: dellos6_config provider: "{{ dell_switch_provider }}" - src: dellos6-config.j2 + src: "{{ lookup('template', 'dellos6-config.j2') }}" when: dell_switch_type == 'dellos6' - name: Ensure DellOS9 switches are configured local_action: module: dellos9_config provider: "{{ dell_switch_provider }}" - src: dellos9-config.j2 + src: "{{ lookup('template', 'dellos9-config.j2') }}" when: dell_switch_type == 'dellos9' - name: Ensure DellOS10 switches are configured diff --git a/releasenotes/notes/bug-2061102-cbc4c65c14c09d55.yaml b/releasenotes/notes/bug-2061102-cbc4c65c14c09d55.yaml new file mode 100644 index 000000000..e14931bac --- /dev/null +++ b/releasenotes/notes/bug-2061102-cbc4c65c14c09d55.yaml @@ -0,0 +1,6 @@ +--- +fixes: + - | + Fixes an issue where Dell OS6 and Dell OS9 switch configuration was not + applied correctly. `LP#2061102 + `__. From cbb9a22f82baaf9a04593dfa435d5288cb4f856a Mon Sep 17 00:00:00 2001 From: Will Szumski Date: Tue, 20 Feb 2024 15:30:56 +0000 Subject: [PATCH 2/2] Fix issue removing docker volumes The error response from the docker daemon has changed to: Error response from daemon: get opensm_logs: no such volume This change should support both old and new responses. Change-Id: Ibef1713d7de2e0a2c6fe046f607b2a8e60dae3da Closes-Bug: #2050092 (cherry picked from commit 27ece2622b934eb6f4d9712d1879ac9bab8d236e) --- ansible/roles/docker-registry/tasks/destroy.yml | 2 +- ansible/roles/inspection-store/tasks/destroy.yml | 2 +- ansible/roles/opensm/tasks/destroy.yml | 2 +- ...oud-service-destroy-volume-cleanup-4b54d81cde9831c7.yaml | 6 ++++++ 4 files changed, 9 insertions(+), 3 deletions(-) create mode 100644 releasenotes/notes/fix-issue-overcloud-service-destroy-volume-cleanup-4b54d81cde9831c7.yaml diff --git a/ansible/roles/docker-registry/tasks/destroy.yml b/ansible/roles/docker-registry/tasks/destroy.yml index 1d3992ab3..7cd02af9b 100644 --- a/ansible/roles/docker-registry/tasks/destroy.yml +++ b/ansible/roles/docker-registry/tasks/destroy.yml @@ -14,7 +14,7 @@ when: "'/' not in volume" failed_when: - volume_result.rc != 0 - - "'No such volume' not in volume_result.stderr" + - "'no such volume' not in volume_result.stderr | lower" vars: volume: "{{ item.1.split(':')[0] }}" register: volume_result diff --git a/ansible/roles/inspection-store/tasks/destroy.yml b/ansible/roles/inspection-store/tasks/destroy.yml index 8bcd7a5d9..c0d5ade04 100644 --- a/ansible/roles/inspection-store/tasks/destroy.yml +++ b/ansible/roles/inspection-store/tasks/destroy.yml @@ -14,7 +14,7 @@ when: "'/' not in volume" failed_when: - volume_result.rc != 0 - - "'No such volume' not in volume_result.stderr" + - "'no such volume' not in volume_result.stderr | lower" vars: volume: "{{ item.1.split(':')[0] }}" register: volume_result diff --git a/ansible/roles/opensm/tasks/destroy.yml b/ansible/roles/opensm/tasks/destroy.yml index 9302a6186..c627d0663 100644 --- a/ansible/roles/opensm/tasks/destroy.yml +++ b/ansible/roles/opensm/tasks/destroy.yml @@ -14,7 +14,7 @@ when: "'/' not in volume" failed_when: - volume_result.rc != 0 - - "'No such volume' not in volume_result.stderr" + - "'no such volume' not in volume_result.stderr | lower" vars: volume: "{{ item.1.split(':')[0] }}" register: volume_result diff --git a/releasenotes/notes/fix-issue-overcloud-service-destroy-volume-cleanup-4b54d81cde9831c7.yaml b/releasenotes/notes/fix-issue-overcloud-service-destroy-volume-cleanup-4b54d81cde9831c7.yaml new file mode 100644 index 000000000..c24718478 --- /dev/null +++ b/releasenotes/notes/fix-issue-overcloud-service-destroy-volume-cleanup-4b54d81cde9831c7.yaml @@ -0,0 +1,6 @@ +--- +fixes: + - | + Fixes an issue with overcloud service destroy where it failed to remove the + inspection store docker volume. See `LP#2050092 + `__.