From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:53089) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V7Oga-0002ti-KP for qemu-devel@nongnu.org; Thu, 08 Aug 2013 07:47:29 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1V7OgQ-0008GZ-OC for qemu-devel@nongnu.org; Thu, 08 Aug 2013 07:47:20 -0400 Received: from smtp2-g21.free.fr ([2a01:e0c:1:1599::11]:60131) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V7OgQ-0008F3-8S for qemu-devel@nongnu.org; Thu, 08 Aug 2013 07:47:10 -0400 Received: from [192.168.4.2] (unknown [82.244.111.82]) (Authenticated sender: revol) by smtp2-g21.free.fr (Postfix) with ESMTPA id 82B8B4B01B1 for ; Thu, 8 Aug 2013 13:47:04 +0200 (CEST) Message-ID: <52038537.40008@free.fr> Date: Thu, 08 Aug 2013 13:47:03 +0200 From: =?ISO-8859-1?Q?Fran=E7ois_Revol?= MIME-Version: 1.0 References: <5203744F.4010407@ramses-pyramidenbau.de> In-Reply-To: <5203744F.4010407@ramses-pyramidenbau.de> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] Using TRIM to shrink qcow2 images List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org On 08/08/2013 12:34, Ralf Ramsauer wrote: > Hi, >=20 > QCOW2 uses a similar idea like file holes (sparse files) on filesystems= [1]. > RAW Images also may use file holes. >=20 > If qemu would support TRIM, then the guest could easily discard and zer= o > all unused blocks. > The host system could detect all unused blocks in a (e.g.) qcow2 image > and shrink it down to its minimum size. >=20 > Did anyone already think about that? >=20 Yes but no time to implement. I believe VirtualBox has some support for TRIM already btw. Fran=E7ois.