USB Hub

This is for discussing general topics about how to use VirtualBox.
Post Reply
RyanR
Posts: 4
Joined: 21. Sep 2013, 22:48

USB Hub

Post by RyanR »

I have an application that needs access to the hub itself in the VirtualBox VM. It probably doesn't matter but I'm using a Windows XP host.

I've tried setting up a filter with the hubs VID and PID but the hub will not transfer to the VM. Is there a way to get the hub to show up in the VM?
mpack
Site Moderator
Posts: 39134
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Mostly XP

Re: USB Hub

Post by mpack »

I don't use an external hub. If it isn't visible as a device on the USB network then, like all other host-owned physical devices, it will not be available to a virtual machine.
RyanR
Posts: 4
Joined: 21. Sep 2013, 22:48

Re: USB Hub

Post by RyanR »

I don't understand this answer. Let me explain the situation in more detail.

I have an APC USB hub. VID 0409 and PID 0059. I've setup a filter with this VID and PID. I want the hub to show up in the Windows XP virtual machine, not the in the host Windows. But no matter what I do to the filter the hub always shows us in the host machine, not the virtual machine. How do I fix this so the hub shows up in the virtual machine?

I had another thought. I was trying to get a USB Wireless dongle to also show up in the VM but it wouldn't. It kept being taken over by the host machine. I got it to work eventually by uninstalling the driver from the host windows. It seems like the host windows has precedence over the devices when the driver is installed. It seems the only way to get the host machine to allow the virtual machine to take over the device is for there to be no driver to enumerate the device. Of course, I'm not going to uninstall the windows hub driver (if that is even possible...).

Also, I noticed that when clicking "Add New Filter", hubs don't show up in that list.

Is it possible to give control of a USB hub to the VM?
mpack
Site Moderator
Posts: 39134
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Mostly XP

Re: USB Hub

Post by mpack »

RyanR wrote:Is it possible to give control of a USB hub to the VM?
As I said, I do not use a USB hub.

However, I would expect that the answer to your question is no. VBox USB passthrough works by redirecting protocol messages from a specific device into a VM. AFAIK a hub doesn't send any messages. A hub just augments the number of ports on your host, it isn't an active participant in the USB network.
RyanR
Posts: 4
Joined: 21. Sep 2013, 22:48

Re: USB Hub

Post by RyanR »

Actually, USB hubs do send messages for the enumeration. Then once the hub is owned by the VM I would think all the devices connected to the hub would automatically be part of the VM. Or at least that is what I was hoping would happen.

Another question in this area, is there a way to give the VM ownership of one of the root hub ports?

The goal is that I want the whole USB tree, hubs and all, to be automatically switched over to the VM. Is any of this possible?
noteirak
Site Moderator
Posts: 5231
Joined: 13. Jan 2012, 11:14
Primary OS: Debian other
VBox Version: OSE Debian
Guest OSses: Debian, Win 2k8, Win 7
Contact:

Re: USB Hub

Post by noteirak »

That is not possible in Virtualbox. You can only attach "real" USB devices, not hub devices or controllers.
Hyperbox - Virtual Infrastructure Manager - https://apps.kamax.lu/hyperbox/
Manage your VirtualBox infrastructure the free way!
RyanR
Posts: 4
Joined: 21. Sep 2013, 22:48

Re: USB Hub

Post by RyanR »

This is very unfortunate... In that case I have a second question. I will need to create two instances of the virtual machine to do what I need to do. An then I will need to plug in two of the exact same device. I see the USB filter has a "Port" option. How can I figure out what port number to put in that setting so I know which device goes to which virtual machine?
Post Reply