WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

RE: [Xen-devel] [PATCH] make qemu handle drbd properly

To: <rshriram@xxxxxxxxx>, "Ian Jackson" <Ian.Jackson@xxxxxxxxxxxxx>
Subject: RE: [Xen-devel] [PATCH] make qemu handle drbd properly
From: "James Harper" <james.harper@xxxxxxxxxxxxxxxx>
Date: Tue, 30 Aug 2011 14:40:43 +1000
Cc: xen-devel@xxxxxxxxxxxxxxxxxxx
Delivery-date: Mon, 29 Aug 2011 21:41:43 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <CAP8mzPNFWXMbVU1FxFncXB6q390L2WaBNcoVKuikzMFbdOnTKA@xxxxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <AEC6C66638C05B468B556EA548C1A77D01BB92B8@trantor> <BANLkTind3O2QvpLE4VN08SBBOMvdZe7QwA@xxxxxxxxxxxxxx> <19977.52972.272583.269113@xxxxxxxxxxxxxxxxxxxxxxxx> <CAP8mzPNFWXMbVU1FxFncXB6q390L2WaBNcoVKuikzMFbdOnTKA@xxxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Thread-index: AcxmywuNyuIYqcnmSwaWE2Ia8JzxgwAAihNA
Thread-topic: [Xen-devel] [PATCH] make qemu handle drbd properly
> -----Original Message-----
> From: Shriram Rajagopalan [mailto:rshriram@xxxxxxxxx]
> Sent: Tuesday, 30 August 2011 14:11
> To: Ian Jackson
> Cc: James Harper; xen-devel@xxxxxxxxxxxxxxxxxxx
> Subject: Re: [Xen-devel] [PATCH] make qemu handle drbd properly
> 
> On Tue, Jun 28, 2011 at 8:54 AM, Ian Jackson
<Ian.Jackson@xxxxxxxxxxxxx>
> wrote:
> > Shriram Rajagopalan writes ("Re: [Xen-devel] [PATCH] make qemu
handle drbd
> properly"):
> >> On Wed, Jan 26, 2011 at 11:43 PM, James Harper <
> >> james.harper@xxxxxxxxxxxxxxxx> wrote:
> >> > This attached patch allows qemu to accept a drbd: prefix and
interpret
> >> > it as a drbd resource. It then searches for it in
/dev/drbd/by-res/
> >> > (which must be mapped via udev). It's against 4.0-testing.
> > ...
> >> Sorry to dig up an old thread. This patch doesnt seem to be in any
of the
> >> qemu-xen-*, xen-*-testing or xen-unstable trees. Any reason why?
> >
> > I don't think we're going to introduce a new feature of this kind
into
> > qemu-xen-unstable at this stage.
> >
> > Sorry,
> > Ian.
> >
> 
> Hi Ian,
>  can you please include this patch into qemu-xen-unstable ?
>  The last time I requested that this patch be included into
qemu-xen-unstable,
> it was too late. I hope I am not late again this time. :)
> Please let me know if you need a more formal version of this patch.
> 

While this patch works great, I'd like to see a more generic mechanism
for passing different backends into qemu when they are fundamentally the
same (just /dev entries) and the setup is handled by the block-*
scripts. A block-iscsi would need the same futzing in qemu to make it
happen properly.

I think it's wrong for qemu to use 'type' - the access method should be
stated explicitly. drbd/iscsi should be set up in block-drbd/iscsi and
then qemu should handle them the same way it handles phy: (with the
exception that drbd may need a delay while it comes online). So maybe
another setting in the xenstore like qemu-type or access-method or
something which, if present, overrides the type that qemu uses when
deciding how to access the underlying block device. I don't really like
the name access-method, and qemu-type sounds wrong too, but can't think
of anything better.

So the changes required would be:

1. The block-drbd script would need to write an entry access-method=phy
into xenstore into the appropriate place. Maybe also write a flag in
there to tell qemu that the device may take a few seconds to come online

2. qemu would need to first read access-method, and then type if
access-type doesn't exist. It would also retry the open of the device if
the delay flag was specified. Or maybe it wouldn't hurt to always retry.

If the decision makers agree with that approach I think I could come up
with a patch...

James


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel

<Prev in Thread] Current Thread [Next in Thread>