Choose style:

Author Topic: How to have USB Harddisks & sticks work under VirtualBox?  (Read 5021 times)

0 Members and 1 Guest are viewing this topic.

Offline jozefmw

  • Member
  • ***
  • Posts: 272
  • Karma: 6
  • New Forum User
    • View Profile
  • Peppermint version(s): 8 & 9
How to have USB Harddisks & sticks work under VirtualBox?
« on: July 29, 2014, 07:02:17 am »
I run Windows 7 -32bit under Virtual Box, because I want to be able to use my scanner/printer and USB Harddisks and -sticks.
I didn't find a Linux driver for my printer/scanner brother MFC-250C

I looked around a bit on Internet and learned that apart from installing Virtual Box some other  packages are needed for mounting my USB harddisks, sticks and printer/scanner.

Does somebody have the commands for installing these packages?
Thank's in advance!
« Last Edit: August 02, 2014, 06:34:16 am by jozefmw »

Offline PCNetSpec

  • Administrator
  • Hero
  • *****
  • Posts: 25661
  • Karma: 2819
  • "-rw-rw-rw-" .. The Number Of The Beast
    • View Profile
    • PCNetSpec
  • Peppermint version(s): Peppermint 8R, 9, and 9R
How did you install virtualbox ?
WARNING: You are logged into reality as 'root' .. logging in as 'insane' is the only safe option.

Team Peppermint
PCNetSpec

Offline jozefmw

  • Member
  • ***
  • Posts: 272
  • Karma: 6
  • New Forum User
    • View Profile
  • Peppermint version(s): 8 & 9
Softwaremanager :
Virtualbox-qt
virtualbox-dkms

Not installed:
virtualbox-guest-additions.iso

I guess that is what I have to do next?

Offline PCNetSpec

  • Administrator
  • Hero
  • *****
  • Posts: 25661
  • Karma: 2819
  • "-rw-rw-rw-" .. The Number Of The Beast
    • View Profile
    • PCNetSpec
  • Peppermint version(s): Peppermint 8R, 9, and 9R
You probably will require the guest additions.

BUT

a) you shouldn't have installed the qt version of virtualbox
and
b) AFAIK (unless something has changed) the version of virtualbox in the default repos is the open source edition and doesn't support USB pass-through .. or at least it never used to.

I could be wrong, maybe the version in the reos *does* now support USB pass-through .. I haven't tried the repo version in, oooooh about |___________________________| that long, maybe longer ;)

Gimme till tomorrow and I'll attempt to test if this is still the case.. but I have a feeling you're going to need to uninstall virtualbox, then add the proper repos and install the version directly from the Oracle repos.

If I haven't answered this by tomorrow .. bump the topic to remind me, memory occasionally skips out on unscheduled holidays these days, and for some unknown reason 24 hours now feels more like 3   :o

--
« Last Edit: July 29, 2014, 11:19:18 am by PCNetSpec »
WARNING: You are logged into reality as 'root' .. logging in as 'insane' is the only safe option.

Team Peppermint
PCNetSpec

Offline jozefmw

  • Member
  • ***
  • Posts: 272
  • Karma: 6
  • New Forum User
    • View Profile
  • Peppermint version(s): 8 & 9
Thank you,
you are not the only one, forgetting things now and then. ... ;D

As by coincident I just received a german Linux newsletter dealing with the matter.

First of all it gives a command to diagnose whether there are USB hardware found:
VBoxManage list usbhost

I tried that one, but it wouldn't find my HD's and sticks.

To solve the problem they propose this command:
/usr/sbin/usermod -a -G virtualbox [Username]

There are more commands in case you have to create a second virtual partition or to put the machine in a network.

This is the link to the article, as I said in german and hope you can read it.

http://www.pcwelt.de/ratgeber/Virtuose_Virtualbox-Tricks_fuer_Linux-Linux-Software-8788800.html?r=86351479368425&lid=347365&pm_ln=15

If not, the commands could be useful. but may be, you now all that already for ages.
Anyway, German members could use it eventually.

I am looking forward to your next post. take your time,  and please be quite clear what version of VirtualBox I have to install and where to find it.
Thank you ever so much, you have already been of so much help !!!
Nice evening,
Jozef
« Last Edit: July 29, 2014, 01:18:04 pm by jozefmw »

Offline PCNetSpec

  • Administrator
  • Hero
  • *****
  • Posts: 25661
  • Karma: 2819
  • "-rw-rw-rw-" .. The Number Of The Beast
    • View Profile
    • PCNetSpec
  • Peppermint version(s): Peppermint 8R, 9, and 9R
Well you DEFINITELY need to add yourself to the vboxusers group

Easiest way .. go to:
menu > System Tools > Users and Groups

Click the "Manage Groups" button.

Scroll down to the vboxusers group in the list and click on it to highlight it., and click the "Properties" button.

make sure there's a tick next to your username .. and click the "OK" button (enter your password if prompted) .. then click "Close" > "Close".

Now log off/on.

Now test you're in the vboxusers group by running:
Code: [Select]
groups
which will give a listing of groups you belong to.
WARNING: You are logged into reality as 'root' .. logging in as 'insane' is the only safe option.

