Bug 1909185
Summary: | The error message of "qemu-img convert -r" should advertise the correct maximum number | ||
---|---|---|---|
Product: | Red Hat Enterprise Linux Advanced Virtualization | Reporter: | Xueqiang Wei <xuwei> |
Component: | qemu-kvm | Assignee: | Eric Blake <eblake> |
qemu-kvm sub component: | Storage | QA Contact: | Tingting Mao <timao> |
Status: | CLOSED CURRENTRELEASE | Docs Contact: | |
Severity: | medium | ||
Priority: | medium | CC: | chayang, coli, eblake, jinzhao, juzhang, kwolf, qzhang, virt-maint, xuwei |
Version: | 8.4 | Keywords: | Triaged |
Target Milestone: | rc | ||
Target Release: | 8.4 | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | If docs needed, set a value | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2021-07-20 12:42:25 UTC | Type: | Bug |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: |
Description
Xueqiang Wei
2020-12-18 14:42:34 UTC
Eric - looks perhaps related to commit 43d589b074370ebc9b340340b5f641b385da9df8 which you reviewed and had PULL'd. This bug is due to qemu_strtosz() mishandling more than 53 bits of precision, and will be fixed once this lands upstream: https://lists.gnu.org/archive/html/qemu-devel/2021-02/msg04160.html [PATCH v2 0/4] improve do_strtosz precision Note that the patches mentioned in comment 2 are now upstream, but introduced a rounding regression where 12.345M produces 12344999 bytes in a context using 1000 as the scaling base. Followup patch proposed: https://lists.gnu.org/archive/html/qemu-devel/2021-03/msg04143.html [PATCH] utils: Reduce chance of rounding inaccuracy in qemu_strtosz. Tried with latest qemu package, the bugs seems fixed. Tested with: qemu-kvm-6.0.0-7.el9 kernel-modules-5.13.0-1.el9.x86_64 Steps: # qemu-img convert -f qcow2 -O qcow2 test.qcow2 tgt.qcow2 -r -1 -p qemu-img: Invalid rate limit specified. You may use k, M, G, T, P or E suffixes for qemu-img: kilobytes, megabytes, gigabytes, terabytes, petabytes and exabytes. # qemu-img convert -f qcow2 -O qcow2 test.qcow2 tgt.qcow2 -r 0 -p (100.00/100%) # qemu-img convert -f qcow2 -O qcow2 test.qcow2 tgt.qcow2 -r 9223372036854775807 -p --------------------------> The maximum number works now. (100.00/100%) # qemu-img convert -f qcow2 -O qcow2 test.qcow2 tgt.qcow2 -r 9223372036854775808 -p qemu-img: Invalid rate limit specified. Must be between 0 and 9223372036854775807. |