[GLLUG] Does any virtualisation system provide good support for USB device forwarding?

John Winters john at sinodun.org.uk
Tue Apr 8 09:39:20 UTC 2014


I've got a small server which uses Xen to run 5 separate VMs.  I do this 
to provide separation of functionality, and to ease migration when I 
move to new hardware.  Moving a VM from one physical host to another one 
is trivial.

The one niggle I have currently is that some of the services I run 
require access to USB devices.  Currently those have to run in my Dom0, 
which isn't as neat and tidy as I would like.

I've looked into USB forwarding within Xen, but it seems to be in a bit 
of a broken state.  As far as I can discover, if you're using the xl 
tool set then it just isn't supported.  The older xm tool set 
theoretically does support it, but xm is deprecated, and doesn't work 
with the current version of Xen (4.3).

I've also tried delegating the entire PCI device (the USB controller) to 
a domU, but whilst the VM can see it, it fails to initialise it.  I 
think I've exhausted the possibilities as far as Xen is concerned.

Obvious alternatives are KVM and VirtualBox, both of which sort of seem 
to support USB device forwarding.  However, the documentation page for 
KVM - http://www.linux-kvm.org/wiki/index.php?title=UsbPassthrough - is 
simply missing, although it's referred to from various other parts of 
the documentation.  My experience of VirtualBox is limited to using it 
for desktop virtualisation.  I haven't tried it headless.

I admit this query is just an attempt to save time.  Rather than my 
setting up new installations of KVM and VirtualBox to see whether USB 
forwarding works, can anyone report having successfully done it with 
either of these platforms?

TIA,
John




More information about the GLLUG mailing list