Bug 1169045
| Summary: | virt-sparsify: libguestfs error: qemu-img info: 'virtual-size' is not representable as a 64 bit integer | ||
|---|---|---|---|
| Product: | [Community] Virtualization Tools | Reporter: | Richard W.M. Jones <rjones> |
| Component: | libguestfs | Assignee: | Richard W.M. Jones <rjones> |
| Status: | CLOSED NOTABUG | QA Contact: | |
| Severity: | unspecified | Docs Contact: | |
| Priority: | unspecified | ||
| Version: | unspecified | CC: | mbooth, ptoscano, rbalakri |
| Target Milestone: | --- | ||
| Target Release: | --- | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| Whiteboard: | |||
| Fixed In Version: | Doc Type: | Bug Fix | |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2014-11-29 11:54:33 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: | |||
Reproducer: $ guestfish -N disk:10G disk-virtual-size test1.img (Note this doesn't reproduce the problem for me, but the original reporter has confirmed that it is a reproducer) Thanks to muued for also chasing up the fix. It turned out to be a yajl bug, fixed by: https://github.com/lloyd/yajl/commit/b0ea41643e411730b8411e282b229d98d5eb38b6 (or updating to yajl >= 2.0.4) |
Description of problem: (Reported by muued on IRC) Using it for my 10GiB image results in the following message: virt-sparsify: libguestfs error: qemu-img info: 'virtual-size' is not representable as a 64 bit integer From the debug output: libguestfs: parse_json: qemu-img info JSON output:\n{\n "virtual-size": 10737418240, \n "filename": "/dev/fd/4", \n "cluster-size": 65536, \n "format": "qcow2", \n "actual-size": 9651417088, \n "format-specific": {\n "type": "qcow2", \n "data": {\n "compat": "0.10"\n }\n }, \n "dirty-flag": false\n}\n\n libguestfs: trace: disk_virtual_size = -1 (error) Version-Release number of selected component (if applicable): qemu 2.1.2 yajl 2.0.3 virt-sparsify 1.26.1 64 bit host How reproducible: Unknown. Additional information: The error message comes from libguestfs.git/src/info.c: len = YAJL_GET_OBJECT(tree)->len; for (i = 0; i < len; ++i) { if (STREQ (YAJL_GET_OBJECT(tree)->keys[i], "virtual-size")) { yajl_val node = YAJL_GET_OBJECT(tree)->values[i]; if (YAJL_IS_NULL (node)) goto bad_type; if (! YAJL_IS_NUMBER (node)) goto bad_type; if (! YAJL_IS_INTEGER (node)) { error (g, _("qemu-img info: 'virtual-size' is not representable as a 64 bit integer")); return -1; } return YAJL_GET_INTEGER (node); } }