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

xen-devel

[Top] [All Lists]

Re: [Xen-devel] Xen guest disk online resize, xenstore/blkback/blkfront

To: Ian Campbell <Ian.Campbell@xxxxxxxxxx>
Subject: Re: [Xen-devel] Xen guest disk online resize, xenstore/blkback/blkfront questions
From: Pasi Kärkkäinen <pasik@xxxxxx>
Date: Wed, 6 Jan 2010 23:57:35 +0200
Cc: "xen-devel@xxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxx>
Delivery-date: 2010年1月06日 13:58:30 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <1262810665.28737.102.camel@xxxxxxxxxxxxxxxxxxxxx>
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: <20100106202631.GK25902@xxxxxxxxxxx> <1262810665.28737.102.camel@xxxxxxxxxxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mutt/1.5.13 (2006年08月11日)
On Wed, Jan 06, 2010 at 08:44:25PM +0000, Ian Campbell wrote:
> On Wed, 2010年01月06日 at 20:26 +0000, Pasi Kärkkäinen wrote:
> [...] 
> > Is this more or less correct? Please correct if I've missed something or
> > understood something wrong.
>
> All sounds vaguely familiar, although it's been a while since I last had
> to follow those twisty paths around...
>
> > So, what I need to do next:
> > 
> > - LVM online-resize the guest disk LV in dom0.
> > 
> > - write something to xenstore block device backend structures, 
> > to get the blkback driver notified about the 'block-resize'.
> > 
> > Should I add a new xenbus_watch for some, say, 'resize' field, so I could 
> > get
> > callback to blkback device_resize() easily when xenstore is updated? 
> > 
> > - blkback driver then needs to update/fetch the new size of the vbd, 
> > and update the xenstore /local/domain/0/backend/vbd/X/sectors field.
> > 
> > Any problems getting the new size/sectors on-the-fly in the kernel? 
>
> You might need to close and reopen the block device? 
>
> Idle speculation: perhaps instead of an explicit "resize" field in
> xenstore you could just have the backend continue watching the
> 'physical-device' node even after everything is connected the first time
> and if it is rewritten (including to the same value) reopening the
> physical device and setting things up again (picking up a size change as
> a side effect).
>
Good idea. I'll experiment with this.
> There's no particular reason why the physical device couldn't change
> over this operation either, you could maybe imagine changing to a
> different device mapper node (e.g. perhaps some sort of wierd snapshot
> mechanism?) or perhaps implementing some sort of PV-CDROM media change
> in the same way.
>
> > - blkback then needs to write something to xenstore block device frontend
> > /local/domain/X/device/vbd/Y/ to notify the blkfront driver in the guest.
> > 
> > Same thing here, should blkfront have a watch for some 'resize' field
> > or so?
>
> blkfront can probably just watch /local/domain/0/backend/vbd/X/sectors
>
Sounds good. 
Thanks for the reply!
-- Pasi
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
<Prev in Thread] Current Thread [Next in Thread>
Previous by Date: Re: [Xen-devel] Re: Tagging Xen 4.0.0 first release candidate , Pasi Kärkkäinen
Next by Date: Re: [Xen-devel] Qemu version for upcoming Xen 4.0 release? , Simon Horman
Previous by Thread: Re: [Xen-devel] Xen guest disk online resize, xenstore/blkback/blkfront questions , Ian Campbell
Next by Thread: Re: [Xen-devel] Xen guest disk online resize, xenstore/blkback/blkfront questions , Daniel Stodden
Indexes: [Date] [Thread] [Top] [All Lists]

Copyright ©, Citrix Systems Inc. All rights reserved. Legal and Privacy
Citrix This site is hosted by Citrix

AltStyle によって変換されたページ (->オリジナル) /