Bug 212845 - emulators/virtualbox-ose: 5.1.6 can't connect USB devices
Summary: emulators/virtualbox-ose: 5.1.6 can't connect USB devices
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Many People
Assignee: Virtualbox Team (Nobody)
Depends on:
Reported: 2016-09-20 09:30 UTC by graham
Modified: 2017-01-29 02:32 UTC (History)
7 users (show)

See Also:
bugzilla: maintainer-feedback? (vbox)

Updated USB proxy backend patch (705 bytes, patch)
2017-01-25 19:49 UTC, Hans Petter Selasky
no flags Details | Diff
Updated USB proxy backend patch (3.09 KB, patch)
2017-01-25 19:49 UTC, Hans Petter Selasky
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description graham 2016-09-20 09:30:55 UTC
I've been using my Epson scanner in Windows XP under VirtualBox for many
years. I recently updated my source and ports to the latest and now I
can't access my scanner. In fact I can't seem to attach any USB devices.
I've tried creating a filter for it under USB Settings, and I've tried
manually connecting it from the Devices->USB menu by clicking its
checkbox. In both cases, it doesn't connect. If I try a second time, I
get a message:

Failed to attach the USB device EPSON Scanner to the virtual machine

USB device 'EPSON EPSON Scanner' with UUID
{aa1eba25-05eb-4aed-8e9f-803807dd3bc4} is busy with a previous request.
Please try again later.

Result Code: NS_ERROR_INVALID_ARG (0x80070057)
Component: HostUSBDeviceWrap
Interface: IHostUSBDevice {c19073dd-cc7b-431b-98b2-951fda8eab89}
Callee: IConsole {872da645-4a9b-1727-bee2-5585105b9eed}

I've waited for an hour in case it was just taking a long time to
connect - no joy.

This is on FreeBSD 11-Stable AMD64, and ports updated to (r422267). And I built the kmod with the correct current kernel source in place. It's not a problem with permissions on the /dev/usb entries.

Today I reverted back to the port as of last month (5.0.26) and it's all working again.
Comment 1 arkadyi 2016-09-27 10:17:13 UTC
I have same problem with connect any usb device to the Virtualbox.

FreeBSD ark 11.0-RELEASE FreeBSD 11.0-RELEASE #0 r306361: Tue Sep 27 12:42:42 MSK 2016     ark@ark:/usr/obj/usr/src/sys/ARK11_64  amd64

virtualbox-ose-5.1.6           General-purpose full virtualizer for x86 hardware
virtualbox-ose-kmod-5.1.6      VirtualBox kernel module for FreeBSD
Comment 2 martin 2016-10-19 14:53:18 UTC
I want to confirm this, too. USB filter functionality is broken.

I downgraded to 5.0.26 and everything works fine again.
Comment 3 arkadyi 2016-10-24 09:15:30 UTC
After upgrade to virtualbox-ose-5.1.8.
Problem still exists.
I checked all my settings.


# Generic USB devices
add path 'ugen[0-9]\*'  mode 666
add path 'usbctl'       mode 666
add path 'usb/\*'       mode 666

User is a member of a group of operators and vboxusers.

Guest OS: Windows XP
When I try to mount the usb disk I see the following:
Не удалось подсоединить USB-устройство JetFlash Mass Storage Device к виртуальной машине WinXP.

USB device 'JetFlash Mass Storage Device' with UUID {23e6aeee-ad7a-4ec1-8a73-c7e5b3bd1f1d} is busy with a previous request. Please try again later.

Код ошибки: NS_ERROR_INVALID_ARG (0x80070057)
Компонент: HostUSBDeviceWrap
Интерфейс: IHostUSBDevice {c19073dd-cc7b-431b-98b2-951fda8eab89}
Вызванный интерфейс: IConsole {872da645-4a9b-1727-bee2-5585105b9eed}
Comment 4 martin 2016-10-31 10:17:41 UTC
Confirmed. 5.1.8 is still broken.

