Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.

Bug 2284095

Summary: Remove leftover OVN LB HM port upon deletion of a member
Product: Red Hat OpenStack Reporter: Fernando Royo <froyo>
Component: python-ovn-octavia-providerAssignee: Fernando Royo <froyo>
Status: CLOSED ERRATA QA Contact: Arkady Shtempler <ashtempl>
Severity: medium Docs Contact:
Priority: medium    
Version: 17.1 (Wallaby)CC: bbonguar, gregraka, gthiemon, mariel, tweining
Target Milestone: z4Keywords: Triaged
Target Release: 17.1   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: python-ovn-octavia-provider-1.0.3-17.1.20240822110754.d779786.el9ost Doc Type: Bug Fix
Doc Text:
In previous RHOSP releases, when all members of an OVN load balancer, including health monitors, were removed, the health monitor port was not deleted and remained in `ovsdb`. In RHOSP 17.1.4, all health monitor ports are properly deleted when all members are removed from an OVN load balancer, and the health monitor port is not needed by any other OVN load balancer.
Story Points: ---
Clone Of: Environment:
Last Closed: 2024-11-21 09:40:48 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 Fernando Royo 2024-05-31 08:00:41 UTC
Creating an octavia load-balancer with the ovn provider, adding a health-monitor and then members, octavia creates a neutron hm port in each subnet where a member was added.

Removing the members again, the hm ports do not get cleaned up. The hm removal then cleans up one of the hm ports, the one that is in the subnet where the vip happens to be. The others are still left and do not get cleaned up by octavia. This of course will cause issues when subnets can later not be deleted due to being still populated by the orphaned ports.
The cleanup logic simply does not match the hm port creation logic.


How reproducible:
Always

Steps to Reproduce:
1. Create a load balancer OVN provider with LB + listener + pool
2. Create a member1 from the same subnet as the LB VIP
3. Create another member2 from another subnet
4. Create a HM over the pool in step 1, at this moment we should have two ovn-lb-hm ports 
5. Delete member1 and check if ovn-lb-hm port related to subnet1 is deleted
6. Delete member2 and check if ovn-lb-hm port related to subnet2 is deleted

Actual results:
Some leftover ovn-lb-hm port keeps after deleting all members from the LB

Expected results:
After steps above no ovn-lb-hm ports should be there

Comment 16 errata-xmlrpc 2024-11-21 09:40:48 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