Volume status remains "detaching" after a failure to detach a volume due to DeviceDetachFailed

Bug #1786318 reported by Lee Yarwood on 2018-08-09
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Medium
Lee Yarwood
Pike
Medium
Lee Yarwood
Queens
Medium
Lee Yarwood
Rocky
Medium
Lee Yarwood

Bug Description

Description
===========
Volume status remains "detaching" after a failure to detach a volume due to DeviceDetachFailed

Steps to reproduce
==================
Attempt to detach a volume while it is mounted and in-use within an instance.

Expected result
===============
Volume detach fails and the volume returns to in-use.

Actual result
=============
Volume detach fails and the volume remains in a detaching state.

Environment
===========
1. Exact version of OpenStack you are running. See the following
  list for all releases: http://docs.openstack.org/releases/

   R

2. Which hypervisor did you use?
   (For example: Libvirt + KVM, Libvirt + XEN, Hyper-V, PowerKVM, ...)
   What's the version of that?

   Libirt + KVM

2. Which storage type did you use?
   (For example: Ceph, LVM, GPFS, ...)
   What's the version of that?

   N/A

3. Which networking type did you use?
   (For example: nova-network, Neutron with OpenVSwitch, ...)

   N/A

Logs & Configs
==============

Fix proposed to branch: master
Review: https://review.openstack.org/590439

Changed in nova:
assignee: nobody → Lee Yarwood (lyarwood)
status: New → In Progress
Matt Riedemann (mriedem) on 2018-08-10
Changed in nova:
importance: Undecided → Medium

Reviewed: https://review.openstack.org/590439
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=3a4b4b91b0bee514d47a67f6a5f9c4ab9ae7f7d8
Submitter: Zuul
Branch: master

commit 3a4b4b91b0bee514d47a67f6a5f9c4ab9ae7f7d8
Author: Lee Yarwood <email address hidden>
Date: Thu Aug 9 17:43:50 2018 +0100

    block_device: Rollback volumes to in-use on DeviceDetachFailed

    The call to os-roll_detaching was dropped when
    I3800b466a50b1e5f5d1e8c8a963d9a6258af67ee started to catch and reraise
    DeviceDetachFailed. This call is required to ensure a volume returns to
    an in-use state when the instance is unable to detach.

    Closes-Bug: #1786318
    Change-Id: I6b3dc09acc6f360806ce0ef8c8a65addbf4a8c51

Changed in nova:
status: In Progress → Fix Released
Matt Riedemann (mriedem) on 2018-08-10
Changed in nova:
status: Fix Released → In Progress
status: In Progress → Fix Released
tags: added: rocky-rc-potential

Reviewed: https://review.openstack.org/590801
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=a890c3403653ddea5f5639fc783b93f9e8e39265
Submitter: Zuul
Branch: stable/rocky

commit a890c3403653ddea5f5639fc783b93f9e8e39265
Author: Lee Yarwood <email address hidden>
Date: Thu Aug 9 17:43:50 2018 +0100

    block_device: Rollback volumes to in-use on DeviceDetachFailed

    The call to os-roll_detaching was dropped when
    I3800b466a50b1e5f5d1e8c8a963d9a6258af67ee started to catch and reraise
    DeviceDetachFailed. This call is required to ensure a volume returns to
    an in-use state when the instance is unable to detach.

    Closes-Bug: #1786318
    Change-Id: I6b3dc09acc6f360806ce0ef8c8a65addbf4a8c51
    (cherry picked from commit 3a4b4b91b0bee514d47a67f6a5f9c4ab9ae7f7d8)

Reviewed: https://review.openstack.org/590803
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=838ecb33830e58dabd5e7116a164b7ef792e6fdb
Submitter: Zuul
Branch: stable/queens

commit 838ecb33830e58dabd5e7116a164b7ef792e6fdb
Author: Lee Yarwood <email address hidden>
Date: Thu Aug 9 17:43:50 2018 +0100

    block_device: Rollback volumes to in-use on DeviceDetachFailed

    The call to os-roll_detaching was dropped when
    I3800b466a50b1e5f5d1e8c8a963d9a6258af67ee started to catch and reraise
    DeviceDetachFailed. This call is required to ensure a volume returns to
    an in-use state when the instance is unable to detach.

    Closes-Bug: #1786318
    Change-Id: I6b3dc09acc6f360806ce0ef8c8a65addbf4a8c51
    (cherry picked from commit 3a4b4b91b0bee514d47a67f6a5f9c4ab9ae7f7d8)
    (cherry picked from commit a890c3403653ddea5f5639fc783b93f9e8e39265)

This issue was fixed in the openstack/nova 18.0.0.0rc3 release candidate.

Reviewed: https://review.openstack.org/590804
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=6864804e61171aa3effa80642f47a7ccd040dd31
Submitter: Zuul
Branch: stable/pike

commit 6864804e61171aa3effa80642f47a7ccd040dd31
Author: Lee Yarwood <email address hidden>
Date: Thu Aug 9 17:43:50 2018 +0100

    block_device: Rollback volumes to in-use on DeviceDetachFailed

    The call to os-roll_detaching was dropped when
    I3800b466a50b1e5f5d1e8c8a963d9a6258af67ee started to catch and reraise
    DeviceDetachFailed. This call is required to ensure a volume returns to
    an in-use state when the instance is unable to detach.

    Closes-Bug: #1786318
    Change-Id: I6b3dc09acc6f360806ce0ef8c8a65addbf4a8c51
    (cherry picked from commit 3a4b4b91b0bee514d47a67f6a5f9c4ab9ae7f7d8)
    (cherry picked from commit a890c3403653ddea5f5639fc783b93f9e8e39265)
    (cherry picked from commit 838ecb33830e58dabd5e7116a164b7ef792e6fdb)

This issue was fixed in the openstack/nova 16.1.5 release.

This issue was fixed in the openstack/nova 17.0.6 release.

This issue was fixed in the openstack/nova 19.0.0.0rc1 release candidate.

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers