Ubuntu Forums ubuntu.com - launchpad.net - ubuntu help  

Go Back   Ubuntu Forums > The Ubuntu Forum Community > Other Community Discussions > Development & Programming > Ubuntu Forum Archives > Intrepid Ibex Testing and Discussion (Closed)
Register Reset Password Forum Help Forum Council Search Today's Posts Mark Forums Read

Intrepid Ibex Testing and Discussion (Closed)
Development of Intrepid Ibex is finished. Please ask questions about Ubuntu 8.10 in Absolute Beginner Talk or Main Support Categories.

 
 
Thread Tools Display Modes
Old October 13th, 2008   #1
txHarleyMan
5 Cups of Ubuntu
 
txHarleyMan's Avatar
 
Join Date: Jun 2007
Location: Texas
My beans are hidden!
Ubuntu 9.10 Karmic Koala
Intrepid/Virtualbox/USB

All,

Has anyone been able to get USB working with Virtualbox 2.0.2 ( non ose version ) ? I'm running Intrepid Beta.


Mike
__________________
txHarleyMan
Registered Linux User #443027

Last edited by txHarleyMan; October 13th, 2008 at 10:32 PM.. Reason: SOLVED
txHarleyMan is offline  
Old October 13th, 2008   #2
ju2wheels
Quad Shot of Ubuntu
 
ju2wheels's Avatar
 
Join Date: Sep 2008
Location: Hartford, CT
Beans: 438
Ubuntu 9.04 Jaunty Jackalope
Send a message via AIM to ju2wheels
Re: Intrepid/Virtualbox/USB

Yea I have it working in mine. I forget the link to the source I used to set it up though, Ill look for it and post back here if I find it.

As usual make sure you have added yourself to the vboxusers group.

Also I checked my fstab so I know I had to add this to get it to enable on every boot:

Code:
#usbfs
none /proc/bus/usb usbfs devgid=46,devmode=664 0 0
Ill look for that article to see if I changed anything else because I dont remember off the top of my head since the process was different from the way it was done on Hardy.
ju2wheels is offline  
Old October 13th, 2008   #3
txHarleyMan
5 Cups of Ubuntu
 
txHarleyMan's Avatar
 
Join Date: Jun 2007
Location: Texas
My beans are hidden!
Ubuntu 9.10 Karmic Koala
Re: Intrepid/Virtualbox/USB

Quote:
Originally Posted by ju2wheels View Post
Yea I have it working in mine. I forget the link to the source I used to set it up though, Ill look for it and post back here if I find it.

As usual make sure you have added yourself to the vboxusers group.

Also I checked my fstab so I know I had to add this to get it to enable on every boot:

Code:
#usbfs
none /proc/bus/usb usbfs devgid=46,devmode=664 0 0
Ill look for that article to see if I changed anything else because I dont remember off the top of my head since the process was different from the way it was done on Hardy.
Thanks, JU. I didn't add anything to my fstab. Will try after work today!

Mike
__________________
txHarleyMan
Registered Linux User #443027
txHarleyMan is offline  
Old October 13th, 2008   #4
The Cokeaholics
First Cup of Ubuntu
 
Join Date: Nov 2007
Beans: 12
Ubuntu Jaunty Jackalope (testing)
Re: Intrepid/Virtualbox/USB

Here you go:
HTML Code:
http://www.ubuntu-unleashed.com/2008/04/howto-install-virtualbox-in-hardy-heron.html
It mentions Hardy but worked out for me.

Quote:
Setup VirtualBox USB Support:
USB is disabled by default, so you'll probably want to enable it. Otherwise you'll get an error when you go into the "Settings" of your virtual machine. To correct this, you'll need to edit the mountdevsubfs.sh file:
sudo gedit /etc/init.d/mountdevsubfs.sh
You'll see a block of code that looks like this:
#
# Magic to make /proc/bus/usb work
#
#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
Now uncomment the last 4 lines above to look like this:
#
# Magic to make /proc/bus/usb work
#
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

Ok now logoff, then log back in so the vbox driver see's you are logged in to the vboxusers group.

If the above doesnt work try rebooting, if that doesnt enable usb you can try this:
Grab the vboxusers group id:
grep vbox /etc/group
vboxusers:124:ionstorm
Edit the fstab with the group id # in bold:
sudo gedit /etc/fstab
Append this to the fstab then save/exit:
## usbfs is the USB group in fstab file:
none /proc/bus/usb usbfs devgid=124,devmode=664 0 0
Now lets edit the mountkernfs.sh file with the gid in bold:
sudo gedit /etc/init.d/mountkernfs.sh
Paste the 2 lines below above the line: "# Mount spufs, if Cell Broadband processor is detected"
## Mount the usbfs for use with Virtual Box
domount usbfs usbdevfs /proc/bus/usb -onoexec,nosuid,nodev,devgid=124,devmode=664

You may not need to reboot, try doing:
sudo /etc/init.d/mountkernfs.sh

