Bug 1668159 - Nova Compute does not clean up host networking if UnexpectedDeletingTaskStateError is raised.
Summary: Nova Compute does not clean up host networking if UnexpectedDeletingTaskStat...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat OpenStack
Classification: Red Hat
Component: openstack-nova
Version: 13.0 (Queens)
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: ---
: ---
Assignee: Stephen Finucane
QA Contact: James Parker
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2019-01-22 05:31 UTC by Robin Cernin
Modified: 2023-10-06 18:08 UTC (History)
19 users (show)

Fixed In Version: openstack-nova-17.0.13-5.el7ost
Doc Type: No Doc Update
Doc Text:
Clone Of:
Environment:
Last Closed: 2020-06-24 11:52:31 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Launchpad 1831771 0 None None None 2019-06-05 16:59:51 UTC
Red Hat Issue Tracker OSP-29346 0 None None None 2023-10-06 18:08:19 UTC
Red Hat Product Errata RHBA-2020:2725 0 None None None 2020-06-24 11:52:48 UTC

Comment 2 smooney 2019-01-25 12:27:49 UTC
looking at the upstream code when destroy is called in the libvirt driver
https://github.com/openstack/nova/blob/stable/queens/nova/virt/libvirt/driver.py#L988-L992
it calls cleanup  which calls _unplug_vifs
https://github.com/openstack/nova/blob/stable/queens/nova/virt/libvirt/driver.py#L1018-L1019

which then loops over all the vifs and unplugs them via the dirver 
https://github.com/openstack/nova/blob/stable/queens/nova/virt/libvirt/driver.py#L838-L845


looking at the downstream code it is identical and i have confimed that the downstream
code deletes the tap device created during plug as it does upstream.
https://github.com/openstack/nova/blob/stable/queens/nova/virt/libvirt/vif.py#L908-L919

the privsep wrapped plug_contrail_vif and unplug_contrail_vif fucntions
https://github.com/openstack/nova/blob/stable/queens/nova/privsep/libvirt.py#L225-L254
are also identical downsteam so based on the inspection of the code the behavior you describe
cannot happen.

can you provide the full nova compute logs and preferably the full sos report for this host.
based on the inspection of the code i feel i should be marking this as invalid but i will
review the logs if the full logs are provided.

Comment 10 smooney 2019-02-18 21:04:23 UTC
when nova recived a delete request for and instance that has been spawned on the host
but not yet updated in the db a UnexpectedDeletingTaskStateError exception will be raised
when the compute manager tries to update the db state.

when that happens we do not call self.driver.cleanup
https://github.com/openstack/nova/blob/master/nova/compute/manager.py#L2030-L2036

as a result we do not clean up the vif for the instance.

this will need to be fixed upstream first and then we can backport the fix downstream to osp 13

Comment 20 Stephen Finucane 2019-08-12 16:38:46 UTC
I have this patch refreshed but I'm unable to reproduce. Would it be possible to provide a reproducer for me if I provided a scratch RPM to test with?

Comment 30 Matthew Booth 2019-10-21 08:02:33 UTC
I've added the requested functional test upstream.

Comment 32 Cristian Muresanu 2019-11-24 23:11:28 UTC
Hi guys, I'm wondering if this can be back-ported to RHOSP 10 as well ?
Thanks

Comment 33 Cristian Muresanu 2019-11-27 05:18:58 UTC
Hi, we're wondering if there is there is anyway to clean these ghost/stale interfaces manually?
Thanks,

Comment 45 Stephen Finucane 2020-03-31 14:47:49 UTC
This has landed upstream. I have the backports proposed for stable branches upstream and downstream. Hoping to get this closed out this week.

Comment 47 Stephen Finucane 2020-04-24 10:21:48 UTC
This has landed and will be included in the next OSP13 z-stream, 13z12.

Comment 59 errata-xmlrpc 2020-06-24 11:52:31 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2020:2725


Note You need to log in before you can comment on or make changes to this bug.