From mboxrd@z Thu Jan 1 00:00:00 1970 From: Laurent Vivier Subject: Re: [Qemu-devel] Re: [RFC][PATCH] Modify loop device to be able to manage partitions of the image disk Date: Wed, 16 Jan 2008 01:30:43 +0100 Message-ID: <1200443443.4602.32.camel@frecb07144> References: <120042137328-git-send-email-Laurent.Vivier@bull.net> <20080115182745.GY17783@redhat.com> <1200440406.4602.16.camel@frecb07144> <20080115235438.GB30528@redhat.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============1878076381==" Cc: kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org To: "Daniel P. Berrange" , qemu-devel-qX2TKyscuCcdnm+yROfE0A@public.gmane.org Return-path: In-Reply-To: <20080115235438.GB30528-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: kvm-devel-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org Errors-To: kvm-devel-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org List-Id: kvm.vger.kernel.org --===============1878076381== Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="=-pOLjfkNoad0xEdB0YIVW" --=-pOLjfkNoad0xEdB0YIVW Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Le mardi 15 janvier 2008 =C3=A0 23:54 +0000, Daniel P. Berrange a =C3=A9cri= t : > On Wed, Jan 16, 2008 at 12:40:06AM +0100, Laurent Vivier wrote: > > Le mardi 15 janvier 2008 =C3=A0 18:27 +0000, Daniel P. Berrange a =C3= =A9crit : > > > On Tue, Jan 15, 2008 at 07:22:53PM +0100, Laurent Vivier wrote: > > > > As it should be useful to be able to mount partition from a=20 > > > > disk image, (and as I need a break in my bug hunting) I've=20 > > > > modified the loop driver to mount raw disk image. > > > >=20 > > > > To not break original loop device, as we have to change minor=20 > > > > numbers to manage partitions, a new parameter is added to the modul= e: > > >=20 > > > I don't see the point in modifying the loop device driver when you > > > can already access the partitions with existing device mapper > > > functionality & tools. > >=20 > > There are two reasons: > >=20 > > 1- I didn't know kpartx (thank you for the tip) > >=20 > > but using loop device, you will be able to use all partition tables > > known by the kernel (acorn, atari, efi, karma, mac, osf, sun, > > ultrix, amiga, ibm, ldm, msdos, sgi, sysv68), whereas kpartx can use > > only partition tables it knows (bsd, dasd, dos, mac, sun, efi, sun, > > unixware). >=20 > This is an argument for extending kpartx to cope with the other > partition tables :-) I have 50/50 split between VMs using files Good try... but IMHO, I think it is better to let the kernel decode the partition table... > vs VMs using LVM volumes - the loop driver patches only help you > access partitions within a file based image, whereas kpartx can > access the partitions within any block device, so can support=20 > files (via existing loop device) & LVM vols & nested partitions. I think you're wrong (but you seem to know the subject better than me, so ...): you should be able to use the modified loop device on the logical volume to decode partition table. >=20 > > 2- I'd like to mount qcow2 or others disk image formats, so perhaps it'= s > > easier to modify loop device driver (but perhaps you know another magic > > tool ?) >=20 > There has been some work in this area wrt to Xen - the DM-Userspace proje= ct > had some working code providing a device mapper target calling out to a=20 > userspace daemon to handle non-raw file formats like qcow. I don't > know what the state of it is now wrt to upstream kernel / device-mapper, > or even whether it is more than just 'proof of concept', but the project > page is here with some info: >=20 > http://wiki.xensource.com/xenwiki/DmUserspace It seems a very good idea, but what I don't like: - it seems very complex (like IBM guys like ;-) ) - it is one and a half year old To be honest, if something good already exists, I take it... Laurent --=20 ----------------- Laurent.Vivier-6ktuUTfB/bM@public.gmane.org ------------------ "La perfection est atteinte non quand il ne reste rien =C3=A0 ajouter mais quand il ne reste rien =C3=A0 enlever." Saint Exup=C3=A9ry --=-pOLjfkNoad0xEdB0YIVW Content-Type: application/pgp-signature; name=signature.asc Content-Description: Ceci est une partie de message =?ISO-8859-1?Q?num=E9riquement?= =?ISO-8859-1?Q?_sign=E9e?= -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.6 (GNU/Linux) iD8DBQBHjVAz9Kffa9pFVzwRAgQUAJwMITKjIZpQ3xc7rn3aaqM4etx+UQCfV8iP 5ya1C/J1nuTzZiinIXxZyrA= =bczC -----END PGP SIGNATURE----- --=-pOLjfkNoad0xEdB0YIVW-- --===============1878076381== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ --===============1878076381== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ kvm-devel mailing list kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org https://lists.sourceforge.net/lists/listinfo/kvm-devel --===============1878076381==--