Team Peppermint
PCNetSpec

Offline jozefmw

  • Member
  • ***
  • Posts: 272
  • Karma: 6
  • New Forum User
    • View Profile
  • Peppermint version(s): 8 & 9

elias adm dialout fax cdrom floppy tape sudo dip video plugdev fuse lpadmin nopasswdlogin sambashare vboxusers

So I welcome myself as a member of the vboxusers group ...  :)

Offline PCNetSpec

  • Administrator
  • Hero
  • *****
  • Posts: 25661
  • Karma: 2819
  • "-rw-rw-rw-" .. The Number Of The Beast
    • View Profile
    • PCNetSpec
  • Peppermint version(s): Peppermint 8R, 9, and 9R
Have you checked if USB passthrough works now ?
WARNING: You are logged into reality as 'root' .. logging in as 'insane' is the only safe option.

Team Peppermint
PCNetSpec

Offline jozefmw

  • Member
  • ***
  • Posts: 272
  • Karma: 6
  • New Forum User
    • View Profile
  • Peppermint version(s): 8 & 9
The USB HD and printer are reckongnized inside the VirtualBox menu but not available in Windows.
This is the Terminal  ouput using the command: $ VBoxManage list usbhost

elias@elias-System-Product-Name ~ $ VBoxManage list usbhost
Host USB Devices:

UUID:               ce6a76be-d656-430a-a85c-b842640540fc
VendorId:           0x04f9 (04F9)
ProductId:          0x01fe (01FE)
Revision:           1.0 (0100)
Port:               1
USB version/speed:  1/1
Manufacturer:       Brother
Product:            MFC-250C
SerialNumber:       BROC0F192209
Address:            sysfs:/sys/devices/pci0000:00/0000:00:12.0/usb3/3-2//device:/dev/vboxusb/003/002
Current State:      Available

UUID:               3e2dd169-4578-4799-965f-32fa906f6fef
VendorId:           0x058f (058F)
ProductId:          0x6364 (6364)
Revision:           1.0 (0100)
Port:               0
USB version/speed:  2/2
Manufacturer:       Generic
Product:            Mass Storage Device
SerialNumber:       058F63646476
Address:            sysfs:/sys/devices/pci0000:00/0000:00:13.2/usb2/2-1//device:/dev/vboxusb/002/002
Current State:      Available

UUID:               33dac90d-91ef-40a6-9c6d-2463edd96f68
VendorId:           0x1241 (1241)
ProductId:          0x1503 (1503)
Revision:           2.128 (02128)
Port:               1
USB version/speed:  1/1
Manufacturer:       
Product:            USB Keyboard
Address:            sysfs:/sys/devices/pci0000:00/0000:00:12.2/usb1/1-5/1-5.2//device:/dev/vboxusb/001/022
Current State:      Busy

UUID:               296fb8a2-08af-4ef0-8372-e63ab18619d9
VendorId:           0x152d (152D)
ProductId:          0x2329 (2329)
Revision:           0.0 (0000)
Port:               1
USB version/speed:  2/2
Manufacturer:       PI-410
Product:            External USB HDD
SerialNumber:       2011092400FCB
Address:            sysfs:/sys/devices/pci0000:00/0000:00:07.0/0000:03:00.0/usb10/10-2//device:/dev/vboxusb/010/002
Current State:      Available

UUID:               daf97222-01ca-4cf8-b7b1-d93c1c717dcf
VendorId:           0x15d9 (15D9)
ProductId:          0x0a4d (0A4D)
Revision:           1.0 (0100)
Port:               2
USB version/speed:  1/1
Product:             USB OPTICAL MOUSE
Address:            sysfs:/sys/devices/pci0000:00/0000:00:12.2/usb1/1-6/1-6.4/1-6.4.3//device:/dev/vboxusb/001/008
Current State:      Busy

UUID:               48f6703a-8f89-4655-a77e-32bca2453bac
VendorId:           0x18a5 (18A5)
ProductId:          0x0237 (0237)
Revision:           25.5 (2505)
Port:               1
USB version/speed:  3/3
Manufacturer:       Verbatim
Product:            Portable USB 3.0 Drive
SerialNumber:       203211215697   
Address:            sysfs:/sys/devices/pci0000:00/0000:00:04.0/0000:02:00.0/usb9/9-2//device:/dev/vboxusb/009/002
Current State:      Available

Do I first have to install the virtualbox-guest-additions-iso?
If yes I probably have to burn the iso on a CD and run the program?
Or does it install itself in  Software maneger?

Or
rather use this command now:

/usr/sbin/usermod -a -G virtualbox [Userrname] ??

« Last Edit: July 29, 2014, 04:10:25 pm by jozefmw »

Offline PCNetSpec

  • Administrator
  • Hero
  • *****
  • Posts: 25661
  • Karma: 2819
  • "-rw-rw-rw-" .. The Number Of The Beast
    • View Profile
    • PCNetSpec
  • Peppermint version(s): Peppermint 8R, 9, and 9R
