Comment 0 for bug 1587802

Revision history for this message
Yang Shengming (yang-shengming) wrote :

when using ceph as backend, instance can resize to a smaller flavor, and vm_state become error in the end.

nova/virt/libvirt/driver.py:
    @staticmethod
    def _is_booted_from_volume(instance, disk_mapping):
        """Determines whether the VM is booting from volume

        Determines whether the disk mapping indicates that the VM
        is booting from a volume.
        """
        return ((not bool(instance.get('image_ref')))
                or 'disk' not in disk_mapping)

when using rbd as backend, the function cannot find 'disk' in disk_mapping, and treat it as booted_from_volume