From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LCHw4-00037J-CM for qemu-devel@nongnu.org; Mon, 15 Dec 2008 13:12:52 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1LCHw0-00034r-7g for qemu-devel@nongnu.org; Mon, 15 Dec 2008 13:12:51 -0500 Received: from [199.232.76.173] (port=41504 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LCHw0-00034i-21 for qemu-devel@nongnu.org; Mon, 15 Dec 2008 13:12:48 -0500 Received: from mx2.suse.de ([195.135.220.15]:38357) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1LCHvz-0008WS-GR for qemu-devel@nongnu.org; Mon, 15 Dec 2008 13:12:47 -0500 Received: from Relay2.suse.de (relay-ext.suse.de [195.135.221.8]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mx2.suse.de (Postfix) with ESMTP id A3E304853D for ; Mon, 15 Dec 2008 19:12:41 +0100 (CET) Message-ID: <49469F31.5080508@suse.de> Date: Mon, 15 Dec 2008 19:17:21 +0100 From: Kevin Wolf MIME-Version: 1.0 Subject: Re: [Qemu-devel][PATCH] Qemu image over raw devices References: <494663E4.3020409@redhat.com> In-Reply-To: <494663E4.3020409@redhat.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Shahar Frank schrieb: > The following patch enables QEMU to create and use images with any > format on top of a raw device. Note that -f is not enough for > bcking files support. When would I need to explicitly specify the type of a backing file? > The patch includes the following: > > 1. The check for block devices is weaken so you can override it by > specifying a protocol > 2. If a protocol exists but not found in the protocols list, the logic > falls back to image type probing. This means use can write > "probe:filename" or just ":filename" IIUC, on qemu side this is just another syntax for -drive format=xyz? Wouldn't it be better to add a parameter to qemu-img then instead of inventing new ways of specifying the format? > Note that if regular file/device path names are used, the previous > behavior is kept. > > lvcreate -L 5G -n base store > dd bs=32k if=win.qcow2 of=/dev/store/base > ./qemu-img info :/dev/store/base > lvcreate -L 2G -n l2 store > ./qemu-img create -b :/dev/store/base -f qcow2 /dev/store/l2 > ./x86_64-softmmu/qemu-system-x86_64 -hda :/dev/store/l2 -L pc-bios/ > lvcreate -L 2G -n l3 store > ./qemu-img create -b :/dev/store/l2 -f qcow2 /dev/store/l3 > ./x86_64-softmmu/qemu-system-x86_64 -hda :/dev/store/l3 -L pc-bios/ Does it even make sense to store qcow2 images on raw block devices? qcow2 are usually growing whereas devices tend to not change their size. Kevin