Cinder show does not inform about snapshot

Bug #1405862 reported by Maxim V. Yefimov
14
This bug affects 3 people
Affects Status Importance Assigned to Milestone
Mirantis OpenStack
Won't Fix
High
Ivan Kolodyazhny
4.1.x
Won't Fix
High
MOS Cinder
5.0.x
Won't Fix
High
MOS Cinder
5.1.x
Won't Fix
High
MOS Cinder
6.0.x
Won't Fix
High
MOS Cinder
6.1.x
Won't Fix
High
Ivan Kolodyazhny
7.0.x
Won't Fix
Medium
Ivan Kolodyazhny

Bug Description

MOS 4.1

We noticed that when we delete cinder volumes, it will error out if there are snapshots

Running cinder delete 523e0d8a-0405-4927-b4ab-2e9763ab07a8
ERROR: Invalid volume: Volume still has 1 dependent snapshots

# cinder snapshot-list --all-tenants
+--------------------------------------+--------------------------------------+-----------+----------------------+------+
| ID | Volume ID | Status | Display Name | Size |
+--------------------------------------+--------------------------------------+-----------+----------------------+------+
| 10ed0442-ab0e-462a-a096-317641eb9185 | 523e0d8a-0405-4927-b4ab-2e9763ab07a8 | available | | 30 |
| 19e01a80-dff2-45e0-8ef7-1c4ecbf23a99 | 0d37f162-2d3a-4f9c-87c3-f9c24b4cb388 | available | XXX | 200 |
| 2616a17c-e4e5-4280-87f8-2418346af5f2 | 93a997e7-6bc8-43ed-851f-fc2f5c8814ce | available | XXX | 200 |
| 529c561f-7021-4e69-b51b-06fdd128d2d2 | d7b6e516-2065-4f82-8269-b30eb5e2426b | available | | 10 |
| 64f6be93-3254-4850-8ca0-1cf2fe0f3699 | 42af7955-b7ed-449c-85ee-7099a7017129 | available | XXX | 5 |
| 78c4222b-05f7-49cb-9766-2e9b7c6d30ac | 86b351a5-cbe4-4d15-a261-77e631bcd2ed | available | XXX | 5 |
| a5aff6bf-3e02-4156-8bb6-bf53d96f50d4 | 3b5f182b-cdd4-4ec2-a36e-475e968fe33a | available | | 30 |
| a7f973a7-e09f-4425-907c-87a1d52502eb | ec7b2a8c-78c1-46c3-87af-a3a634137448 | available | | 10 |
| d7f4bb6c-0a1d-4a22-9ff0-874277c21990 | 0d37f162-2d3a-4f9c-87c3-f9c24b4cb388 | available | XXX | 200 |
| faccca8a-9009-48d7-a524-ef0056024f7e | ea52373a-cf78-4fe6-8c7a-859751504912 | available | XXX | 1 |
+--------------------------------------+--------------------------------------+-----------+----------------------+------+

But cinder show does not tell us it's a snapshot:

# cinder show 523e0d8a-0405-4927-b4ab-2e9763ab07a8
+--------------------------------+--------------------------------------+
| Property | Value |
+--------------------------------+--------------------------------------+
| attachments | [] |
| availability_zone | nova |
| bootable | false |
| created_at | 2014-10-10T14:55:10.000000 |
| display_description | None |
| display_name | None |
| id | 523e0d8a-0405-4927-b4ab-2e9763ab07a8 |
| metadata | {u'readonly': u'False'} |
| os-vol-host-attr:host | xxx.xxx.xxx |
| os-vol-mig-status-attr:migstat | None |
| os-vol-mig-status-attr:name_id | None |
| os-vol-tenant-attr:tenant_id | 055df6b2b44845bfb863059fa2358c6e |
| size | 30 |
| snapshot_id | None |
| source_volid | None |
| status | available |
| volume_type | None |
+--------------------------------+--------------------------------------+

tags: added: customer found
removed: cinder
tags: removed: found
Denis Ipatov (dipatov)
tags: added: cinder customer-found
removed: customer
Revision history for this message
Alexander Rubtsov (arubtsov) wrote :
Ivan Kolodyazhny (e0ne)
Changed in mos:
assignee: nobody → MOS Cinder (mos-cinder)
Changed in mos:
milestone: none → 6.1
information type: Public → Public Security
information type: Public Security → Public
Ivan Kolodyazhny (e0ne)
Changed in mos:
status: New → Confirmed
Revision history for this message
Ivan Kolodyazhny (e0ne) wrote :

Working on fix in upstream for https://launchpad.net/bugs/1111839

Revision history for this message
Ivan Kolodyazhny (e0ne) wrote :

This issue requires API changes so it will be fixed only in 7.x+ after patch will be merged in upstream

Changed in mos:
status: Confirmed → Won't Fix
status: Won't Fix → In Progress
milestone: 6.1 → 7.0
Revision history for this message
Dmitry Borodaenko (angdraug) wrote :

If it's not going to be fixed properly until 7.x, please document a workaround in the bug description.

Revision history for this message
Dmitriy Novakovskiy (dnovakovskiy) wrote :

Gentlemen,

Do I understand correctly that ANY volume delete operation will fail in any current Mirantis OpenStack installation if the volume has snapshots? Any backend (Ceph, NetApp), any OpenStack distro (assuming no patch was applied specifically for this problem) ?

Revision history for this message
Dmitry Borodaenko (angdraug) wrote :

Dmitriy N.: Yes, this is not specific to Mirantis distro, any current OpenStack installation will have the same problem regardless of backend.

Ivan K.: please document a workaround as requested in comment #4 two weeks ago.

Revision history for this message
Ivan Kolodyazhny (e0ne) wrote :

Dmitry B,

the problem it that cinder does not _show_ snapshots if volumes list or volume details is called. Cinder doesn't allow do delete volume if it has snapshot. It's a common behavior to not delete objects if it contains depended data. Volumes could be deleted only if all it's snapshots are deleted.

We can't fix it in MOS <7 because it requires API changes. It could be REST API or python-cinderclient API. In such cases our OpenStack will have different API with upstream.

I can't say that it is workaround, because it's a feature request, not bug. May be it's only UX issue.

you need to call 'cinder snapshot-list | grep <vol_id>' before volume delete and delete all volume's snapshots using 'cinder snapshot-delete <snapshot_id>' command

no longer affects: mos/6.0.x
Changed in mos:
milestone: 7.0 → 6.1
status: In Progress → New
Changed in mos:
status: New → Won't Fix
Revision history for this message
Dmitry Mescheryakov (dmitrymex) wrote :

We are not going to fix the issue in 6.x because it requires changes in OpenStack API. And we don't want MOS API be different from the upstream OpenStack. Hence we work in the upstream on fixing the issue.

tags: added: release-note
tags: added: release-notes
removed: release-note
tags: added: release-notes-done
removed: release-notes
Revision history for this message
Ivan Kolodyazhny (e0ne) wrote :

It's not fixed in Kilo. I hope to get it merged in Liberty/MOS 8.0.

Actually, it's not an but. It is feature request. We've got a very simple and working workaround for it so I change priority ti Medium

tags: added: wontfix-feature
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.