neutron-ovn-db-sync error during generate OVN DB

Bug #1939726 reported by Son Do Xuan
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
neutron
Fix Released
Undecided
Rodolfo Alonso

Bug Description

I have deployed Openstack Victoria from kolla-ansible tool and Openvswich OVN for networking. neutron-ovn-db-sync tool generate OVN DB error when any subnet (disable dhcp) has allocated all available IP address. Because neutron-ovn-db-sync tool trying recreate port "network:distributed".

--------------------
2021-07-23 14:19:47.295 1417 INFO neutron.plugins.ml2.drivers.ovn.mech_driver.ovsdb.extensions.qos [req-8fb77747-70c7-459c-bab8-97dbe07a8eba - - - - -] Starting OVNClientQosExtension
2021-07-23 14:19:47.296 1417 INFO neutron.cmd.ovn.neutron_ovn_db_sync_util [req-8fb77747-70c7-459c-bab8-97dbe07a8eba - - - - -] Sync for Northbound db started with mode : repair
2021-07-23 14:19:55.231 1417 CRITICAL neutron_ovn_db_sync_util [req-8fb77747-70c7-459c-bab8-97dbe07a8eba - - - - -] Unhandled error: neutron_lib.exceptions.IpAddressGenerationFailure: No more IP addresses available on network 15b718eb-4589-4b9f-8b95-aa5dc71da538.
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util Traceback (most recent call last):
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/lib/python3.8/site-packages/neutron/db/ipam_pluggable_backend.py", line 138, in _ipam_allocate_ips
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util ip_address, subnet_id = ipam_allocator.allocate(ip_request)
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/lib/python3.8/site-packages/neutron/ipam/subnet_alloc.py", line 240, in allocate
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util raise ipam_exc.IpAddressGenerationFailureAllSubnets()
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util neutron.ipam.exceptions.IpAddressGenerationFailureAllSubnets: No more IP addresses available.
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util During handling of the above exception, another exception occurred:
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util Traceback (most recent call last):
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/bin/neutron-ovn-db-sync-util", line 8, in <module>
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util sys.exit(main())
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/lib/python3.8/site-packages/neutron/cmd/ovn/neutron_ovn_db_sync_util.py", line 229, in main
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util synchronizer.do_sync()
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/lib/python3.8/site-packages/neutron/plugins/ml2/drivers/ovn/mech_driver/ovsdb/ovn_db_sync.py", line 101, in do_sync
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util self.sync_networks_ports_and_dhcp_opts(ctx)
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/lib/python3.8/site-packages/neutron/plugins/ml2/drivers/ovn/mech_driver/ovsdb/ovn_db_sync.py", line 987, in sync_networks_ports_and_dhcp_opts
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util self._sync_metadata_ports(ctx, db_ports)
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/lib/python3.8/site-packages/neutron/plugins/ml2/drivers/ovn/mech_driver/ovsdb/ovn_db_sync.py", line 912, in _sync_metadata_ports
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util self._ovn_client.update_metadata_port(ctx, net['id'])
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/lib/python3.8/site-packages/neutron/plugins/ml2/drivers/ovn/mech_driver/ovsdb/ovn_client.py", line 2155, in update_metadata_port
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util update_metadata_port_fixed_ips(metadata_port,
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/lib/python3.8/site-packages/neutron/plugins/ml2/drivers/ovn/mech_driver/ovsdb/ovn_client.py", line 2122, in update_metadata_port_fixed_ips
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util self._plugin.update_port(n_context.get_admin_context(),
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/lib/python3.8/site-packages/neutron/common/utils.py", line 687, in inner
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util return f(self, context, *args, **kwargs)
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/lib/python3.8/site-packages/neutron_lib/db/api.py", line 233, in wrapped
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util return method(*args, **kwargs)
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/lib/python3.8/site-packages/neutron_lib/db/api.py", line 139, in wrapped
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util setattr(e, '_RETRY_EXCEEDED', True)
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/lib/python3.8/site-packages/oslo_utils/excutils.py", line 220, in __exit__
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util self.force_reraise()
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/lib/python3.8/site-packages/oslo_utils/excutils.py", line 196, in force_reraise
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util six.reraise(self.type_, self.value, self.tb)
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/usr/local/lib/python3.8/dist-packages/six.py", line 703, in reraise
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util raise value
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/lib/python3.8/site-packages/neutron_lib/db/api.py", line 135, in wrapped
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util return f(*args, **kwargs)
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/lib/python3.8/site-packages/oslo_db/api.py", line 154, in wrapper
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util ectxt.value = e.inner_exc
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/lib/python3.8/site-packages/oslo_utils/excutils.py", line 220, in __exit__
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util self.force_reraise()
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/lib/python3.8/site-packages/oslo_utils/excutils.py", line 196, in force_reraise
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util six.reraise(self.type_, self.value, self.tb)
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/usr/local/lib/python3.8/dist-packages/six.py", line 703, in reraise
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util raise value
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/lib/python3.8/site-packages/oslo_db/api.py", line 142, in wrapper
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util return f(*args, **kwargs)
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/lib/python3.8/site-packages/neutron_lib/db/api.py", line 183, in wrapped
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util LOG.debug("Retry wrapper got retriable exception: %s", e)
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/lib/python3.8/site-packages/oslo_utils/excutils.py", line 220, in __exit__
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util self.force_reraise()
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/lib/python3.8/site-packages/oslo_utils/excutils.py", line 196, in force_reraise
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util six.reraise(self.type_, self.value, self.tb)
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/usr/local/lib/python3.8/dist-packages/six.py", line 703, in reraise
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util raise value
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/lib/python3.8/site-packages/neutron_lib/db/api.py", line 179, in wrapped
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util return f(*dup_args, **dup_kwargs)
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/lib/python3.8/site-packages/neutron/plugins/ml2/plugin.py", line 1653, in update_port
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util updated_port = super(Ml2Plugin, self).update_port(context, id,
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/lib/python3.8/site-packages/neutron_lib/db/api.py", line 233, in wrapped
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util return method(*args, **kwargs)
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/lib/python3.8/site-packages/neutron/db/db_base_plugin_v2.py", line 1482, in update_port
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util self.ipam.update_port(
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/lib/python3.8/site-packages/neutron/db/ipam_backend_mixin.py", line 711, in update_port
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util changes = self.update_port_with_ips(context,
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/lib/python3.8/site-packages/neutron/db/ipam_pluggable_backend.py", line 427, in update_port_with_ips
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util changes = self._update_ips_for_port(context,
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/lib/python3.8/site-packages/neutron/db/ipam_pluggable_backend.py", line 381, in _update_ips_for_port
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util added = self._ipam_allocate_ips(context, ipam_driver,
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/lib/python3.8/site-packages/neutron/db/ipam_pluggable_backend.py", line 148, in _ipam_allocate_ips
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util return
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/lib/python3.8/site-packages/oslo_utils/excutils.py", line 220, in __exit__
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util self.force_reraise()
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/lib/python3.8/site-packages/oslo_utils/excutils.py", line 196, in force_reraise
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util six.reraise(self.type_, self.value, self.tb)
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/usr/local/lib/python3.8/dist-packages/six.py", line 703, in reraise
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util raise value
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util File "/var/lib/kolla/venv/lib/python3.8/site-packages/neutron/db/ipam_pluggable_backend.py", line 140, in _ipam_allocate_ips
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util raise n_exc.IpAddressGenerationFailure(
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util neutron_lib.exceptions.IpAddressGenerationFailure: No more IP addresses available on network 15b718eb-4589-4b9f-8b95-aa5dc71da538.
2021-07-23 14:19:55.231 1417 ERROR neutron_ovn_db_sync_util

--------------------

Son Do Xuan (sondx25)
summary: - neutron-ovn-db-sync error when system have a subnet
+ neutron-ovn-db-sync error
summary: - neutron-ovn-db-sync error
+ neutron-ovn-db-sync error during generate OVN DB
Revision history for this message
Miguel Lavalle (minsel) wrote :

Shouldn't you increase your subnet's IP range?

Changed in neutron:
status: New → Incomplete
Revision history for this message
Duy (duynkt) wrote :

The problem occured when we have 1 subnet /30 and all port was allocated --> sync error with above message.
We workaround, remove 1 port in that subnet and Sync OK.

Revision history for this message
Duy (duynkt) wrote :

The subnet on our customer's project. We need the agreement and working as a cloud provider, we can't change on user's subnets.
Any information so far?

Revision history for this message
Miguel Lavalle (minsel) wrote :

So, you are not attempting to allocate a new ip address from that subnet?

Changed in neutron:
status: Incomplete → New
tags: added: ovn
tags: added: l3-ipam-dhcp
Revision history for this message
Jakub Libosvar (libosvar) wrote :

Is the traceback from the description full TB? I can't tell from where the call to ipam from db sync is. Could you please add the full TB?

Revision history for this message
Son Do Xuan (sondx25) wrote :

@libosvar
Sorry for the incomplete description. I have edited my description above.

description: updated
Revision history for this message
Rodolfo Alonso (rodolfo-alonso-hernandez) wrote :

Hello:

I think there is a problem in the "_sync_metadata_ports" method, in [1]. If the subnet has DHCP disabled, the metadata port should not receive an IP address from this subnet. When a subnet without DHCP is created, the metadata port (already there because is created when the network is), does not receive any IP address.

We should make this check at this point too: if the subnet has "dhcp_enbled" to False, then we should update the port IPs but deleting, if exist, any IP address on this subnet (just the opposite of what is happening now).

Regards.

[1]https://github.com/openstack/neutron/blob/bd7b40b4f871586068039e6014dbb9081d1630e8/neutron/plugins/ml2/drivers/ovn/mech_driver/ovsdb/ovn_client.py#L2230-L2232

Changed in neutron:
assignee: nobody → Rodolfo Alonso (rodolfo-alonso-hernandez)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to neutron (master)

Fix proposed to branch: master
Review: https://review.opendev.org/c/openstack/neutron/+/811996

Changed in neutron:
status: New → In Progress
Revision history for this message
Rodolfo Alonso (rodolfo-alonso-hernandez) wrote :
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to neutron (master)

Reviewed: https://review.opendev.org/c/openstack/neutron/+/811996
Committed: https://opendev.org/openstack/neutron/commit/5e32dddc11c6ec73afc83d2bfc7c4beaa252de0c
Submitter: "Zuul (22348)"
Branch: master

commit 5e32dddc11c6ec73afc83d2bfc7c4beaa252de0c
Author: Rodolfo Alonso Hernandez <email address hidden>
Date: Thu Sep 30 16:28:19 2021 +0000

    Fix "_sync_metadata_ports" with no DHCP subnets

    When a subnet does not have DHCP configured, the metadata port does
    not have an IP address on this CIDR. The method
    "OvnNbSynchronizer.sync_networks_ports_and_dhcp_opts", was always
    setting an IP address for the metadata ports, regardless of the subnet
    configuration (with or without DHCP).

    The method "_sync_metadata_ports", in charge of synchronizing the
    metadata ports, now filters the subnets by the parameter "enable_dhcp".

    In case of having a subnet with DHCP enabled, if the metadata port is
    missing the subnet IP addresses, the method adds them.

    In case of having a subnet without DHCP enabled, if the metadata port
    has an IP address on the subnet, the method removes it.

    Closes-Bug: #1939726
    Change-Id: I09cc14dff6933aae63cbd43a29f9221f405ecede

Changed in neutron:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to neutron (stable/xena)

Fix proposed to branch: stable/xena
Review: https://review.opendev.org/c/openstack/neutron/+/812334

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to neutron (stable/wallaby)

Fix proposed to branch: stable/wallaby
Review: https://review.opendev.org/c/openstack/neutron/+/812335

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to neutron (stable/victoria)

Fix proposed to branch: stable/victoria
Review: https://review.opendev.org/c/openstack/neutron/+/812336

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to neutron (stable/ussuri)

Fix proposed to branch: stable/ussuri
Review: https://review.opendev.org/c/openstack/neutron/+/812337

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to neutron (stable/wallaby)

Reviewed: https://review.opendev.org/c/openstack/neutron/+/812335
Committed: https://opendev.org/openstack/neutron/commit/fe9e596d3e8c28801093adfd6fb50d6f8786142d
Submitter: "Zuul (22348)"
Branch: stable/wallaby

commit fe9e596d3e8c28801093adfd6fb50d6f8786142d
Author: Rodolfo Alonso Hernandez <email address hidden>
Date: Thu Sep 30 16:28:19 2021 +0000

    Fix "_sync_metadata_ports" with no DHCP subnets

    When a subnet does not have DHCP configured, the metadata port does
    not have an IP address on this CIDR. The method
    "OvnNbSynchronizer.sync_networks_ports_and_dhcp_opts", was always
    setting an IP address for the metadata ports, regardless of the subnet
    configuration (with or without DHCP).

    The method "_sync_metadata_ports", in charge of synchronizing the
    metadata ports, now filters the subnets by the parameter "enable_dhcp".

    In case of having a subnet with DHCP enabled, if the metadata port is
    missing the subnet IP addresses, the method adds them.

    In case of having a subnet without DHCP enabled, if the metadata port
    has an IP address on the subnet, the method removes it.

    Closes-Bug: #1939726

    Conflicts:
        neutron/plugins/ml2/drivers/ovn/mech_driver/ovsdb/ovn_client.py

    Change-Id: I09cc14dff6933aae63cbd43a29f9221f405ecede
    (cherry picked from commit 5e32dddc11c6ec73afc83d2bfc7c4beaa252de0c)

tags: added: in-stable-wallaby
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to neutron (stable/victoria)

Reviewed: https://review.opendev.org/c/openstack/neutron/+/812336
Committed: https://opendev.org/openstack/neutron/commit/992496c8b5d8dac26c60cfe44e8e493e65b422bb
Submitter: "Zuul (22348)"
Branch: stable/victoria

commit 992496c8b5d8dac26c60cfe44e8e493e65b422bb
Author: Rodolfo Alonso Hernandez <email address hidden>
Date: Thu Sep 30 16:28:19 2021 +0000

    Fix "_sync_metadata_ports" with no DHCP subnets

    When a subnet does not have DHCP configured, the metadata port does
    not have an IP address on this CIDR. The method
    "OvnNbSynchronizer.sync_networks_ports_and_dhcp_opts", was always
    setting an IP address for the metadata ports, regardless of the subnet
    configuration (with or without DHCP).

    The method "_sync_metadata_ports", in charge of synchronizing the
    metadata ports, now filters the subnets by the parameter "enable_dhcp".

    In case of having a subnet with DHCP enabled, if the metadata port is
    missing the subnet IP addresses, the method adds them.

    In case of having a subnet without DHCP enabled, if the metadata port
    has an IP address on the subnet, the method removes it.

    Closes-Bug: #1939726

    Conflicts:
        neutron/plugins/ml2/drivers/ovn/mech_driver/ovsdb/ovn_client.py

    Change-Id: I09cc14dff6933aae63cbd43a29f9221f405ecede
    (cherry picked from commit 5e32dddc11c6ec73afc83d2bfc7c4beaa252de0c)
    (cherry picked from commit fe9e596d3e8c28801093adfd6fb50d6f8786142d)

tags: added: in-stable-victoria
tags: added: in-stable-ussuri
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to neutron (stable/ussuri)

Reviewed: https://review.opendev.org/c/openstack/neutron/+/812337
Committed: https://opendev.org/openstack/neutron/commit/ba80c87ceed0c7b5ab3f10d509f542f99d4e1a15
Submitter: "Zuul (22348)"
Branch: stable/ussuri

commit ba80c87ceed0c7b5ab3f10d509f542f99d4e1a15
Author: Rodolfo Alonso Hernandez <email address hidden>
Date: Thu Sep 30 16:28:19 2021 +0000

    Fix "_sync_metadata_ports" with no DHCP subnets

    When a subnet does not have DHCP configured, the metadata port does
    not have an IP address on this CIDR. The method
    "OvnNbSynchronizer.sync_networks_ports_and_dhcp_opts", was always
    setting an IP address for the metadata ports, regardless of the subnet
    configuration (with or without DHCP).

    The method "_sync_metadata_ports", in charge of synchronizing the
    metadata ports, now filters the subnets by the parameter "enable_dhcp".

    In case of having a subnet with DHCP enabled, if the metadata port is
    missing the subnet IP addresses, the method adds them.

    In case of having a subnet without DHCP enabled, if the metadata port
    has an IP address on the subnet, the method removes it.

    Closes-Bug: #1939726

    Conflicts:
        neutron/plugins/ml2/drivers/ovn/mech_driver/ovsdb/ovn_client.py

    Change-Id: I09cc14dff6933aae63cbd43a29f9221f405ecede
    (cherry picked from commit 5e32dddc11c6ec73afc83d2bfc7c4beaa252de0c)
    (cherry picked from commit fe9e596d3e8c28801093adfd6fb50d6f8786142d)

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to neutron (stable/xena)

Reviewed: https://review.opendev.org/c/openstack/neutron/+/812334
Committed: https://opendev.org/openstack/neutron/commit/8701c462252296e76f57afb727f6ba557d0010b5
Submitter: "Zuul (22348)"
Branch: stable/xena

commit 8701c462252296e76f57afb727f6ba557d0010b5
Author: Rodolfo Alonso Hernandez <email address hidden>
Date: Thu Sep 30 16:28:19 2021 +0000

    Fix "_sync_metadata_ports" with no DHCP subnets

    When a subnet does not have DHCP configured, the metadata port does
    not have an IP address on this CIDR. The method
    "OvnNbSynchronizer.sync_networks_ports_and_dhcp_opts", was always
    setting an IP address for the metadata ports, regardless of the subnet
    configuration (with or without DHCP).

    The method "_sync_metadata_ports", in charge of synchronizing the
    metadata ports, now filters the subnets by the parameter "enable_dhcp".

    In case of having a subnet with DHCP enabled, if the metadata port is
    missing the subnet IP addresses, the method adds them.

    In case of having a subnet without DHCP enabled, if the metadata port
    has an IP address on the subnet, the method removes it.

    Closes-Bug: #1939726
    Change-Id: I09cc14dff6933aae63cbd43a29f9221f405ecede
    (cherry picked from commit 5e32dddc11c6ec73afc83d2bfc7c4beaa252de0c)

tags: added: in-stable-xena
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/neutron 16.4.2

This issue was fixed in the openstack/neutron 16.4.2 release.

tags: added: neutron-proactive-backport-potential
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/neutron 19.1.0

This issue was fixed in the openstack/neutron 19.1.0 release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/neutron 17.3.0

This issue was fixed in the openstack/neutron 17.3.0 release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/neutron 18.2.0

This issue was fixed in the openstack/neutron 18.2.0 release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/neutron 20.0.0.0rc1

This issue was fixed in the openstack/neutron 20.0.0.0rc1 release candidate.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/networking-ovn train-eol

This issue was fixed in the openstack/networking-ovn train-eol release.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.