[openstack-dev] Quantum : deleting an in-use port is possible. Is this a bug or feature ?

Dan Wendlandt dan at nicira.com
Fri Feb 8 18:03:13 UTC 2013


Hi Gavin,

>From an API perspective, this is intentional, as it is important to be able
to clean up ports that another service (e.g., Nova) might have orphaned.
 It also means that services like Nova can delete the port for a VM without
two calls (first to clear the device_id, second to delete the port).

That said, I think one could certainly argue that from a tenant CLI or GUI
perspective, we should try to warn users who are deleting a port that
appears to be in use, and for example, require them to specify a --force
option (CLI) or click another confirmation (GUI) if the device_id of a port
is still set.  That would be a pretty simple change, I suspect.

Dan

p.s.  The patch proposed by someone else to enforce that API deletes cannot
happen if device_id is non-empty actually breaks the current nova/quantum
interaction and (ironically) leaves orphaned ports with a device_id set.
https://review.openstack.org/#/c/21520/

On Thu, Feb 7, 2013 at 9:58 AM, Brebner, Gavin <gavin.brebner at hp.com> wrote:

>  ** **
>
> Running on a quantum-enabled devstack.****
>
> ** **
>
> I created a network, subnet and a VM that used the network.****
>
> ** **
>
> I then deleted the port used by the VM – no error, and I end up****
>
> getting a VM without an address :****
>
> ** **
>
> ubuntu at az3devstackvm2:/opt/stack/tempest2/tempest/tests/network$ nova list
> ****
>
>
> +--------------------------------------+-----------------------+--------+----------+
> ****
>
> | ID                                   | Name                  | Status |
> Networks |****
>
>
> +--------------------------------------+-----------------------+--------+----------+
> ****
>
> | e43ec1a6-9499-4a7f-bbd0-fbecf6f3c115 | server-negtest-322040 | ACTIVE
> |          |****
>
>
> +--------------------------------------+-----------------------+--------+----------+
> ****
>
> ** **
>
> So far I’ve not found a way to re-attach the VM to my network.****
>
> ** **
>
> Is this a bug or a feature ?****
>
> ** **
>
> Gavin****
>
> ** **
>
>                 ****
>
> ** **
>
> _______________________________________________
> OpenStack-dev mailing list
> OpenStack-dev at lists.openstack.org
> http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev
>
>


-- 
~~~~~~~~~~~~~~~~~~~~~~~~~~~
Dan Wendlandt
Nicira, Inc: www.nicira.com
twitter: danwendlandt
~~~~~~~~~~~~~~~~~~~~~~~~~~~
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstack.org/pipermail/openstack-dev/attachments/20130208/e65b97e0/attachment.html>


More information about the OpenStack-dev mailing list