Martin Sugioarto
Comment 5 russo 2016-12-12 22:00:10 UTC
Has anyone checked to see if 5.1.10 also has this bug?  I've got VirtualBox held at 5.0.26 because I can't let it be broken (just about the only thing I use VirtualBox for depends on USB working, and it does in 5.0.26).
Comment 6 arkadyi 2016-12-13 05:03:02 UTC
Yes. I tried. This version(5.1.10) has a same problem.
Comment 7 Petr Fischer 2017-01-02 12:53:09 UTC
5.1.12 is also broken (usb passthrough)

Latest working is 5.0.26_1.

Bug author can change to "Affects Many People"
Comment 8 graham 2017-01-21 04:01:43 UTC
Sadly, 5.1.14 doesn't work either.
Comment 9 Hans Petter Selasky freebsd_committer 2017-01-25 19:49:18 UTC
Created attachment 179314 [details]
Updated USB proxy backend patch
Comment 10 Hans Petter Selasky freebsd_committer 2017-01-25 19:49:57 UTC
Created attachment 179315 [details]
Updated USB proxy backend patch
Comment 11 Hans Petter Selasky freebsd_committer 2017-01-25 19:51:48 UTC
Some minor VBox USB patches are needed to get it working again, attached.
Comment 12 graham 2017-01-25 20:13:07 UTC
Thank you very much, Hans. Working for me now.

Comment 13 commit-hook freebsd_committer 2017-01-25 21:02:04 UTC
A commit references this bug:

Author: jkim
Date: Wed Jan 25 21:01:18 UTC 2017
New revision: 432460
URL: https://svnweb.freebsd.org/changeset/ports/432460

  Fix USB support.

  PR:		212845
  Submitted by:	hselasky
  Tested by:	Graham Menhennitt (graham at menhennitt dot com dot au)

Comment 14 Jung-uk Kim freebsd_committer 2017-01-25 21:02:39 UTC
Committed, thanks!
Comment 15 arkadyi 2017-01-26 07:53:42 UTC
Thanks a lot! It's work.
Comment 16 Slawomir Wojciech Wojtczak 2017-01-27 23:59:23 UTC
Does not work for me.

After USB stick is connected to USB 3.0 port on ThinkPad W530 and clicking USB Passthru:

Virtualbox Error:
Failed to attach the USB device vendor 0x13fe USB DISK 3.0 to the virtual machine ASD.

Failed to create a proxy device for the USB device. (Error: VERR_PDM_NO_USB_PORTS).

Result Code: NS_ERROR_FAILURE (0x80004005)
Component: ConsoleWrap
Interface: IConsole {872da645-4a9b-1727-bee2-5585105b9eed}

After USB stick is connected to USB 2.0 port on ThinkPad W530 and clicking USB Passthru:

(No direct Virtualbox fail but the device does not appears on Virtualbox VM).

Comment 17 graham 2017-01-28 08:40:37 UTC
Hey Vermaden,

That looks like a different problem. I'd suggest creating a separate PR for it.

Comment 18 Hans Petter Selasky freebsd_committer 2017-01-28 08:53:18 UTC

Is this a USB 2.0 or USB 3.0 stick, what does usbconfig say?

Currently, USB 2.0 and USB 3.0 support is missing from virtualbox!

Comment 19 Slawomir Wojciech Wojtczak 2017-01-29 01:21:30 UTC
(In reply to graham from comment #17)
In what way different?

The name of the bug is "can't connect USB devices".

This is exactly my problem.
Comment 20 Slawomir Wojciech Wojtczak 2017-01-29 01:23:45 UTC
(In reply to Hans Petter Selasky from comment #18)

I do not expect Virtualbox to have working USB passthru at 2.0 or 3.0 speed, I just need its basic 1.1 speed that is available in open source version.

But that does not work on FreeBSD.

I was just showing that no matter if I attach an USB dongle thru 2.0 or 3.0 port it still does not work.

Last time I checked FreeBSD has different drivers for 2.0 and 3.0 USB so that information COULD help to narrow the problem.
Comment 21 graham 2017-01-29 01:58:10 UTC
(In reply to vermaden from comment #19)

It's a different error message and different symptoms.

And Hans has fixed this error. So, yours is a different problem.
Comment 22 Slawomir Wojciech Wojtczak 2017-01-29 02:32:15 UTC
(In reply to graham from comment #21)

Here: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=216564