ovn provider fails with "AttributeError: 'Client' object has no attribute 'ports'"

Bug #2046457 reported by kay
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
neutron
Fix Released
High
Fernando Royo

Bug Description

octavia-driver-agent[91903]: ERROR futurist.periodics [-] Failed to call periodic 'ovn_octavia_provider.maintenance.DBInconsistenciesPeriodics.change_device_owner_lb_hm_ports' (it runs every 600.00 seconds): AttributeError: 'Client' object has no attribute 'ports'
octavia-driver-agent[91903]: ERROR futurist.periodics Traceback (most recent call last):
octavia-driver-agent[91903]: ERROR futurist.periodics File "/usr/local/lib/python3.10/dist-packages/futurist/periodics.py", line 290, in run
octavia-driver-agent[91903]: ERROR futurist.periodics work()
octavia-driver-agent[91903]: ERROR futurist.periodics File "/usr/local/lib/python3.10/dist-packages/futurist/periodics.py", line 64, in __call__
octavia-driver-agent[91903]: ERROR futurist.periodics return self.callback(*self.args, **self.kwargs)
octavia-driver-agent[91903]: ERROR futurist.periodics File "/usr/local/lib/python3.10/dist-packages/futurist/periodics.py", line 178, in decorator
octavia-driver-agent[91903]: ERROR futurist.periodics return f(*args, **kwargs)
octavia-driver-agent[91903]: ERROR futurist.periodics File "/opt/stack/ovn-octavia-provider/ovn_octavia_provider/maintenance.py", line 79, in change_device_owner_lb_hm_ports
octavia-driver-agent[91903]: ERROR futurist.periodics ovn_lb_hm_ports = neutron_client.ports(
octavia-driver-agent[91903]: ERROR futurist.periodics AttributeError: 'Client' object has no attribute 'ports'

see also k8s e2e test results:

https://prow.k8s.io/view/gs/kubernetes-jenkins/pr-logs/pull/cloud-provider-openstack/2504/openstack-cloud-controller-manager-e2e-test/1735270733262622720

Revision history for this message
yatin (yatinkarel) wrote :

Thanks @kay for the bug report, from logs i see it's seen antelope release:-
=============
DevStack Version: 2023.1
Change: c32b528f8ddb2b9aaa3e20fe75b160062ef339d4 Make multiple attempts to download image 2023-12-12 08:08:04 +0000
OS Version: Ubuntu 22.04 jammy
=============

The Tracebacks is part of a new maintenance task added as part of [1], available in antelope+. But the code itself relies on openstacksdk switch from neutronclient[2], which was only available since bobcat.

So in order to fix it either [1] needs to be reverted or the maintenance code needs to be adopted to work with neutronclient.

Backporting [1] itself looks doubtful in stable/antelope and have dependency on another octavia patch.

Same trace can be see in ovn octavia CI [3]

[1] https://review.opendev.org/q/I0d4feb1e5c128d5a768d1b87deb2dcb3ab6d1ea1
[2] https://review.opendev.org/c/openstack/ovn-octavia-provider/+/870514
[3] https://zuul.opendev.org/t/openstack/build/8ef68ec671854adc9dac39395e87a84a/log/controller/logs/screen-o-da.txt#391-404

Changed in neutron:
importance: Undecided → High
status: New → Triaged
yatin (yatinkarel)
tags: added: stable
Changed in neutron:
assignee: nobody → Fernando Royo (froyoredhat)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to ovn-octavia-provider (stable/2023.1)

Fix proposed to branch: stable/2023.1
Review: https://review.opendev.org/c/openstack/ovn-octavia-provider/+/903867

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to ovn-octavia-provider (stable/2023.1)

Reviewed: https://review.opendev.org/c/openstack/ovn-octavia-provider/+/903867
Committed: https://opendev.org/openstack/ovn-octavia-provider/commit/8b55dc0ac392c648605a9174591cfff07635ec3b
Submitter: "Zuul (22348)"
Branch: stable/2023.1

commit 8b55dc0ac392c648605a9174591cfff07635ec3b
Author: Fernando Royo <email address hidden>
Date: Mon Dec 18 11:00:35 2023 +0100

    [stable-only] Fix ovn-lb-hm maintenance task

    Neutron client is used in stable/2023.1 and some part of code
    was backported from [1] using openstacksdk client that is
    already merged in master and stable/2023.2.

    This patch fix the calls to neutron_client affected.

    [1] https://review.opendev.org/c/openstack/ovn-octavia-provider/+/898535

    Closes-Bug: 2046457
    Change-Id: I512ab26b6ce692cdf7df73b711df42908a8e2a61

Changed in neutron:
status: Triaged → Fix Released
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.