> There is a workaround under current design, you can tell glance image's
> size when you create it like following, but you will also meet exception
> when you consuming it such as trigger provisioning since http store can
> not receive remote image with a unusable network link.
>
> glance image-create --name cirros --is-public true --container-format
> bare --disk-format qcow2 --location
> https://launchpad.net/cirros/trunk/0.3.0/+download/cirros-0.3.0-x86_64-disk.img
> --size 123456
Between --size and --checksum, I suppose that's sufficient to validate
an image.
> I'm not sure this is a defect but from end user's perspective this
> behavior is strange, so probably we need import an exception mechanism
> (and related up layer handling) for store 'get_size()'. any thoughts?
I think that if we can't talk to the server, or if the returned image
file is blatantly undersized (smaller than the smallest possible disk
image file) then we should log the problem (if we don't already) and the
image should show a "status" of "ERROR".
The fact that the image shows a status of "active" when it has a size of
zero is really misleading.
On 10/07/2013 08:29 PM, Zhi Yan Liu wrote:
> There is a workaround under current design, you can tell glance image's /launchpad. net/cirros/ trunk/0. 3.0/+download/ cirros- 0.3.0-x86_ 64-disk. img
> size when you create it like following, but you will also meet exception
> when you consuming it such as trigger provisioning since http store can
> not receive remote image with a unusable network link.
>
> glance image-create --name cirros --is-public true --container-format
> bare --disk-format qcow2 --location
> https:/
> --size 123456
Between --size and --checksum, I suppose that's sufficient to validate
an image.
> I'm not sure this is a defect but from end user's perspective this
> behavior is strange, so probably we need import an exception mechanism
> (and related up layer handling) for store 'get_size()'. any thoughts?
I think that if we can't talk to the server, or if the returned image
file is blatantly undersized (smaller than the smallest possible disk
image file) then we should log the problem (if we don't already) and the
image should show a "status" of "ERROR".
The fact that the image shows a status of "active" when it has a size of
zero is really misleading.
Chris