neutron: 500 error when trying to attach no network to an instance with no network
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Compute (nova) |
Fix Released
|
Low
|
Matt Riedemann |
Bug Description
It's possible to create a VM with nova using neutron as the backend and have no network information. If the tenant doesn't have any available network in neutron and doesn't request any network, the neutron backend will simply log a message and continue.
If you then later attempt to use the os-attach-interface API and don't provider a network, and the tenant still doesn't have any networks available in neutron, then the request fails in the neutronv2 API code with an IndexError because it's assuming there is at least one available network:
http://
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
2016-02-12 09:34:32.188 TRACE nova.api.
We should at least handle that case and report a 400 to the user.
Changed in nova: | |
importance: | Undecided → Low |
status: | New → Confirmed |
Changed in nova: | |
assignee: | nobody → Matt Riedemann (mriedem) |
status: | Confirmed → In Progress |
Fix proposed to branch: master /review. openstack. org/279839
Review: https:/