Hide Forgot
+++ This bug was initially created as a clone of Bug #1196688 +++ Description of problem: bdrv_make_zero() clamps the nb_sectors value: if (nb_sectors > INT_MAX) { nb_sectors = INT_MAX; } But INT_MAX is too large because bdrv_rw_co() performs the following check later: if (nb_sectors < 0 || nb_sectors > INT_MAX / BDRV_SECTOR_SIZE) { return -EINVAL; } Fam Zheng already fixed this bug upstream so we just need to backport the fix: http://git.qemu-project.org/?p=qemu.git;a=commitdiff;h=f3a9cfddaec127078ac1898de6b063db8ac3bb48 How reproducible: Deterministic Steps to Reproduce: 1. qemu-img create input.img 2G 2. qemu-img create output.img 2G 3. sudo losetup -f output.img 4. qemu-img convert -t none -O raw input.img /dev/loop0 Actual results: qemu-img: error writing zeroes at sector 0: Invalid argument Expected results: Success from qemu-img convert. --- Additional comment from Stefan Hajnoczi on 2015-02-27 07:18:16 EST --- --- Additional comment from Stefan Hajnoczi on 2015-03-06 17:35:37 EST --- Set state to modified. The patch will come into RHEL 7.2 qemu-kvm from upstream via rebase. --- Additional comment from Dan Prince on 2015-03-09 08:37:31 EDT --- This same issue effects Fedora 21 as well and is displayed when trying to use OpenStack Cinder to convert Glance images. Could we backport the fix into Fedora 21 as well (it is preventing upstream CI from using Fedora ATM).
Already working on backporting this, the patch is trivial and should not affect stable branches.
qemu-2.1.3-3.fc21 has been submitted as an update for Fedora 21. https://admin.fedoraproject.org/updates/qemu-2.1.3-3.fc21
qemu-2.1.3-3.fc21 has been pushed to the Fedora 21 stable repository. If problems still persist, please make note of it in this bug report.
Looks like the security fixes in qemu-2.1.3-5.fc21 have caused a regression. We are once again hitting this issue in Fedora 21 stable.
ugh, apologies, I accidentally dropped haikel's patch when pushed the next update. I'll do a build now
nm looks like haikel got to it first
qemu-2.1.3-6.fc21 has been submitted as an update for Fedora 21. https://admin.fedoraproject.org/updates/qemu-2.1.3-6.fc21
qemu-2.1.3-6.fc21 has been pushed to the Fedora 21 stable repository. If problems still persist, please make note of it in this bug report.