Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 5 Jul 2016 05:37:41 +0000
From:      Manish Jain <bourne.identity@hotmail.com>
To:        Polytropon <freebsd@edvax.de>
Cc:        "freebsd-questions@freebsd.org" <freebsd-questions@freebsd.org>
Subject:   Re: How to make smooth USB access available to Virtualbox vm
Message-ID:  <VI1PR02MB097452AA12CC30A2EF3CE365F6390@VI1PR02MB0974.eurprd02.prod.outlook.com>
In-Reply-To: <20160705024640.b2f73f82.freebsd@edvax.de>
References:  <VI1PR02MB0974C9E557F7FEBCA7D7B4FCF6380@VI1PR02MB0974.eurprd02.prod.outlook.com> <20160705024640.b2f73f82.freebsd@edvax.de>

next in thread | previous in thread | raw e-mail | index | archive | help
On 07/05/16 06:16, Polytropon wrote:
> On Mon, 4 Jul 2016 23:35:25 +0000, Manish Jain wrote:
>> Hi,
>>
>> I am running VirtualBox under FreeBSD 10.2 amd64. I created a Windows XP
>> vm for some work I need to do. The vm needs data which I placed on a USB
>> pen drive. I added a filter under VirtualBox to pass the pen drive to
>> the vm and then started the vm. The pen drive for some reason is not
>> smoothly visible to the vm - the icon for removable drive in the vm
>> keeps coming and going every 1-2 seconds. I think the problem is the
>> Gnome3 desktop environment and VirtualBox are competing for the USB pen
>> drive.
>
> Yes, that is to be expected as such a configuration tends to do lots
> of automount "magic" which is now turning against the user. :-)
>
>
>
>> On the host FreeBSD system, I repeatedly get error messages
>> "Unable to mount volume" - some error related to HALD. I tried setting
>> hald_enable=3D"NO" in /etc/rc.conf and then rebooted FreeBSD.
>
> If I remember correctly, this doesn't have any effect, especially
> if you have gnome_enable=3D"YES" defined.
>
>
>
>> Upon
>> restart, the situation remains the same - the vm does not see the pen
>> drive long enough for the data to be copied out.
>
> As far as I know, HAL - at the point where it was fully supported - has
> been EOL'd in Linux and is therefore mostly useless in FreeBSD. The
> problem you see probably is related to the Gnome 3 removable media
> subsystem, the "automounter". If you want to exclusively allow USB
> access to mass storage to the "Windows XP" VirtualBox instance, you
> need to disable that device inside Gnome, i. e. keep Gnome from trying
> to access it.
>
> Here is an instruction on how to do it (even though it is related to
> Ubuntu, it should work similarly on FreeBSD/VirtualBox):
>
> http://askubuntu.com/questions/25596/how-to-set-up-usb-for-virtualbox
>
> Allow me to quote the relevant text section:
>
> 	Select host USB device for access from the guest
>
> 	To grant access to USB devices we need to select a device to
> 	disable in the host and to enable in the guest (this is a
> 	precaution to avoid simultaneous access from host and guest).
> 	This can be done from the panel Devices menu or by right
> 	mouse click in the bottom panel of the Virtual Box Manager
> 	on the USB icon:
>
> 	(screenshot)
>
> 	Tick the device you need in the guest, untick it if you need
> 	it in the host. The selected device will immediately be
> 	accessible from the guest. A Windows guest may need additional
> 	drivers:
>

I tried both the Devices menu as well the bottom panel of Virtual Box=20
Manager. It has no effect : the pen drive appears momentarily again and=20
again - not long enough for me to copy out the data. I have also used=20
dconf-editor to set org.gnome.desktop.media-handling::automount to false=20
- and in gnome3, the automount has stopped. But still vbox is unable to=20
get clean access to the USB pen drive.

Is there anything else I can do ? I am further somewhat surprised that=20
an extension pack which enables USB 2.0 access is available for Linux,=20
but not for FreeBSD. Does anyone have any idea why is that so ?

--=20
Regards

Manish Jain



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?VI1PR02MB097452AA12CC30A2EF3CE365F6390>