Bug 1214855 - qemu-img: error while compressing sector <NNN>: Input/output error
Summary: qemu-img: error while compressing sector <NNN>: Input/output error
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: qemu
Version: 22
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Fedora Virtualization Maintainers
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
: 1241710 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2015-04-23 16:46 UTC by Richard W.M. Jones
Modified: 2015-08-11 20:37 UTC (History)
13 users (show)

Fixed In Version: qemu-2.3.0-6.fc22
Clone Of:
Environment:
Last Closed: 2015-07-30 00:48:27 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
Compression failure fix (1.86 KB, patch)
2015-06-24 04:59 UTC, Jindrich Makovicka
no flags Details | Diff
Compression failure fix (1.79 KB, patch)
2015-06-24 05:06 UTC, Jindrich Makovicka
no flags Details | Diff

Description Richard W.M. Jones 2015-04-23 16:46:00 UTC
Description of problem:

Converting a VMDK file to compressed qcow2 fails (reliably) in
the same place each time.  It does not appear to be a hardware
problem.

$ qemu-img convert -f vmdk -O qcow2 -c Windows_2012_R2_UEFI-disk1.vmdk Windows_2012_R2_UEFI-disk1.qcow2
qemu-img: error while compressing sector 10036608: Input/output error

Removing the -c [compressed] flag makes it work.

Version-Release number of selected component (if applicable):

qemu-img-2.3.0-0.4.rc3.fc23.x86_64

How reproducible:

100%

Steps to Reproduce:
1. See above.

Additional info:

Unfortunately the test image is enormous and proprietary and can't be
shared outside Red Hat.  I will attempt to upload it and attach a link
for Red Hat associates to this BZ.

Comment 2 Richard W.M. Jones 2015-04-23 19:06:02 UTC
Possibly relevant thread:
https://lists.gnu.org/archive/html/qemu-devel/2013-04/msg02520.html

For this disk image in question:

$ qemu-img info Windows_2012_R2_UEFI-disk1.vmdk
image: Windows_2012_R2_UEFI-disk1.vmdk
file format: vmdk
virtual size: 40G (42949672960 bytes)
disk size: 5.0G
cluster_size: 65536
Format specific information:
    cid: 2951036465
    parent cid: 4294967295
    create type: streamOptimized
    extents:
        [0]:
            compressed: true
            virtual size: 42949672960
            filename: Windows_2012_R2_UEFI-disk1.vmdk
            cluster size: 65536
            format: 

so it is already rounded to cluster size & 64K.

Comment 3 Jindrich Makovicka 2015-06-24 04:59:21 UTC
Created attachment 1042594 [details]
Compression failure fix

Can you please this patch if it helps?

Comment 4 Jindrich Makovicka 2015-06-24 05:06:38 UTC
Created attachment 1042595 [details]
Compression failure fix

Comment 5 Richard W.M. Jones 2015-06-24 10:06:48 UTC
Yes, the patch in comment 4 does fix the problem.

Comment 6 David Woodhouse 2015-06-25 16:33:35 UTC
Do we have a fixed package for F22?

Comment 7 Cole Robinson 2015-06-25 17:23:35 UTC
Patch was only queued today:

https://lists.nongnu.org/archive/html/qemu-devel/2015-06/threads.html

I'll scoop it up in the next build

Comment 8 Jan Kurik 2015-07-15 14:14:47 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 23 development cycle.
Changing version to '23'.

(As we did not run this process for some time, it could affect also pre-Fedora 23 development
cycle bugs. We are very sorry. It will help us with cleanup during Fedora 23 End Of Life. Thank you.)

More information and reason for this action is here:
https://fedoraproject.org/wiki/BugZappers/HouseKeeping/Fedora23

Comment 9 Jim Minter 2015-07-20 10:49:45 UTC
I hope this isn't bad Bugzilla etiquette, but it'd be pretty handy if this were fixed in the F22 qemu-img build.

Comment 10 Richard W.M. Jones 2015-07-20 11:07:00 UTC
The patch went upstream as 3e5feb6202149e8a963a33b911216e40d790f1d7.

I'll do a quick backport in a minute.

Comment 11 Richard W.M. Jones 2015-07-20 11:11:55 UTC
Fix is included in: qemu-2.3.0-6.fc22

Note the fix is included upstream in qemu >= 2.4.0-rc0 so
we don't require a backport for f23 or rawhide.

Comment 12 Fedora Update System 2015-07-20 13:07:22 UTC
qemu-2.3.0-6.fc22 has been submitted as an update for Fedora 22.
https://admin.fedoraproject.org/updates/qemu-2.3.0-6.fc22

Comment 13 Fedora Update System 2015-07-21 08:19:41 UTC
Package qemu-2.3.0-6.fc22:
* should fix your issue,
* was pushed to the Fedora 22 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing qemu-2.3.0-6.fc22'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2015-11886/qemu-2.3.0-6.fc22
then log in and leave karma (feedback).

Comment 14 Fedora Update System 2015-07-30 00:48:27 UTC
qemu-2.3.0-6.fc22 has been pushed to the Fedora 22 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 15 Cole Robinson 2015-08-11 18:33:37 UTC
*** Bug 1241710 has been marked as a duplicate of this bug. ***

Comment 16 Persona non grata 2015-08-11 20:37:23 UTC
I confirm, that qemu-2.3.0.6.fc22 fixes the issue. Thanks.


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