[OVN] orphaned virtual parent ports break new ports
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
neutron |
New
|
Medium
|
Unassigned |
Bug Description
Reproducible on stable/yoga.
Should the ovn port deletion fail due to backend (mariadb or ovn) connection failure, leftover switchports are left hanging in the OVN NB db.
oslo_db.
[SQL: DELETE FROM securitygrouppo
[parameters: {'port_id': '76ff3324-
neutron/
Such ports are detected by maintenance task, but only reported as warnings in logs:
neutron/
When neutron tries to create a new port for nova instance in the same network and the IP address of the new port matches the IP of the orphaned virtual-parent, neutron binds the new port's virtual switchport to the orphan but fails to proceed with binding algorithms, resulting in a perpetually-DOWN port.
For example, here is OVN-side body of a new virtual port, that has failed to bind to compute:
addresses : ["fa:16:3e:44:8a:d5 10.0.0.29"]
enabled : true
external_ids : {"neutron:
name : "79cba8eb-
options : {mcast_
port_security : ["fa:16:3e:44:8a:d5 10.0.0.29"]
type : virtual
up : false
it was incorrectly bound to orphaned parent 76ff:
addresses : ["fa:16:3e:f6:cc:6a 10.0.0.29"]
enabled : true
external_ids : {"neutron:
name : "76ff3324-
options : {mcast_
port_security : ["fa:16:3e:f6:cc:6a 10.0.0.29"]
type : ""
up : false
As we can see, the only set of matching values is (IP, network_id) triplet, which may indicate that the problem lies in the usage of
def get_virtual_
function in neutron\
Manual workaround:
manually delete the port from OVN NB (ovn-nbctl lsp-del), and it's version from neutron ovn_revision_
Changed in neutron: | |
importance: | Undecided → Medium |
Hello Boris:
Can you describe why the port deletion failing in first place? If the Neutron DB port deletion failed, why is not present in the Neutron DB but it is in the OVN DB? Sorry but I can't see how could that happened.
In any case, what you have is an OVN LSP leftover that is not removed by the maintenance task. Correct?
Another question is: how "get_virtual_ port_parents" is related to this issue?
Regards.