backup instance won't be able to delete all images exceeding rotation limit, if user mistakenly deletes one of the backup image
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Compute (nova) |
Fix Released
|
Low
|
Bhagyashri Shewale | ||
Newton |
Fix Committed
|
Low
|
Lee Yarwood |
Bug Description
If user have already backed up instance to few numbers and then execute
backup api with rotation 1, then nova will delete the previously
created images exceeding rotation limit.
During deleting these images, if user mistakenly deletes one of the
image in advance, then backup instance won't be able to delete all
images exceeding rotation limit causing api failure.
Steps to reproduce:
1. Create instance
$ nova boot --flavor <flavor_id> --image <image_id> <server_name>
$ nova boot --flavor 1 --image cirros-
+----
| ID | Name | Status | Task State | Power State | Networks |
+----
| a9e41bc5-
+----
2. Create 5 instance backup using the backup api(hit below command 5 times)
$ nova backup <server> <name> <backup-type> <rotation>
$ nova backup a9e41bc5-
3. Take list of backup images
$ glance image-list
+----
| ID | Name |
+----
| c33790be-
| de43a375-
| 0a6c800e-
| fc0d2030-
| a9d7dc78-
| 937061b4-
| 41e25c26-
| a15ae46a-
+----
4. Add debug point using pdb.set_trace() in nova.compute.
5. Delete one of the backup images from above list
$ glance image-delete fc0d2030-
6. Create the insatnce backup by passing the rotation parameter value as 1.
$ nova backup a9e41bc5-
7. Checked the n-cpu logs
2016-10-17 15:59:38.978 ERROR oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
2016-10-17 15:59:38.978 TRACE oslo_messaging.
[1] https:/
Changed in nova: | |
assignee: | Bhagyashri Shewale (bhagyashri-shewale) → Michael Still (mikal) |
Changed in nova: | |
assignee: | Michael Still (mikal) → Bhagyashri Shewale (bhagyashri-shewale) |
Changed in nova: | |
importance: | Undecided → Low |
tags: | added: compute |
Changed in nova: | |
assignee: | Bhagyashri Shewale (bhagyashri-shewale) → melanie witt (melwitt) |
Changed in nova: | |
assignee: | melanie witt (melwitt) → Bhagyashri Shewale (bhagyashri-shewale) |
Fix proposed to branch: master /review. openstack. org/388519
Review: https:/