Bug 974058 - qcow2 images size reported by glance should match the virtual image size
Summary: qcow2 images size reported by glance should match the virtual image size
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Red Hat OpenStack
Classification: Red Hat
Component: openstack-glance
Version: 4.0
Hardware: Unspecified
OS: Unspecified
unspecified
low
Target Milestone: async
: 5.0 (RHEL 7)
Assignee: Flavio Percoco
QA Contact: Giulio Fidente
URL:
Whiteboard:
Depends On: 1048174
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-06-13 11:10 UTC by Giulio Fidente
Modified: 2023-09-14 01:45 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-01-15 08:22:54 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Launchpad 1190559 0 None None None Never

Description Giulio Fidente 2013-06-13 11:10:35 UTC
Description of problem:
the image size of qcow2 images should match the virtual size reported by qemu-img not the actual data size

# glance image-show ff8f8fb3-76a3-47c0-bfc2-7bbbb9e46950
[...]
| size | 699592704 |
[...]

# qemu-img info /var/lib/glance/images/ff8f8fb3-76a3-47c0-bfc2-7bbbb9e46950
image: /var/lib/glance/images/ff8f8fb3-76a3-47c0-bfc2-7bbbb9e46950
file format: qcow2
virtual size: 6.0G (6442450944 bytes)
disk size: 667M
cluster_size: 65536


Version-Release number of selected component (if applicable):
openstack-glance-2013.1.2-1.el6ost.noarch

Comment 1 John Bresnahan 2013-06-24 19:47:37 UTC
The right fix for this is dependent upon more complicated work that is underway for havana.  There is an import/export effort in which incoming images can be verified/converted as opposed to just uploaded.  This is a very good place to verify things like the image size.  This is also coupled with the async workers blueprint: https://blueprints.launchpad.net/glance/+spec/async-glance-workers.

Comment 2 Flavio Percoco 2013-11-29 10:24:04 UTC
Also, I'd argue that using the size field is the right thing to do. The size is also important to know what the file size is. For example, using the image size instead of the file size would break all features that rely on that (Progress bar, for example).

It may be necessary to explicitly differentiate the image_size from the file_size, which in many cases will be the same.

Comment 3 Flavio Percoco 2013-12-13 09:34:24 UTC
This will be fixed as part of this blueprint:

https://blueprints.launchpad.net/glance/+spec/split-image-size

Comment 4 Flavio Percoco 2014-01-15 08:22:54 UTC
I'm closing this as WONTFIX because the image size won't match the virtual_size. Instead, the proposed blueprint will add a new virtual_size attribute that will hold this information.

Comment 5 Summer Long 2014-07-23 04:25:12 UTC
Flavio, I'm moving requires_doc_text to - since nothing was done. Unless you you want to set it as a Known Issue with text? Is there a specific user problem that you'd like to point out? (Release notes are regenerated with each maintenance release if you want to include info.)

Comment 6 Red Hat Bugzilla 2023-09-14 01:45:31 UTC
The needinfo request[s] on this closed bug have been removed as they have been unresolved for 1000 days


Note You need to log in before you can comment on or make changes to this bug.