From: Serge Hallyn <1025244@bugs.launchpad.net>
To: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [Bug 1025244] Re: qcow2 image increasing disk size above the virtual limit
Date: Wed, 17 Dec 2014 19:02:37 -0000 [thread overview]
Message-ID: <20141217190237.GF32218@ubuntumail> (raw)
In-Reply-To: 20141216125112.30835.26875.malone@chaenomeles.canonical.com
@Mario,
the external snapshots have apparently been around a long time. The
ability to create external snapshots from running vms is newer, but
it appears to exist evn in qemu-kvm 1.0. So all versions in Debian
and Ubuntu should support them.
http://wiki.qemu.org/Features/Snapshots#Snapshot_command_flow
--
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1025244
Title:
qcow2 image increasing disk size above the virtual limit
Status in QEMU:
New
Status in qemu-kvm package in Ubuntu:
Triaged
Bug description:
Using qemu/kvm, qcow2 images, ext4 file systems on both guest and host
Host and Guest: Ubuntu server 12.04 64bit
To create an image I did this:
qemu-img create -f qcow2 -o preallocation=metadata ubuntu-pdc-vda.img 10737418240 (not sure about the exact bytes, but around this)
ls -l ubuntu-pdc-vda.img
fallocate -l theSizeInBytesFromAbove ubuntu-pdc-vda.img
The problem is that the image is growing progressively and has
obviously no limit, although I gave it one. The root filesystem's
image is the same case:
qemu-img info ubuntu-pdc-vda.img
image: ubuntu-pdc-vda.img
file format: qcow2
virtual size: 10G (10737418240 bytes)
disk size: 14G
cluster_size: 65536
and for confirmation:
du -sh ubuntu-pdc-vda.img
15G ubuntu-pdc-vda.img
I made a test and saw that when I delete something from the guest, the real size of the image is not decreasing (I read it is normal). OK, but when I write something again, it doesn't use the freed space, but instead grows the image. So for example:
1. The initial physical size of the image is 1GB.
2. I copy 1GB of data in the guest. It's physical size becomes 2GB.
3. I delete this data (1GB). The physical size of the image remains 2GB.
4. I copy another 1GB of data to the guest.
5. The physical size of the image becomes 3GB.
6. And so on with no limit. It doesn't care if the virtual size is less.
Is this normal - the real/physical size of the image to be larger than
the virtual limit???
To manage notifications about this bug go to:
https://bugs.launchpad.net/qemu/+bug/1025244/+subscriptions
next prev parent reply other threads:[~2014-12-17 19:11 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20120716123031.26191.29124.malonedeb@chaenomeles.canonical.com>
2012-07-17 13:41 ` [Qemu-devel] [Bug 1025244] Re: qcow2 image increasing disk size above the virtual limit Serge Hallyn
2012-12-18 10:18 ` Andy Menzel
2013-01-02 15:50 ` Stefan Hajnoczi
2013-01-02 16:07 ` Eric Blake
2012-12-19 17:12 ` Serge Hallyn
2013-01-11 13:06 ` Andy Menzel
2014-12-12 16:37 ` Mario
2014-12-14 14:01 ` Michael Tokarev
2014-12-15 16:38 ` Serge Hallyn
2014-12-15 19:40 ` Mario
2014-12-15 20:37 ` Serge Hallyn
2014-12-16 9:23 ` Max Reitz
2014-12-16 12:51 ` Mario
2014-12-17 19:02 ` Serge Hallyn [this message]
2018-04-04 17:52 ` Thomas Huth
2018-06-04 4:17 ` Launchpad Bug Tracker
2018-06-04 4:17 ` Launchpad Bug Tracker
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20141217190237.GF32218@ubuntumail \
--to=1025244@bugs.launchpad.net \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).