Bug 672187

Summary: Improper responsive message when shrinking qcow2 image
Product: Red Hat Enterprise Linux 6 Reporter: Shirley Zhou <szhou>
Component: qemu-kvmAssignee: Kevin Wolf <kwolf>
Status: CLOSED ERRATA QA Contact: Virtualization Bugs <virt-bugs>
Severity: medium Docs Contact:
Priority: medium    
Version: 6.1CC: michen, mkenneth, mshao, virt-maint
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: qemu-kvm-0.12.1.2-2.134.el6 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-05-19 11:29:38 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 580953    

Description Shirley Zhou 2011-01-24 10:48:27 UTC
Description of problem:
Improper responsive messages when shrinking qcow2 image

Version-Release number of selected component (if applicable):
qemu-kvm-0.12.1.2-2.129.el6.x86_64

+++ This bug was initially created as a clone of Bug #613893 +++

While this bug reproduce when truncate size smaller than initiate size.
# qemu-img create -f qcow2 test.img 2G
Formatting 'test.img', fmt=qcow2 size=2147483648 encryption=off cluster_size=0 
# qemu-io test.img
qemu-io> truncate 1G
truncate: Unknown error 18446744073709551521

BTW this issue does not exist on raw format.

So change status to assigned.

--- Additional comment from kwolf on 2011-01-19 09:32:06 EST ---

qcow2 only supports growing images, not shrinking. So this is the expected result (except that qemu-io doesn't get the right error message).

--- Additional comment from szhou on 2011-01-19 21:30:23 EST ---

(In reply to comment #10)
> qcow2 only supports growing images, not shrinking. So this is the expected
> result (except that qemu-io doesn't get the right error message).

Kevin, would you prefer fix this error message on this bug or prefer open a separate one?

--- Additional comment from szhou on 2011-01-24 05:38:26 EST ---

(In reply to comment #10)
> qcow2 only supports growing images, not shrinking. So this is the expected
> result (except that qemu-io doesn't get the right error message).

According to comment 9 and comment 10, this issue has already been fixed.

And I will open another bug to track error message issue.

Comment 6 Shirley Zhou 2011-02-11 09:11:25 UTC
Verify this bug with qemu-kvm-0.12.1.2-2.144.el6.x86_64 as following

]# qemu-img create -f qcow2 test.img 2G
Formatting 'test.img', fmt=qcow2 size=2147483648 encryption=off cluster_size=0 
# qemu-io test.img
qemu-io> truncate 1G
truncate: Operation not supported

So this bug has been fixed.

Comment 8 Miya Chen 2011-03-10 02:07:18 UTC
move to verified based on comment#6.

Comment 9 errata-xmlrpc 2011-05-19 11:29:38 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHSA-2011-0534.html

Comment 10 errata-xmlrpc 2011-05-19 13:01:16 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHSA-2011-0534.html