Don't check flavor disk size when booting from volume
When creating a volume from an image, cinder copies the image metadata
into volume properties. When booting from the volume, we read this
metadata from the volume and use it as image metadata once again.
While fixing the check against min_ram,
change I861a78b5c7efa71e4bf7206d388b8d0d8048c78e introduced a
regression which prevents a user from booting a volume which is larger
than the flavor's disk. As we are not creating this disk, this check
does not make sense. Similarly, it checks the image metadata's
min_disk against the flavor disk size, which is not being used.
This change leaves the image metadata check unaltered when creating a
flavor disk. When booting from a volume, we check min_disk from image
metadata against the actual size of the volume. We don't check the
volume size at all. The check against min_ram is retained unaltered.
Reviewed: https:/ /review. openstack. org/213308 /git.openstack. org/cgit/ openstack/ nova/commit/ ?id=8794b938dcb 983b7c918718807 c2396cb255b4ce
Committed: https:/
Submitter: Jenkins
Branch: stable/kilo
commit 8794b938dcb983b 7c918718807c239 6cb255b4ce
Author: Matthew Booth <email address hidden>
Date: Wed Jul 22 14:56:52 2015 +0100
Don't check flavor disk size when booting from volume
When creating a volume from an image, cinder copies the image metadata
into volume properties. When booting from the volume, we read this
metadata from the volume and use it as image metadata once again.
While fixing the check against min_ram, 1e4bf7206d388b8 d0d8048c78e introduced a
change I861a78b5c7efa7
regression which prevents a user from booting a volume which is larger
than the flavor's disk. As we are not creating this disk, this check
does not make sense. Similarly, it checks the image metadata's
min_disk against the flavor disk size, which is not being used.
This change leaves the image metadata check unaltered when creating a
flavor disk. When booting from a volume, we check min_disk from image
metadata against the actual size of the volume. We don't check the
volume size at all. The check against min_ram is retained unaltered.
Closes-Bug: #1457517 664df571e328760 30246c2a87c a9ba279c87e2508 2b4aa9b3b8)
Closes-Bug: #1459491
Closes-Bug: #1466305
Change-Id: I264493172da20b
(cherry picked from commit 642c986f0636d52