Skip to content
Snippets Groups Projects
Commit dac58808 authored by Michal Nasiadka's avatar Michal Nasiadka
Browse files

openvswitch: add option to set hw offload

Change-Id: I8bf5453c6943fd2ad8912e5d80af179296ada894
parent 8df6cf48
No related branches found
No related tags found
No related merge requests found
...@@ -104,3 +104,4 @@ openvswitch_vswitchd_extra_volumes: "{{ openvswitch_extra_volumes }}" ...@@ -104,3 +104,4 @@ openvswitch_vswitchd_extra_volumes: "{{ openvswitch_extra_volumes }}"
############# #############
openvswitch_system_id: "{{ ansible_facts.hostname }}" openvswitch_system_id: "{{ ansible_facts.hostname }}"
openvswitch_hw_offload: "no"
--- ---
# NOTE(mnasiadka): external_ids:system-id uniquely identifies a physical system, used by OVN and other controllers # NOTE(mnasiadka): external_ids:system-id uniquely identifies a physical system, used by OVN and other controllers
- name: Set system-id - name: Set system-id and hw-offload
become: true become: true
kolla_toolbox: kolla_toolbox:
user: root user: root
...@@ -8,10 +8,13 @@ ...@@ -8,10 +8,13 @@
module_args: module_args:
table: Open_vSwitch table: Open_vSwitch
record: . record: .
col: external_ids col: "{{ item.col }}"
key: system-id key: "{{ item.name }}"
value: "{{ openvswitch_system_id }}" value: "{{ item.value }}"
state: present state: "{{ item.state | default('present') }}"
loop:
- { col: "external_ids", name: "system-id", value: "{{ openvswitch_system_id }}" }
- { col: "other_config", name: "hw-offload", value: true, state: "{{ 'present' if openvswitch_hw_offload | bool else 'absent' }}" }
- name: Ensuring OVS bridge is properly setup - name: Ensuring OVS bridge is properly setup
become: true become: true
......
...@@ -71,6 +71,13 @@ VFs enabled: ...@@ -71,6 +71,13 @@ VFs enabled:
[sriov_nic] [sriov_nic]
exclude_devices = exclude_devices =
To use OpenvSwitch hardware offloading modify `/etc/kolla/globals.yml``:
.. path /etc/kolla/globals.yml
.. code-block:: yaml
openvswitch_hw_offload: "yes"
Run deployment. Run deployment.
Verification Verification
......
---
features:
- |
Adds functionality to enable HW offload in OpenvSwitch using
``openvswitch_hw_offload`` variable.
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment