Apparently Virtualbox has made a good improvement after being taken by Sun. However it is still not mature enough to work out of the box when it is installed on Ubuntu 8.04 in the first place. A little hacking is still required.
First of all, download the full version from the
website of Virtualbox (instead of install the open source version directly from the repository). Install it in a way you like. And hope it works. If it doesn't, carry on reading this.
You need to add your current user to a group named vboxusers, again, in your favorite way. If you don't have one, try this one.
Check if the group exists:
sudo grep vboxusers /etc/group
If nothing shows up, add it:
sudo addgroup vboxusers
Now add the user to the group:
usermod -a -G vboxusers $USER
Now you should at least be able to open Virtualbox properly and install an operating system on it. Let's take Windows XP for an example here, make sure you installed Guest Additions (Devices-Install Guest Additions).
The next step is to authorize the user to use USB.
Edit /etc/init.d/mountdevsubfs.sh with your best editor, make sure the following lines are
uncommented
mkdir -p /dev/bus/usb/.usbfs
domount usbfs “” /dev/bus/usb/.usbfs -obusmode=0700,devmode=0600,listmode=0644
ln -s .usbfs/devices /dev/bus/usb/devices
mount –rbind /dev/bus/usb /proc/bus/usb
Create a new group and add the current user to it:
sudo addgroup usbfs
sudo usermod -a -G usbfs $USER
Then edit /etc/udev/rules.d/40-permissions.rules
Find
LABEL=”usb_serial_start”
ATTRS{idVendor}==”0403″, ATTRS{idProduct}==”6001″, \
, MODE=”0660″, GROUP=”dialout”
LABEL=”usb_serial_end”
Add GROUP="usbfs" to it, like this:
LABEL=”usb_serial_start”
ATTRS{idVendor}==”0403″, ATTRS{idProduct}==”6001″, \
GROUP="usbfs", MODE=”0660″, GROUP=”dialout”
LABEL=”usb_serial_end”
Save the file.
Find out the group id:
grep usbfs /etc/group
Remember the number within it, for example on this machine, I get the result
vboxusers:x:1003:name
Thus
1003
is the id.
Open /etc/fstab, add the following line to the end:
none /proc/bus/usb usbfs devgid=1003,devmode=664 0 0
Reboot the host system.
And then you should be able to enjoy the VM with available USB support.
6 comments:
great tutorial man! worked fine for me.
2 commands although miss smt ;)
sudo (addgroup) vboxusers
(sudo) usermod -a -G usbfs $USER
Oops..Thank you!
I so thank you:) I`ts works. But my integrated webcam still bad:(
grep usbfs /etc/group
gives an answer with vboxusers in it?
So should I be greping for usbfs or vboxusers? Which gid should I be using?
Here I used a separate group to authorize vbox to access usb. And vboxusers is the group whose member can use vbox properly.
This is a very clearly written tutorial, thank you.
Except that usb is still not working for me on Win XP running in virtual box. This is a pity because I cannot get WinXP to see my external HD. What else can I try?
Post a Comment