[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-block] [PATCH for-4.1 v2] qemu-img: Saner printing of large fi
From: |
Eric Blake |
Subject: |
Re: [Qemu-block] [PATCH for-4.1 v2] qemu-img: Saner printing of large file sizes |
Date: |
Wed, 17 Apr 2019 11:58:57 -0500 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.6.1 |
On 4/10/19 2:28 PM, Max Reitz wrote:
> On 01.04.19 16:57, Eric Blake wrote:
>> Disk sizes close to INT64_MAX cause overflow, for some pretty
>> ridiculous output:
>>
>> $ ./nbdkit -U - memory size=$((2**63 - 512)) --run 'qemu-img info $nbd'
>> image: nbd+unix://?socket=/tmp/nbdkitHSAzNz/socket
>> file format: raw
>> virtual size: -8388607T (9223372036854775296 bytes)
>> disk size: unavailable
>>
>
> There are more iotests this breaks. First, there is 059 for vmdk, which
> looks just like the rest.
Easy enough; I was able to reproduce.
>
> But for -m32, it gets a bit more difficult. Every size above 999 GB
> (1000 GB gets rounded to 1 TB, which is 2^31 * 512) gets printed as
> "inf [unit]":
Ouch - pre-existing bug in size_to_str(); I'll have to fix that, then
send a v3.
Kevin, do you want to unqueue this from block-next until then?
>
> But regardless of the iotests, we shouldn’t show the size as infinite
> just because of -m32.
Is there an easy docker setup for building -m32?
--
Eric Blake, Principal Software Engineer
Red Hat, Inc. +1-919-301-3226
Virtualization: qemu.org | libvirt.org
signature.asc
Description: OpenPGP digital signature