Enable VirtualBox virtual machines(Guests) USB support

This post was written by admin on September 30, 2009
Posted Under: General

I installed Virtualbox and XP guest in Ubuntu 9.04,and enabled file sharing between them.But I encountered USB problem when I inserted a USB disk.Finally,I worked it out by following steps.
1.Open up VirtualBox,select the virtual machine and click on Settings.Then select USB in left and check the two checkboxes.
virtualbox_usb1
2.Open up terminal(Applications->Accessories->Terminal).Create usb group and add current user to the group:

sudo groupadd usbfs
sudo adduser your_username_here usbfs

3.Use this command,and you will get group id:

cat /etc/group | grep usbfs

Example of output:

usbfs:x:1001:wraith

Here,1001 is the group id.
4.Edit /etc/fstab by this command:

sudo gedit /etc/fstab

Add this line in the bottom.

none /proc/bus/usb usbfs devgid=1001,devmode=664 0 0

Here 1001 is the group id in step 3.
5.Run following command:

sudo chmod 777 /proc/bus/usb

Restart your computer.
virtualbox_usb

Tips:
I don’t konw whether it matters,but you’d better install guest additions (from Devices->Install guest additions in VM window)

Related posts:

  1. How to share folder between VirtualBox Host and Virutal Machines(Guests)
  2. Enable VirtualBox ubuntu guest 3D Acceleration
  3. Enable remote desktop in Virtual machine(Virtualbox guest)
  4. Manage your VirtualBox Guest OS with VBoxManage
  5. Install/Update the latest VirtualBox without hurting current VMs

    Reader Comments

    Hey man!!

    Great work!!! I had tried pretty much every other solution I could find, but yours was the only one that worked!!! You ROCK!!! Thanks a million dude!!!

    [Reply]

    #1 
    Written By Spyros on November 10th, 2009 @ 11:54 pm

    Add a Comment

    required, use real name
    required, will not be published
    optional, your blog address