XCP storage driver domains: Difference between revisions
Dave.scott (talk | contribs) (Created page with "This page describes how to configure a storage driver domain on XCP 1.6. This is experimental software: please send feedback to xen-api@lists.xen.org. ==Create a suitable VM== …") |
Dave.scott (talk | contribs) No edit summary |
||
Line 15: | Line 15: | ||
=== The XCP block udev scripts === |
=== The XCP block udev scripts === |
||
These are needed to signal to the toolstack when a disk has been "attached". |
These are needed to signal to the toolstack when a disk has been "attached". In Ubuntu the scripts are normally installed via the package "xen-utils-common". |
||
=== PCI passthrough === |
=== PCI passthrough === |
||
Line 26: | Line 26: | ||
If you shutdown and then restart the VM (not reboot), you should see the device appear in the driver VM with "lspci" while in dom0 the device should be associated with "pciback". |
If you shutdown and then restart the VM (not reboot), you should see the device appear in the driver VM with "lspci" while in dom0 the device should be associated with "pciback". |
||
⚫ | |||
=== Add a VIF to the "internal management network" === |
=== Add a VIF to the "internal management network" === |
||
Shut down the driver VM and execute in dom0: |
|||
NET=$(xe network-list other-config:is_host_internal_management_network=true params=uuid --minimal) |
|||
xe vif-create vm-uuid=<my VM uuid> network-uuid=$NET device=0 |
|||
This will add a special VIF connecting the driver VM to the "host internal management" network. |
|||
⚫ | |||
Inside the driver VM run: |
|||
git clone git@github.com:djs55/dbus-test |
|||
cd dbus-test |
|||
sudo make install |
|||
This will add a python program (/usr/lib/xcp-sm-fs) |
|||
It's a good idea to arrange for this program to start automatically when the VM starts. There's a config file (/etc/xcp-sm-fs.conf) which has some tweakable settings. Check the VM is binding to port 80 on eth0 using "netstat" (or adjust the configuration if you're using a different interface) |
|||
=== Try the prototype file-backed "Storage Repository" === |
=== Try the prototype file-backed "Storage Repository" === |
Revision as of 13:48, 15 March 2013
This page describes how to configure a storage driver domain on XCP 1.6. This is experimental software: please send feedback to xen-api@lists.xen.org.
Create a suitable VM
Install a VM in the usual way. A storage driver domain can be PV or HVM. A storage driver domain must have:
- the blkback kernel module
- the XCP block udev scripts (available in RPM)
- access to the storage medium (via the network or via a PCI passthrough device)
The blkback kernel module
Check you have the "xen-blkback" module (Linux) and "modprobe" it if its missing.
The XCP block udev scripts
These are needed to signal to the toolstack when a disk has been "attached". In Ubuntu the scripts are normally installed via the package "xen-utils-common".
PCI passthrough
Use "lspci" in dom0 to identify the storage controller you want to pass through. Take a note of the "BBBB:DD.F" identification string. Note that unless a multi-function device supports "Function Level Reset" on individual Functions you must pass all functions together as a group.
Use the "xe" CLI to associate this PCI device with your driver VM:
xe vm-param-set uuid=<VM uuid> other-config:pci=0/BBBB:DD.F,1/BBBB:DD.F
If you shutdown and then restart the VM (not reboot), you should see the device appear in the driver VM with "lspci" while in dom0 the device should be associated with "pciback".
Add a VIF to the "internal management network"
Shut down the driver VM and execute in dom0:
NET=$(xe network-list other-config:is_host_internal_management_network=true params=uuid --minimal) xe vif-create vm-uuid=<my VM uuid> network-uuid=$NET device=0
This will add a special VIF connecting the driver VM to the "host internal management" network.
Install the storage control plane software
Inside the driver VM run:
git clone git@github.com:djs55/dbus-test cd dbus-test sudo make install
This will add a python program (/usr/lib/xcp-sm-fs)
It's a good idea to arrange for this program to start automatically when the VM starts. There's a config file (/etc/xcp-sm-fs.conf) which has some tweakable settings. Check the VM is binding to port 80 on eth0 using "netstat" (or adjust the configuration if you're using a different interface)