If not, reboot, and virtualbox should detect your usb devices!
Regarding the part of 'magic' in mountdevsubfs.sh, you can compare with mine if it is not in your file:
Code:
#! /bin/sh
### BEGIN INIT INFO
# Provides:          mountdevsubfs
# Required-Start:    mountkernfs
# Required-Stop:
# Should-Start:      udev
# Default-Start:     S
# Default-Stop:
# Short-Description: Mount special file systems under /dev.
# Description:       Mount the virtual filesystems the kernel provides
#                    that ordinarily live under the /dev filesystem.
### END INIT INFO
#
# This script gets called multiple times during boot
#

PATH=/lib/init:/sbin:/bin
TTYGRP=5
TTYMODE=620
[ -f /etc/default/devpts ] && . /etc/default/devpts

TMPFS_SIZE=
[ -f /etc/default/tmpfs ] && . /etc/default/tmpfs

KERNEL="$(uname -s)"

. /lib/lsb/init-functions
. /lib/init/mount-functions.sh

do_start () {
	#
	# Mount a tmpfs on /dev/shm
	#
	SHM_OPT=
	[ "${SHM_SIZE:=$TMPFS_SIZE}" ] && SHM_OPT=",size=$SHM_SIZE"
	domount tmpfs shmfs /dev/shm tmpfs -onosuid,nodev$SHM_OPT

	#
	# Mount /dev/pts. Master ptmx node is already created by udev.
	#
        domount devpts "" /dev/pts devpts -onoexec,nosuid,gid=$TTYGRP,mode=$TTYMODE

# Magic to make /proc/bus/usb work
	#
	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
}

case "$1" in
  "")
	echo "Warning: mountdevsubfs should be called with the 'start' argument." >&2
	do_start
	;;
  start)
	do_start
	;;
  restart|reload|force-reload)
	echo "Error: argument '$1' not supported" >&2
	exit 3
	;;
  stop)
	# No-op
	;;
  *)
	echo "Usage: mountdevsubfs [start|stop]" >&2
	exit 3
	;;
esac
Robert
The Cokeaholics is offline  
Old October 13th, 2008   #5
Delvien
Ubuntu Extra Shot
 
Delvien's Avatar
 
Join Date: Oct 2005
Location: Columbus Ohio
Beans: 394
Ubuntu Karmic Koala (testing)
Re: Intrepid/Virtualbox/USB

Quote:
Originally Posted by The Cokeaholics View Post
Here you go:
HTML Code:
http://www.ubuntu-unleashed.com/2008/04/howto-install-virtualbox-in-hardy-heron.html
It mentions Hardy but worked out for me.

This doesn't work in intrepid due to the changes. You must add the information to fstab. Its alot easier to do imo: )
Delvien is offline  
Old October 13th, 2008   #6
txHarleyMan
5 Cups of Ubuntu
 
txHarleyMan's Avatar
 
Join Date: Jun 2007
Location: Texas
My beans are hidden!
Ubuntu 9.10 Karmic Koala
Re: Intrepid/Virtualbox/USB

Quote:
Originally Posted by Delvien View Post
This doesn't work in intrepid due to the changes. You must add the information to fstab. Its alot easier to do imo: )
Correct. Working fine now. Thanks, All!
__________________
txHarleyMan
Registered Linux User #443027
txHarleyMan is offline  
Old October 24th, 2008   #7
c0mp13371331337
Just Give Me the Beans!
 
c0mp13371331337's Avatar
 
Join Date: Oct 2007
Beans: 55
Ubuntu 8.10 Intrepid Ibex
Re: Intrepid/Virtualbox/USB

Quote:
Originally Posted by ju2wheels View Post
Code:
#usbfs
none /proc/bus/usb usbfs devgid=46,devmode=664 0 0
This worked like a charm for me in Intrepid. Thanks!
c0mp13371331337 is offline  
Old October 25th, 2008   #8
davidfg4
First Cup of Ubuntu
 
Join Date: Nov 2006
Beans: 11
Re: Intrepid/Virtualbox/USB

This did not work for me.
I made sure I am in the vboxusers group, added the line from ju2wheels's post to my fstab, and restarted.
I also tried having devmode=666 and devgid=124 (the id of the vboxusers group).
No matter what I tried nothing ever showed up in the Devices > USB Devices menu.
I am on Intrepid and using virtualbox 2.0.2_OSE.
Any ideas as to what I am missing?

David

EDIT: It looks like the OSE edition does not support usb, I will get the non OSE version.

Last edited by davidfg4; October 25th, 2008 at 08:52 PM..
davidfg4 is offline  
Old October 25th, 2008   #9
davidfg4
First Cup of Ubuntu
 
Join Date: Nov 2006
Beans: 11
Re: Intrepid/Virtualbox/USB

Alright, I got it working!
Thanks everyone!
davidfg4 is offline  
Old October 25th, 2008   #10
inportb
Grande Half-n-Half Cinnamon Ubuntu
 
inportb's Avatar
 
Join Date: Jan 2007
Beans: 943
Kubuntu Development Release
Re: Intrepid/Virtualbox/USB

Wow, I didn't know the solution would be so simple. I never really had to use USB in a VM, but the warning box was always a bit unsettling =p

It's easier than the Hardy fix.
__________________
my shiz: http://inportb.com/
inportb is offline  
 

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 09:06 PM.


vBulletin ©2000 - 2010, Jelsoft Enterprises Ltd. Ubuntu Logo, Ubuntu and Canonical © Canonical Ltd. Tango Icons © Tango Desktop Project. bilberry