[OVN] Regression when using ML2/OVN with Neutron DHCP agent

Bug #1935983 reported by Lucas Alvares Gomes
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
neutron
In Progress
Critical
Lucas Alvares Gomes

Bug Description

In an attempt to minimize the number of connections to the OVSDBs the ML2/OVN driver no longer connects to the OVN dbs if the Neutron worker is a RpcWorker [0].

This introduced a regression where when ML2/OVN is deployed along with the Neutron DHCP server (e.g for baremetal provisioning) the DHCP agent is no longer able to create the DHCP port and fails with the following error message:

2021-07-13 13:36:18.116 17 ERROR neutron.plugins.ml2.managers Traceback (most recent call last):
2021-07-13 13:36:18.116 17 ERROR neutron.plugins.ml2.managers File "/usr/lib/python3.6/site-packages/neutron/plugins/ml2/managers.py", line 477, in _call_on_drivers
2021-07-13 13:36:18.116 17 ERROR neutron.plugins.ml2.managers getattr(driver.obj, method_name)(context)
2021-07-13 13:36:18.116 17 ERROR neutron.plugins.ml2.managers File "/usr/lib/python3.6/site-packages/networking_ovn/ml2/mech_driver.py", line 551, in create_port_precommit
2021-07-13 13:36:18.116 17 ERROR neutron.plugins.ml2.managers if self._is_port_provisioning_required(port, context.host):
2021-07-13 13:36:18.116 17 ERROR neutron.plugins.ml2.managers File "/usr/lib/python3.6/site-packages/networking_ovn/ml2/mech_driver.py", line 589, in _is_port_provisioning_required
2021-07-13 13:36:18.116 17 ERROR neutron.plugins.ml2.managers if not self._sb_ovn.chassis_exists(host):
2021-07-13 13:36:18.116 17 ERROR neutron.plugins.ml2.managers AttributeError: 'NoneType' object has no attribute 'chassis_exists'

See full traceback at: http://paste.openstack.org/show/807435/

[0] https://opendev.org/openstack/neutron/commit/c4007b0833111a25d24f597161d39ee9ccd37189

Tags: ovn
Revision history for this message
Rodolfo Alonso (rodolfo-alonso-hernandez) wrote :

Hello:

In a "normal" deployment (without baremetal chassis) we don't use DHCP agents; this is why, as you commented, we removed the OVSDBs connectivity from other classes than WorkerService and MaintenanceWorker.

In this specific case, I think https://review.opendev.org/c/openstack/neutron/+/795781 is what you are looking for. This patch will allow you to define more server classes (RpcWorker in your case) that could have OVN IDL connectivity.

Does it work for you?

Regards.

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

without baremetal servers* (not chassis)

Revision history for this message
Rodolfo Alonso (rodolfo-alonso-hernandez) wrote :
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/+/800679

Changed in neutron:
status: Triaged → In Progress
Revision history for this message
Lucas Alvares Gomes (lucasagomes) wrote :

Hi Rodolfo,

Thanks for pointing that out. Yes that option does work but, I don't think it should be the final fix for this.

For one, it's not backportable (since it adds a config option). And also, we are now by default breaking a use-case that worked before, this would require operators to add support and change their scripts/tools to accommodate to that option to fix something that already worked.

Revision history for this message
Bartosz Bezak (bbezak) wrote :
Revision history for this message
Lucas Alvares Gomes (lucasagomes) wrote :

Hi Bartosz,

Thanks much for the pointers. I can see how this bug is duplicated with [0] indeed. I will mark it as such.

For the patch [1] I do not think it solves the problem because RpcWorkers (by default due to the new configuration option) will not connect to the OVN databases (this is true for stable branches where the config option is not present).

[0] https://bugs.launchpad.net/neutron/+bug/1929633
[1] https://review.opendev.org/c/openstack/neutron/+/781555/

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/+/800780

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/+/800781

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/+/800782

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on neutron (stable/ussuri)

Change abandoned by "Lucas Alvares Gomes <email address hidden>" on branch: stable/ussuri
Review: https://review.opendev.org/c/openstack/neutron/+/800782
Reason: Will cherry-pick from wallaby

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on neutron (stable/victoria)

Change abandoned by "Lucas Alvares Gomes <email address hidden>" on branch: stable/victoria
Review: https://review.opendev.org/c/openstack/neutron/+/800781
Reason: Will cherry-pick from wallaby

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/+/800783

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/+/800784

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on neutron (stable/wallaby)

Change abandoned by "Lucas Alvares Gomes <email address hidden>" on branch: stable/wallaby
Review: https://review.opendev.org/c/openstack/neutron/+/800780
Reason: We've changed the master branch approach and now the patch is backportable

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on neutron (stable/victoria)

Change abandoned by "Lucas Alvares Gomes <email address hidden>" on branch: stable/victoria
Review: https://review.opendev.org/c/openstack/neutron/+/800784
Reason: We've changed the master branch approach and now the patch is backportable

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on neutron (stable/ussuri)

Change abandoned by "Lucas Alvares Gomes <email address hidden>" on branch: stable/ussuri
Review: https://review.opendev.org/c/openstack/neutron/+/800783
Reason: We've changed the master branch approach and now the patch is backportable

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.