Comment 3 for bug 1653080

Revision history for this message
Lee Yarwood (lyarwood) wrote :

My apologies, I assumed we were talking about resizing up and I had to re-read your description to see that this was actually about resizing down. The following review moved _is_booted_from_volume to use block_device_info and appears to correct this on master, I'll look into a stable/newton backport shortly :

libvirt: Improve _is_booted_from_volume implementation
https://review.openstack.org/#/c/382024/

Again using my local env this now WORKSFORME when I attempt to resize down :

$ sudo rbd -p vms ls -l
NAME SIZE PARENT FMT PROT LOCK
67e542f2-6a21-4363-818b-4ed58be529dd_disk 5120M images/ec027d6b-f677-40fd-b3c9-f0d30ef460de@snap 2
$ nova resize test-resize 1
$ grep ResizeError ../logs/n-cpu.log
2017-01-04 08:13:24.779 TRACE oslo_messaging.rpc.server ResizeError: Resize error: Unable to resize disk down.
$ sudo rbd -p vms ls -l
NAME SIZE PARENT FMT PROT LOCK
67e542f2-6a21-4363-818b-4ed58be529dd_disk 5120M images/ec027d6b-f677-40fd-b3c9-f0d30ef460de@snap 2