nova backup fails to backup an instance with attached volume (libvirt, LVM backed)
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Compute (nova) |
Fix Released
|
Medium
|
Feilong Wang | ||
Juno |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
Description of problem:
An instance has an attached volume, after running the command:
# nova backup <instance id> <backup name> snapshot <rotation (an integer)>
An image has been created (type backup) and the status is stuck in 'queued'.
Version-Release number of selected component (if applicable):
openstack-
openstack-
openstack-
openstack-
openstack-
openstack-
python-
python-
openstack-
How reproducible:
100%
Steps to Reproduce:
1. launch an instance from a volume.
2. backup the instance.
Actual results:
The backup is stuck in queued state.
Expected results:
the backup should be available as an image in Glance.
Additional info:
The nova-compute error & the glance logs are attached.
tags: | added: volumes |
Changed in nova: | |
assignee: | nobody → Fei Long Wang (flwang) |
Changed in nova: | |
milestone: | none → kilo-3 |
Changed in nova: | |
milestone: | kilo-3 → kilo-rc1 |
Changed in nova: | |
milestone: | none → liberty-1 |
status: | Fix Committed → Fix Released |
Changed in nova: | |
milestone: | liberty-1 → 12.0.0 |
So important thing to notice here and is not mentioned by the bug report is that this is reported with CONF.libvirt_ images_ type set to 'lvm'.
Looking at the snapshotting code in the libvirt driver and the line that causes the compute stack trace - when running an LVM backed instance with an attached volume libvirt_ utils.find_ disk method seems to give us the wrong disk back.
It would be good to see the libvirt.xml generated for the offending instance, but seeing how poorly tested the find_disk method is - I would not be surprised that it is in fact the cause of the bug.