neutron/neutron
Miguel Lavalle 33de608f04 Avoid race condition when deleting trunk bridges
Prior to this change, trunk bridges are created by os-vif but deleted
by Neutron when the last vif is removed from it. This creates race
conditions in some use cases, like DPDK with vhostuserclient mode, when
VMs are rebooted. To avoid these races, Neutron will not delete trunk
bridges anymore. Their creation and deletion will be os-vif's
responsiblity. Since [1], Nova uses the os-vif version that contains
this functionality.

This patch also changes the trunk status change event. During a live
migration, when the trunk parent port has been bound to the destination
host (that means there is only one port binding associated) and the
status has changed to ACTIVE, the method triggers the subport binding
to the new host too. This is because there could be a race condition
between the subport binding, triggered by the OVS agent, and the parent
port binding, triggered by Nova. If when the OVS agent tries to bind the
subports, the parent port is still bound to the source host, the subport
binding remains in the source host too, instead of changing to the
destination.

This patch also reverts [2] and [3]. As commented in the previous
paragraph, this patch fixes the issue reported in LP#1997025. The trunk
port live migration with ML2/OVS must be fixed with this patch.

[1]https://review.opendev.org/c/openstack/nova/+/865031
[2]https://review.opendev.org/c/openstack/neutron/+/865295
[3]https://review.opendev.org/c/openstack/neutron/+/865424

Closes-Bug: #1869244
Closes-Bug: #1997025

Change-Id: I4e16357f3ff214fcf41e418982806c24088a2665
2022-11-17 10:39:30 +01:00
..
agent Merge "Update tap ip in metadata agent when metadata port ip updated" 2022-11-24 06:31:33 +00:00
api Fix some pylint indentation warnings 2022-11-02 10:11:46 -04:00
cmd Merge "db: add segment_index to the unique constraint" 2022-11-24 10:23:22 +00:00
common Merge "Code move for metadata haproxy" 2022-11-23 20:33:23 +00:00
conf Remove policy rule for get_network:router:external 2022-11-18 16:09:20 +01:00
core_extensions Revert "Set system_scope='all' in elevated context" 2021-06-15 10:29:20 +02:00
db Merge "db: add segment_index to the unique constraint" 2022-11-24 10:23:22 +00:00
debug Fix typos in log/error messages 2022-06-01 21:17:29 +05:30
exceptions Add port-resource-request-groups extension 2021-10-21 14:30:07 +02:00
extensions [api]adds port_forwarding id when list floatingip 2022-08-26 08:45:09 +08:00
hacking Fix remaining typos in comments and tests 2022-07-06 21:20:27 +05:30
ipam Fix some pylint indentation warnings 2022-11-02 10:47:38 -04:00
locale Imported Translations from Zanata 2022-04-30 03:45:16 +00:00
notifiers Retry connections to Nova 2022-09-02 11:26:40 +02:00
objects Always create a "router_extra_attributes" register per router 2022-11-18 08:51:43 +00:00
pecan_wsgi Merge "Handle properly InvalidScope exceptions to not return error 500" 2022-04-19 06:42:29 +00:00
plugins Merge "Make MechanismDriverContext plugin_context public" 2022-11-23 20:33:10 +00:00
privileged Format the protocol number to be passed to pyroute2 2022-08-29 12:44:14 +02:00
profiling Remove "six" library 2020-07-28 16:55:52 +00:00
quota Implement specific tracked resource count method per quota driver 2022-07-28 06:01:18 +02:00
scheduler Fix some pylint indentation warnings 2022-11-02 10:26:11 -04:00
server Use monkey_patch for neutron API server. 2022-04-28 13:34:36 +00:00
services Avoid race condition when deleting trunk bridges 2022-11-17 10:39:30 +01:00
tests Avoid race condition when deleting trunk bridges 2022-11-17 10:39:30 +01:00
__init__.py Remove usage of six.PY2 2020-05-22 12:59:01 -04:00
_i18n.py
auth.py Add fake_project_id middleware for noauth 2021-07-05 21:18:09 +05:30
manager.py Remove usage of six.add_metaclass 2020-05-21 14:41:18 -04:00
neutron_plugin_base_v2.py Remove usage of six.add_metaclass 2020-05-21 14:41:18 -04:00
opts.py Merge "Fix some pylint indentation warnings" 2022-07-05 17:19:29 +00:00
policy.py Bump oslo.policy to 3.12.0 2022-05-02 12:47:16 +02:00
service.py Re-use existing ProcessLauncher from wsgi in RPC workers 2020-02-07 14:51:06 +01:00
version.py
worker.py
wsgi.py Fix some pylint indentation warnings 2022-07-01 17:52:59 -04:00