Bug 633096 - virt-resize calculates block device size incorrectly, doesn't work with qcow2 target
Summary: virt-resize calculates block device size incorrectly, doesn't work with qcow2...
Keywords:
Status: CLOSED UPSTREAM
Alias: None
Product: Virtualization Tools
Classification: Community
Component: libguestfs
Version: unspecified
Hardware: All
OS: Linux
low
medium
Target Milestone: ---
Assignee: Richard W.M. Jones
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2010-09-12 20:40 UTC by Richard W.M. Jones
Modified: 2011-07-14 19:14 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2011-07-14 19:14:40 UTC
Embargoed:


Attachments (Terms of Use)

Description Richard W.M. Jones 2010-09-12 20:40:27 UTC
Description of problem:

virt-resize calculates the size of the block device using the host file
size.  This is completely wrong and it naturally miscalculates things
like qcow2 targets.  It should instead use the guestfs_blockdev_getsize64
API.

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

1.5.12

How reproducible:

Always.

Steps to Reproduce:
1. Create a qcow2 target file.
2. Try to resize with the qcow2 device as the target.
3.
  
Actual results:

Will fail or say the target image is too small.

Expected results:

Should calculate the target size correctly and thus not fail.

Additional info:

Originally reported by Sean Darcy here:
https://www.redhat.com/archives/libguestfs/2010-September/msg00008.html

Comment 2 Richard W.M. Jones 2010-09-27 16:21:33 UTC
Patch posted:

https://www.redhat.com/archives/libguestfs/2010-September/msg00054.html


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