[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH for-4.6] libxl, hotplug/Linux: default to phy backend for raw format file



On Thu, 8 Jan 2015, Ian Campbell wrote:
> On Thu, 2015-01-08 at 16:07 +0000, Wei Liu wrote:
> > On Thu, Jan 08, 2015 at 02:07:42PM +0000, Ian Campbell wrote:
> > > On Wed, 2014-11-26 at 16:55 +0000, Wei Liu wrote:
> > > > Modify libxl and hotplug script to allow raw format file to use phy
> > > > backend.
> > > > 
> > > > The block script now tests the path and determine the actual type of
> > > > file (block device or regular file) then use the actual type to
> > > > determine which branch to run.
> > > > 
> > > > With these changes, plus the current ordering of backend preference (phy
> > > > > qdisk > tap), we will use phy backend for raw format file by default.
> > > 
> > > http://lists.xen.org/archives/html/xen-devel/2012-04/msg00077.html
> > > includes (in the quotes, Stefano's reply is about something else but has
> > > conveniently trimmed most of the other uninteresting stuff):
> > >         use /dev/loop+blkback. This requires loop driver AIO and
> > >         O_DIRECT patches which are not (AFAIK) yet upstream.
> > > 
> > > and I have it in my mind that using /dev/loop+blkback is somehow unsafe,
> > > for reasons relating to crash consistency and the proper implementation
> > > (in /dev/loop, blkback is good I think) of barriers and such, e.g.
> > > relating to whether data is really on the platter or not when we've to
> > > the frontend that it is (which is critical for proper operation of
> > > journalling file systems).
> > > 
> > > It's entirely possible that I'm either plain wrong or a decade out of
> > > date on this though. CC-ing Konrad in case he has any insights as
> > > blkback maintainer (I think, MAINTAINERS doesn't have a specific entry)
> > > 
> > 
> > Too bad, as far as I can tell AIO and O_DIRECT are still missing in loop
> > device. I guess we will have to wait until those two things are
> > upstreamed.
> > 
> 
> I'm kinda hoping someone will tell me I'm wrong...

Even without O_DIRECT, using /dev/loop+blkback is safe if the barriers
in the block protocol are implemented correctly. Last time I look, they
are, so I think we should be able to switch to it.

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.