For guest additions see here:
http://www.dedoimedo.com/computers/virtualbox-guest-addons.html
you do NOT need to burn a CD :)

Can you post the output from:
Code: [Select]
dpkg -l | grep virtualbox
WARNING: You are logged into reality as 'root' .. logging in as 'insane' is the only safe option.

Team Peppermint
PCNetSpec

Offline jozefmw

  • Member
  • ***
  • Posts: 272
  • Karma: 6
  • New Forum User
    • View Profile
  • Peppermint version(s): 8 & 9
elias@elias-System-Product-Name ~ $ dpkg -l | grep virtualbox
ii  virtualbox                                  4.3.10-dfsg-1                         amd64        x86 virtualization solution - base binaries
ii  virtualbox-dkms                             4.3.10-dfsg-1                         all          x86 virtualization solution - kernel module sources for dkms
ii  virtualbox-qt                               4.3.10-dfsg-1                         amd64        x86 virtualization solution - Qt based user interface

Thank you very much for that link to dedoimedo. That really is a rich source for every layman in Linuxland.

Offline PCNetSpec

  • Administrator
  • Hero
  • *****
  • Posts: 25661
  • Karma: 2819
  • "-rw-rw-rw-" .. The Number Of The Beast
    • View Profile
    • PCNetSpec
  • Peppermint version(s): Peppermint 8R, 9, and 9R
OK, I can probably help with removing the incorrect version(s) of virtualbox you have installed .. then adding the oracle repo .. then installing the correct version.

BUT

Doing so may kill any VM's you've already created .. requiring you to recreate them.

In fact it WILL kill them, because I think it would be best to delete them and start again.

Do you want to continue ?
WARNING: You are logged into reality as 'root' .. logging in as 'insane' is the only safe option.

Team Peppermint
PCNetSpec

Offline jozefmw

  • Member
  • ***
  • Posts: 272
  • Karma: 6
  • New Forum User
    • View Profile
  • Peppermint version(s): 8 & 9
Thank you!
The only way is the right way, which will turn out to be the happy way ....
A bit work in the beginning phase makes itself profitable avoiding a lot of problems later.

So, I remove the old one and could run windows 8.1 inside, instead of seven.
As my processor is 64 bit I probably be better of with Windows 64bit, so that I can use my 8 GB ram.
But again I didn't find the thing I had to change in the Bios. (don't remember what  for the moment)

So what is the right version and where to find it?
And where to find the right Oracle repo?

Offline PCNetSpec

  • Administrator
  • Hero
  • *****
  • Posts: 25661
  • Karma: 2819
  • "-rw-rw-rw-" .. The Number Of The Beast
    • View Profile
    • PCNetSpec
  • Peppermint version(s): Peppermint 8R, 9, and 9R
OK, if you've already removed the old virtualbox versions with:
Code: [Select]
sudo apt purge virtualbox*

Make sure you have build-essential, linux-headers-generic, and dkms installed:
Code: [Select]
sudo apt install build-essential linux-headers-generic dkms

add the public key for the oracle virtualbox repo with:
Code: [Select]
wget -q http://download.virtualbox.org/virtualbox/debian/oracle_vbox.asc -O- | sudo apt-key add -

Now backup your sources.list:
Code: [Select]
sudo cp -v /etc/apt/sources.list /etc/apt/sources.list.bak

Now open sources.list for editing:
Code: [Select]
sudo gedit /etc/apt/sources.list

and add these 2 NEW LINES at the bottom:
Code: [Select]
###### Oracle VirtualBox repo
deb http://download.virtualbox.org/virtualbox/debian trusty contrib
SAVE the file and exit gedit.

Back in the terminal update the package cache:
Code: [Select]
sudo apt update

and install virtualbox-4.3 with
Code: [Select]
sudo apt install virtualbox-4.3

Check you're still a member of the vboxusers group and add yourself if necessary.

Download the extensions pack for the correct version of virtualbox from here:
https://www.virtualbox.org/wiki/Downloads
here's a direct download llink for the current version (4.3.14):
http://download.virtualbox.org/virtualbox/4.3.14/Oracle_VM_VirtualBox_Extension_Pack-4.3.14-95030.vbox-extpack
and double click it to to install it .. virtualbox will start and offer to install it, clcik the "Install" button, then scroll to the bottom of the license and click the "I Agree" button, and enter your password when prompted.

Done.
« Last Edit: August 10, 2014, 02:35:58 pm by PCNetSpec »
WARNING: You are logged into reality as 'root' .. logging in as 'insane' is the only safe option.

Team Peppermint
PCNetSpec

Offline jozefmw

  • Member
  • ***
  • Posts: 272
  • Karma: 6
  • New Forum User
    • View Profile
  • Peppermint version(s): 8 & 9
When I give in the command:
sudo apt purge virtualbox*
I am asked to put in my password.
However, it is impossible to do this because the input through the keyboard would't work anymore.
Nor copy and pass the password.

I just changed the all over language from German into English.
Could that be the cause if the problem?

Is it O.K. to remove virtualbox  using the Software Manager?

Does this problem need to be posted  as another post?