Volume is not unreserved when shelved_offloaded volume attach fails

Bug #1629952 reported by Matt Riedemann
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
In Progress
Medium
Matt Riedemann

Bug Description

This code attaches a volume to a shelved offloaded instance:

https://github.com/openstack/nova/blob/b3d58ed718db91015582cf759a7c8af1874ef093/nova/compute/api.py#L3416

But it doesn't unreserve the volume if that fails in the exception block. This could happen if the os-attach call to cinder failed. And if that happens, then the volume is stuck in 'attaching' state and the admin has to reset the state on it to make it available again.

Revision history for this message
Matt Riedemann (mriedem) wrote :

This code might actually be part of an incomplete blueprint, and if that's the case and no one is working on finishing that blueprint (since Andrea Rosa is no longer working on openstack and I think he added the change), then we should maybe just remove this code.

Revision history for this message
Matt Riedemann (mriedem) wrote :

Looks like the blueprint was completely implemented:

https://blueprints.launchpad.net/nova/+spec/volume-ops-when-shelved

So we just need to fix this corner case.

Changed in nova:
assignee: nobody → Matt Riedemann (mriedem)
Revision history for this message
Matt Riedemann (mriedem) wrote :
Matt Riedemann (mriedem)
Changed in nova:
assignee: Matt Riedemann (mriedem) → nobody
Sean Dague (sdague)
Changed in nova:
assignee: nobody → Matt Riedemann (mriedem)
status: Triaged → In Progress
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.