openstack-ansible-os_neutron/templates/ovn-northd-opts.j2
Danila Balagansky d35c27bf71 Configure OVN NB and SB DB Connection probes
Allow configuration of `inactivity_probe` in Connection table in NB and
SB for new installations.

Issues, which successfully resolve by using this as a workaround:
1. https://www.mail-archive.com/ovs-discuss@openvswitch.org/msg07431.html
2. https://bugs.launchpad.net/kolla-ansible/+bug/1917484

According to the OVN ML, specifically this part [1], there is no other
way to set `inactivity_probe` other than using Connection table. And the
only valid option for it would be `0.0.0.0`, so that it could be applied
to all connections.

`ovn-ctl` forces `ovsdb-server` to look for addresses to listen on in
Connection table with `db-nb-use-remote-in-db` and
`db-sb-use-remote-in-db` options which are enabled by default.

If `db-nb-create-insecure-remote` and `db-sb-create-insecure-remote` are
set to `yes` (when `neutron_ovn_ssl` is `False`), this would result in
flooding OVN logs with `Address already in use` errors.

So we will rely on default value `no` for them from now on and only
listen on and with whatever options are provided in Connection tables.

[1] https://www.mail-archive.com/ovs-discuss@openvswitch.org/msg07476.html

Change-Id: If87cf7cfa1788d68c9a4013d7f4877692f2bb11c
2023-07-12 13:24:18 +03:00

31 lines
1.5 KiB
Django/Jinja

# {{ ansible_managed }}
# OVN cluster parameters
{{ neutron_ovn_northd_opts }}=" \
--db-nb-addr={{ ansible_host }} \
--db-sb-addr={{ ansible_host }} \
--db-nb-cluster-local-addr={{ ansible_host }} \
--db-sb-cluster-local-addr={{ ansible_host }} \
{% if leader_node %}
--db-nb-cluster-remote-addr={% for item in leader_node %}{{ item }} {% endfor %} \
--db-sb-cluster-remote-addr={% for item in leader_node %}{{ item }} {% endfor %} \
{% endif %}
--ovn-northd-nb-db={{ neutron_ovn_nb_connection }} \
--ovn-northd-sb-db={{ neutron_ovn_sb_connection }} \
{% if neutron_ovn_ssl %}
--db-nb-cluster-remote-proto=ssl \
--db-sb-cluster-remote-proto=ssl \
--db-nb-cluster-local-proto=ssl \
--db-sb-cluster-local-proto=ssl \
--ovn-northd-ssl-key={{ [neutron_ovn_conf_dir, neutron_ovn_ssl_key] | join('/') }} \
--ovn-northd-ssl-cert={{ [neutron_ovn_conf_dir, neutron_ovn_ssl_cert] | join('/') }} \
--ovn-northd-ssl-ca-cert={{ [neutron_ovn_conf_dir, neutron_ovn_ssl_ca_cert] | join('/') }} \
--ovn-nb-db-ssl-key={{ [neutron_ovn_conf_dir, neutron_ovn_ssl_key] | join('/') }} \
--ovn-nb-db-ssl-cert={{ [neutron_ovn_conf_dir, neutron_ovn_ssl_cert] | join('/') }} \
--ovn-nb-db-ssl-ca-cert={{ [neutron_ovn_conf_dir, neutron_ovn_ssl_ca_cert] | join('/') }} \
--ovn-sb-db-ssl-key={{ [neutron_ovn_conf_dir, neutron_ovn_ssl_key] | join('/') }} \
--ovn-sb-db-ssl-cert={{ [neutron_ovn_conf_dir, neutron_ovn_ssl_cert] | join('/') }} \
--ovn-sb-db-ssl-ca-cert={{ [neutron_ovn_conf_dir, neutron_ovn_ssl_ca_cert] | join('/') }} \
{% endif %}
"