Bug 783184 - storage cloning ignores "sparse" and creates non-sparse disk images
Summary: storage cloning ignores "sparse" and creates non-sparse disk images
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: libvirt
Version: 6.3
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: rc
: ---
Assignee: Cole Robinson
QA Contact: Virtualization Bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-01-19 15:59 UTC by Marian Csontos
Modified: 2012-08-16 05:39 UTC (History)
10 users (show)

Fixed In Version: libvirt-0.9.10-1.el6
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-06-20 06:46:56 UTC
Target Upstream Version:


Attachments (Terms of Use)
virt-clone log with --debug (5.51 KB, text/plain)
2012-02-03 07:43 UTC, zhe peng
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2012:0748 0 normal SHIPPED_LIVE Low: libvirt security, bug fix, and enhancement update 2012-06-19 19:31:38 UTC

Description Marian Csontos 2012-01-19 15:59:59 UTC
Description of problem:
virt-clone ignores "sparse" and creates non-sparse disk images

Version-Release number of selected component (if applicable):
python-virtinst-0.600.0-5.el6.noarch

How reproducible:
100%

Steps to Reproduce:
1. clone sparse VM
2. run stat and compare blocks allocated
  
Actual results:
cloned image is non sparse - the amount of blocks is several times bigger than original.

Expected results:
cloned image is sparse

Additional info:
I have not done any investigation on older versions.

Comment 2 Cole Robinson 2012-01-25 21:57:24 UTC
Please provide output of virt-clone --debug when reproducing

Comment 4 zhe peng 2012-02-03 07:43:33 UTC
Created attachment 559242 [details]
virt-clone log with --debug

Comment 5 Cole Robinson 2012-02-07 19:54:18 UTC
This is a libvirt bug, patch forthcoming.

Comment 10 zhe peng 2012-02-14 09:59:58 UTC
verify with:
libvirt-0.9.10-1.el6.x86_64
python-virtinst-0.600.0-7.el6.noarch

step same with comment 3
before clone:
# du v1.img 
2871456	v1.img
# stat v1.img 
  File: `v1.img'
  Size: 6291456000	Blocks: 5742912    IO Block: 4096   regular file
Device: 805h/2053d	Inode: 2885429     Links: 1
Access: (0644/-rw-r--r--)  Uid: (    0/    root)   Gid: (    0/    root)
Access: 2012-02-14 04:50:59.918362545 -0500
Modify: 2012-02-14 04:50:04.372426169 -0500
Change: 2012-02-14 04:50:30.955113070 -0500
after clone:
# du v1-clone.img 
749936	v1-clone.img
# stat v1-clone.img 
  File: `v1-clone.img'
  Size: 6291456000	Blocks: 1499872    IO Block: 4096   regular file
Device: 805h/2053d	Inode: 2885438     Links: 1
Access: (0644/-rw-r--r--)  Uid: (  107/    qemu)   Gid: (  107/    qemu)
Access: 2012-02-14 04:53:43.038592256 -0500
Modify: 2012-02-14 04:57:14.586157421 -0500
Change: 2012-02-14 04:57:14.586157421 -0500

the cloned image is sparse,verification passed.
move to verified.

Comment 13 errata-xmlrpc 2012-06-20 06:46:56 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHSA-2012-0748.html

Comment 14 MATSUU Takuto 2012-08-16 05:39:24 UTC
It seems that even if I set --nonsparse option, virt-clone always creates sparse disk image.


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