yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #76439
[Bug 1809497] [NEW] _get_filterid_for_ip can generate an UnboundLocalError
Public bug reported:
After fixing a bug in the L3 extension API,
https://review.openstack.org/#/c/626401/ - the l3-agent is getting a
traceback in the QoS code running the dvr multinode scenario job.
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent [-] Failed to process compatible router: 7461a0e1-508c-4ff2-a559-6cc89a128ea5: UnboundLocalError: local variable 'filter_id' referenced before assignment
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent Traceback (most recent call last):
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent File "/opt/stack/neutron/neutron/agent/l3/agent.py", line 628, in _process_routers_if_compatible
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent self._process_router_if_compatible(router)
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent File "/opt/stack/neutron/neutron/agent/l3/agent.py", line 504, in _process_router_if_compatible
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent self._process_updated_router(router)
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent File "/opt/stack/neutron/neutron/agent/l3/agent.py", line 529, in _process_updated_router
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent self.l3_ext_manager.update_router(self.context, router)
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent File "/opt/stack/neutron/neutron/agent/l3/l3_agent_extensions_manager.py", line 54, in update_router
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent extension.obj.update_router(context, data)
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent File "/usr/local/lib/python3.6/dist-packages/oslo_concurrency/lockutils.py", line 328, in inner
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent return f(*args, **kwargs)
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent File "/opt/stack/neutron/neutron/agent/l3/extensions/qos/fip.py", line 292, in update_router
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent self.process_floating_ip_addresses(context, router_info)
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent File "/opt/stack/neutron/neutron/agent/l3/extensions/qos/fip.py", line 277, in process_floating_ip_addresses
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent self._remove_fip_rate_limit(device, fip)
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent File "/opt/stack/neutron/neutron/agent/l3/extensions/qos/fip.py", line 164, in _remove_fip_rate_limit
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent tc_wrapper.clear_ip_rate_limit(direction, fip_ip)
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent File "/opt/stack/neutron/neutron/agent/linux/l3_tc_lib.py", line 188, in clear_ip_rate_limit
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent filter_id = self._get_filterid_for_ip(qdisc_id, ip)
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent File "/opt/stack/neutron/neutron/agent/linux/l3_tc_lib.py", line 82, in _get_filterid_for_ip
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent filterids_for_ip.append(filter_id)
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent UnboundLocalError: local variable 'filter_id' referenced before assignment
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent
>From this log file:
http://logs.openstack.org/01/626401/1/check/neutron-tempest-plugin-dvr-
multinode-
scenario/a7bcbe2/controller/logs/screen-q-l3.txt.gz?level=WARNING#_Dec_19_23_26_00_169583
The loop in _get_filterid_for_ip() doesn't look to protect against this
case, we'd need to capture the output to see why it's failing.
** Affects: neutron
Importance: High
Status: New
** Tags: qos
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to neutron.
https://bugs.launchpad.net/bugs/1809497
Title:
_get_filterid_for_ip can generate an UnboundLocalError
Status in neutron:
New
Bug description:
After fixing a bug in the L3 extension API,
https://review.openstack.org/#/c/626401/ - the l3-agent is getting a
traceback in the QoS code running the dvr multinode scenario job.
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent [-] Failed to process compatible router: 7461a0e1-508c-4ff2-a559-6cc89a128ea5: UnboundLocalError: local variable 'filter_id' referenced before assignment
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent Traceback (most recent call last):
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent File "/opt/stack/neutron/neutron/agent/l3/agent.py", line 628, in _process_routers_if_compatible
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent self._process_router_if_compatible(router)
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent File "/opt/stack/neutron/neutron/agent/l3/agent.py", line 504, in _process_router_if_compatible
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent self._process_updated_router(router)
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent File "/opt/stack/neutron/neutron/agent/l3/agent.py", line 529, in _process_updated_router
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent self.l3_ext_manager.update_router(self.context, router)
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent File "/opt/stack/neutron/neutron/agent/l3/l3_agent_extensions_manager.py", line 54, in update_router
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent extension.obj.update_router(context, data)
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent File "/usr/local/lib/python3.6/dist-packages/oslo_concurrency/lockutils.py", line 328, in inner
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent return f(*args, **kwargs)
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent File "/opt/stack/neutron/neutron/agent/l3/extensions/qos/fip.py", line 292, in update_router
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent self.process_floating_ip_addresses(context, router_info)
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent File "/opt/stack/neutron/neutron/agent/l3/extensions/qos/fip.py", line 277, in process_floating_ip_addresses
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent self._remove_fip_rate_limit(device, fip)
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent File "/opt/stack/neutron/neutron/agent/l3/extensions/qos/fip.py", line 164, in _remove_fip_rate_limit
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent tc_wrapper.clear_ip_rate_limit(direction, fip_ip)
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent File "/opt/stack/neutron/neutron/agent/linux/l3_tc_lib.py", line 188, in clear_ip_rate_limit
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent filter_id = self._get_filterid_for_ip(qdisc_id, ip)
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent File "/opt/stack/neutron/neutron/agent/linux/l3_tc_lib.py", line 82, in _get_filterid_for_ip
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent filterids_for_ip.append(filter_id)
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent UnboundLocalError: local variable 'filter_id' referenced before assignment
neutron-l3-agent[14973]: ERROR neutron.agent.l3.agent
From this log file:
http://logs.openstack.org/01/626401/1/check/neutron-tempest-plugin-
dvr-multinode-
scenario/a7bcbe2/controller/logs/screen-q-l3.txt.gz?level=WARNING#_Dec_19_23_26_00_169583
The loop in _get_filterid_for_ip() doesn't look to protect against
this case, we'd need to capture the output to see why it's failing.
To manage notifications about this bug go to:
https://bugs.launchpad.net/neutron/+bug/1809497/+subscriptions
Follow ups