Nova deletes port when detaching auto-created interface

Bug #1976545 reported by Artom Lifshitz
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
In Progress
Undecided
Unassigned

Bug Description

Description
===========

When detaching an interface that was auto-created (for example, with networks='auto' at server boot time), Nova deletes the port.

Steps to reproduce
==================
1. Boot a server with an auto-created Neutron port.
2. Detach the port using the Nova API.

Expected result
===============
Port is detached, but still present in Neutron. While it makes sense to delete auto-created ports when deleting the server to avoid leaking ports, IMO when an auto-created port is detached its ownership now belongs to the user, as they've explicitly requested an operation on it, and are now responsible for its future life cycle.

Actual result
=============
The port is completely deleted from Neutron.

Environment
===========
Reproduced on master with a func test, reported in stable/train.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix proposed to nova (master)

Related fix proposed to branch: master
Review: https://review.opendev.org/c/openstack/nova/+/844325

Changed in nova:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to nova (master)

Fix proposed to branch: master
Review: https://review.opendev.org/c/openstack/nova/+/844326

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.