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] Xen guest disk online resize, xenstore/blkback/blkfront

To: Pasi Kärkkäinen <pasik@xxxxxx>
Subject: Re: [Xen-devel] Xen guest disk online resize, xenstore/blkback/blkfront questions
From: Daniel Stodden <daniel.stodden@xxxxxxxxxx>
Date: Thu, 7 Jan 2010 23:54:19 -0800
Cc: Ian Campbell <Ian.Campbell@xxxxxxxxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxx>
Delivery-date: Thu, 07 Jan 2010 23:54:48 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <20100106215735.GM25902@xxxxxxxxxxx>
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> <20100106215735.GM25902@xxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
On Wed, 2010-01-06 at 16:57 -0500, Pasi Kärkkäinen wrote:

> > >   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.

The XCP kernel has support for transparent pause/unpause. Which takes of
the queue flush in order to get the bdev closed.

Below is that patch which enables switching the physical node,
safety-checking if the VBD is paused etc. Matters not so much for
snapshotting, rather for cross-vg stuff.

It happens to work otherwise as IanC suggested.

It may be more than you're up to in order to get a resize done, e.g.
depends on whether you want to piggyback close/open into pause/unpause
or not (as a rule of thumb, it's safe to say that pause applications
want a close anyway :]). 

Didn't check for bitrot, sorry in advance.

HTH. Let me know if you're missing something or how it's going.

Cheers,
Daniel

Attachment: blkback-device-switch.diff
Description: Text Data

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