qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [Bug 660366] [NEW] "qemu-img convert -O qcow2 -o backing_file" makes huge images
@ 2010-10-14  8:28 Ildar
  2010-10-14  9:25 ` [Qemu-devel] [Bug 660366] " Stefan Hajnoczi
                   ` (8 more replies)
  0 siblings, 9 replies; 12+ messages in thread
From: Ildar @ 2010-10-14  8:28 UTC (permalink / raw)
  To: qemu-devel

Public bug reported:

$ dd if=/dev/urandom bs=1M of=1.img count=4
4+0 records in
4+0 records out
4194304 bytes (4,2 MB) copied, 1,0413 s, 4,0 MB/s
$ qemu-img create -f qcow2 -b 1.img 2.img
Formatting '2.img', fmt=qcow2 size=4194304 backing_file='1.img' encryption=off cluster_size=0 
$ qemu-img convert -O qcow2 -o backing_file=1.img 2.img 3.img
$ du -h ?.img
4,1M	1.img
144K	2.img
4,3M	3.img

The conversion result is bigger then the source!

It appears that "-o backing_file" is not applied to data (as expected).
I.e. all data is put into the resulting image: both from source image
and "backing" image.

Expected behavior is to put only data that is not present in
backing_file.

** Affects: qemu
     Importance: Undecided
         Status: New

-- 
"qemu-img convert -O qcow2 -o backing_file" makes huge images
https://bugs.launchpad.net/bugs/660366
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.

Status in QEMU: New

Bug description:
$ dd if=/dev/urandom bs=1M of=1.img count=4
4+0 records in
4+0 records out
4194304 bytes (4,2 MB) copied, 1,0413 s, 4,0 MB/s
$ qemu-img create -f qcow2 -b 1.img 2.img
Formatting '2.img', fmt=qcow2 size=4194304 backing_file='1.img' encryption=off cluster_size=0 
$ qemu-img convert -O qcow2 -o backing_file=1.img 2.img 3.img
$ du -h ?.img
4,1M	1.img
144K	2.img
4,3M	3.img

The conversion result is bigger then the source!

It appears that "-o backing_file" is not applied to data (as expected). I.e. all data is put into the resulting image: both from source image and "backing" image.

Expected behavior is to put only data that is not present in backing_file.

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2015-08-11 10:15 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-10-14  8:28 [Qemu-devel] [Bug 660366] [NEW] "qemu-img convert -O qcow2 -o backing_file" makes huge images Ildar
2010-10-14  9:25 ` [Qemu-devel] [Bug 660366] " Stefan Hajnoczi
2010-10-14  9:41 ` Ildar
2010-10-14 10:56 ` Stefan Hajnoczi
2010-10-14 12:26 ` Anthony Liguori
2010-10-14 12:51   ` Stefan Hajnoczi
2010-10-14 12:59     ` Anthony Liguori
2013-05-23  7:56 ` Ildar
2013-05-23  8:08 ` Ildar
2015-08-10 12:37 ` sakishrist
2015-08-11  9:42 ` Kevin Wolf
2015-08-11 10:08 ` sakishrist

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).