Hello OpenStack Community,
I'm part of the StarlingX Community and our starlingx-openstack distribution is currently delivering the 2024.1 (Caracal) release. We were exploring the openstack-client "server rebuild" feature [1], and we might have found a bug. So, I'm writing this email
to explain our current issue and get feedback on this new Launchpad we are creating for the Nova component
https://bugs.launchpad.net/nova/+bug/2114855 [2].
It happened in the following scenario:
-
Create a VM with some small disk flavor and a small image. For example, using a flavor of 1 GB with the Cirros image (~ 21 MB of disk size).
-
Try to rebuild the VM using a new image. Example: the ubuntu-jammy qcow image.
When the steps above are executed with an image with a disk size greater than the flavor size, the Nova API returns an error and the VM is not rebuilt:
Flavor's disk is too small for requested image. Flavor disk is 1073741824 bytes, image is 1283063808 bytes. (HTTP 400) (Request-ID: req-7db974bb-15f3-425f-b97b-98b789b7e10f)
But when we use an image with a disk size smaller than the flavor disk size, but with a virtual size bigger than the flavor disk size, Nova will try to rebuild the VM and fail: the VM state will be ERROR.
It looks like the Nova API is accepting such rebuild requests, but when Nova Compute checks for virtual size, it fails.
Is that expected behavior? Shouldn't the Nova API reject the request with an explicit warning telling the user to resize the VM before trying to rebuild?
Thank you very much
Description =========== Openstackclient + Nova API accept to rebuild server with virtual size greater than the specified flavor’s disk size. Steps to Reproduce ================== 1 - Create a server specifying a flavor with small disk size (example: 1 GB) and
an image small enough to fit. openstack flavor create --ram 512 --disk 1 --vcpus 1 tiny openstack server create –flavor tiny –image cirros vm-test 2 - Try to rebuild the server using a larger image but that still fits. It’s v...
bugs.launchpad.net
|