Bug 1461810 - heat stack snapshot failes when cinder volume is IN_USE state
heat stack snapshot failes when cinder volume is IN_USE state
Product: Red Hat OpenStack
Classification: Red Hat
Component: openstack-heat (Show other bugs)
11.0 (Ocata)
x86_64 Linux
medium Severity medium
: z1
: 11.0 (Ocata)
Assigned To: Thomas Hervé
Amit Ugol
: Triaged, ZStream
Depends On: 1438137
  Show dependency treegraph
Reported: 2017-06-15 07:27 EDT by Thomas Hervé
Modified: 2017-07-19 13:04 EDT (History)
10 users (show)

See Also:
Fixed In Version: openstack-heat-8.0.2-2.el7ost
Doc Type: Bug Fix
Doc Text:
Cause: Cinder requires an extra flag to force allowing a snapshot of a volume that is IN_USE. Heat did not pass that flag when doing "stack snapshot create". Consequence: Creating the snapshot failed if the stack contained any volumes that were in-use. Fix: The force flag is now passed to Cinder when creating the volume snapshot. Result: Stacks containing volumes that are in-use can now be snapshotted.
Story Points: ---
Clone Of: 1438137
Last Closed: 2017-07-19 13:04:31 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

External Trackers
Tracker ID Priority Status Summary Last Updated
Launchpad 1687006 None None None 2017-06-15 07:27 EDT
OpenStack gerrit 465592 None None None 2017-06-15 07:27 EDT
OpenStack gerrit 465593 None None None 2017-06-15 07:27 EDT
Red Hat Product Errata RHBA-2017:1779 normal SHIPPED_LIVE openstack-heat bug fix advisory 2017-07-19 17:01:19 EDT

  None (edit)
Description Thomas Hervé 2017-06-15 07:27:49 EDT
+++ This bug was initially created as a clone of Bug #1438137 +++

Description of problem:

I tried to create heat stack snapshot for the stack in which instance is
booted using cinder volume. It got failed because of cinder volume
IN_USE state. I don't see any option from heat to force the snapshot
creation. It looks like a bug.
# heat stack-snapshot f03159ff-c301-4e38-adb0-df69b9cd0fd8 -n
WARNING (shell) "heat stack-snapshot" is deprecated, please use
"openstack stack snapshot create" instead
  "status": "IN_PROGRESS",
  "name": "teststack1-snap1",
  "data": null,
  "creation_time": "2017-03-16T12:51:12Z",
  "status_reason": null,
  "id": "aa0d8b13-ce1f-4b35-a62a-08db30a79f25"

# heat snapshot-list f03159ff-c301-4e38-adb0-df69b9cd0fd8
WARNING (shell) "heat snapshot-list" is deprecated, please use
"openstack stack snapshot list" instead
| id                                   | name             | status |
| creation_time        |
| aa0d8b13-ce1f-4b35-a62a-08db30a79f25 | teststack1-snap1 | FAILED |
Resource SNAPSHOT failed: BadRequest: resources.volume: Invalid volume:
Backing up an in-use volume must use the force flag. (HTTP 400)
(Request-ID: req-1a2ae978-c656-4880-8ae6-d3c38afb2821) |
2017-03-16T12:51:12Z |

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1. Spawn an instance using stack which is boot from cinder volume
2. Tried to take the snapshot of the heat stack. It's getting failed because volume is IN_USE. 
3. We can use the cinder force option to take the snapshot of IN_USE volume but this option is not available with heat snapshot. 

Actual results:
Not able to take the snapshot of heat stack. 

Expected results:
We should be able to take the snapshot of heat stack. 

Additional info:
Comment 4 errata-xmlrpc 2017-07-19 13:04:31 EDT
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.


Note You need to log in before you can comment on or make changes to this bug.