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

Re: [Xen-devel] Driver domains and hotplug scripts, redux


Ian Campbell wrote:
> blktap2 doesn't use xenbus IIRC, rather it is created via userspace
> tools/libraries. There _might_ be some hotplug script interaction which
> causes the phys-dev node to get written to the associated blkback
> device
> but I think this is not the case and the toolstack just writes the
> phys-dev because it knows what it is from when it created it.

FYI XCP/xapi is a heavy user of blktap2 and we use it like this:

0. user calls VM.start
1. xapi invokes one of its "storage managers" (plugin scripts, one per
   storage type) telling it to "attach" a disk.
2. the storage manager zones-in the relevant LUN and runs "tap-ctl"
   commands to create a block device. This is returned to xapi.
3. xapi creates the block backend directory in xenstore with
   "params=<block device>".

Xapi used to write the physical-device key directly but I stopped
it doing that when I discovered that using the "params" key worked for
both FreeBSD and Linux storage driver domains. (In the case of a
driver domain on XCP, the "storage manager" code runs inside the driver
domain and xapi talks to it over an RPC mechanism -- currently JSON-rpc
over a network but we'll probably support something else in future: maybe

We used to store cleanup information in xenstore (under /xapi) but we
don't need to do this anymore, now that xapi remembers which disks it
has "attach"ed.

Xen-devel mailing list



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