Bug 2295745

Summary: [OVN] Neutron is not correctly handling the metadata port
Product: Red Hat OpenStack Reporter: Rodolfo Alonso <ralonsoh>
Component: openstack-neutronAssignee: Rodolfo Alonso <ralonsoh>
Status: CLOSED ERRATA QA Contact: Renjing Xiao <rxiao>
Severity: medium Docs Contact:
Priority: high    
Version: 17.1 (Wallaby)CC: bcafarel, bmv, chrisw, mariel, scohen
Target Milestone: z4Keywords: Triaged
Target Release: 17.1   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: openstack-neutron-18.6.1-17.1.20240822200817.85ff760.el9ost Doc Type: No Doc Update
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2024-11-21 09:41:46 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Rodolfo Alonso 2024-07-04 07:03:12 UTC
In OpenStack 17.1 we can have OVN metadata ports:
* Inherited from 16.x environments migrated to 17.1. These metadata ports have device_owner="network:dhcp"
* New metadata ports created in 17.1. These metadata ports have device_owner="network:distributed"

However, in the code sometimes we are checking this possibility [1] or we are just retrieving only the "network:distributed" ports [2].

This bug proposed to add a maintenance task, only for 17.1, that retrieves all network metadata ports ("network:dhcp"+no_dhcp_port and "network:distributed") and change the device owner of those with the former one. This task should consider the possibility of:
* Having metadata and DHCP agent ports.
* Having only new metadata ports
* Having only old ("network:dhcp") metadata ports
* Having duplicated new and old (as reported in https://bugzilla.redhat.com/show_bug.cgi?id=2293063).

[1]https://code.engineering.redhat.com/gerrit/gitweb?p=neutron.git;a=blob;f=neutron/plugins/ml2/drivers/ovn/mech_driver/ovsdb/ovn_client.py;h=9a2d24d1ef0bd17e3b4506f2d72844dacf2011fb;hb=refs/heads/rhos-17.1-trunk-patches#l2541
[2]https://code.engineering.redhat.com/gerrit/gitweb?p=neutron.git;a=blob;f=neutron/plugins/ml2/drivers/ovn/mech_driver/ovsdb/impl_idl_ovn.py;h=c2d9b0dd32e55fdf42eccba68336b9ffc802ba21;hb=refs/heads/rhos-17.1-trunk-patches#l909

Comment 15 errata-xmlrpc 2024-11-21 09:41:46 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (RHOSP 17.1.4 bug fix and enhancement advisory), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2024:9974