From 416574c8b48a342fac5c99806a227cabb1782841 Mon Sep 17 00:00:00 2001 From: Bartosz Bezak Date: Thu, 8 Aug 2024 11:35:03 +0000 Subject: [PATCH] Restart OVS container after hw-offload change OpenvSwitch container needs to be restarted for hw offload to be enabled/disabled properly [1]. OpenvSwitch container will also be restarted when system-id or hostname changes. Closes-Bug: #2076335 [1] https://docs.openstack.org/neutron/2024.1/admin/config-ovs-offload.html#configure-open-vswitch-hardware-offloading Change-Id: I444fc345e5d21ed969f48aa9a6230905cc411149 --- ansible/roles/openvswitch/tasks/post-config.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/ansible/roles/openvswitch/tasks/post-config.yml b/ansible/roles/openvswitch/tasks/post-config.yml index e2d92a545c..274183f7b1 100644 --- a/ansible/roles/openvswitch/tasks/post-config.yml +++ b/ansible/roles/openvswitch/tasks/post-config.yml @@ -1,6 +1,6 @@ --- # NOTE(mnasiadka): external_ids:system-id uniquely identifies a physical system, used by OVN and other controllers -- name: Set system-id and hw-offload +- name: Set system-id, hostname and hw-offload become: true kolla_toolbox: container_engine: "{{ kolla_container_engine }}" @@ -19,6 +19,8 @@ - { col: "other_config", name: "hw-offload", value: true, state: "{{ 'present' if openvswitch_hw_offload | bool else 'absent' }}" } when: - openvswitch_services['openvswitch-vswitchd'].host_in_groups | bool + notify: + - "Restart openvswitch-vswitchd container" - name: Ensuring OVS bridge is properly setup become: true