Page 1 of 2 12 LastLast
Results 1 to 10 of 20

Thread: Virtualbox 3.0.6 USB support

  1. #1
    Join Date
    Jul 2008
    Location
    Poland
    Posts
    260

    Default Virtualbox 3.0.6 USB support

    How to enable USB support for Virtualbox 3.0.6 non-OSE on openSUSE 11.1?
    The FAQ for VB 2.0.2 doesn't work

  2. #2

    Default Re: Virtualbox 3.0.6 USB support

    Have the same problem and no solution!!
    Nobody any solution??
    -----------
    Linux 2.6.27.7-9-pae i686//openSUSE 11.1 (i586)//3.5.10 "release 21.9" "release 4.9"
    on LENOVO 3000 N500

  3. #3

    Default Re: Virtualbox 3.0.6 USB support

    Hi rozbarwinek,
    are you still interested in a solution?
    I've found one )
    and my USB SanDisk U3 Cruzer is running properly!!

    cu
    aiko
    -----------
    Linux 2.6.27.7-9-pae i686//openSUSE 11.1 (i586)//3.5.10 "release 21.9" "release 4.9"
    on LENOVO 3000 N500

  4. #4
    Join Date
    Jun 2008
    Location
    USA
    Posts
    1,120

    Default Re: Virtualbox 3.0.6 USB support

    Add me to that list. It stopped working with a kernel update, at least as far as I can recall. I did the recompiling, as instructed, but usb connectivity did not come back.

  5. #5

    Default Re: Virtualbox 3.0.6 USB support

    My workflow for the installation was the following:

    1. I downloaded SUN VBox (non-OSE) => VirtualBox-3.0.6_52128_openSUSE111-1.i586.rpm from the SUN HP
    2. I installed: kernel-sources, kernel-headers, gcc, pam-devel and make with YAST
    3. I installed rpm - file as root(!) in a console with: rpm -ivh VirtualBox-3.0.6_52128_openSUSE111-1.i586.rpm
    4. The installation rebuilt the kernel with no problem!
    5. My User-account was automatically added to the VBOXUSER-group

    I started VBox with my User-account (not as root!) and that's the problem,
    (from my very limited linux knowledge). VBox has been installed as root, but was not started as
    root, so not the whole functionality is available!
    I installed W2K3 Server in the VBox. I saw the USB devices including my USB SanDisk Stick, but
    after booting W2K3 the USB stick was not available!

    Maybe there is an easier way, but I solved it with the following:
    1. open a console - su - VirtualBox (start VBox as user root!)
    2. VBox started "untouched"! I expected to see my W2K3 installation, but there was nothing!
    3. I thought about re-installing, but there was already an installation and I didn't want to spend
    the same amount of time for re-installing )
    4. So I did the following:
    NEW - CONTINUE - choose a name and OS - CONTINUE - USE HARDDRIVE - BROWSE - ADD -
    filename: /home/YOUR-USR-NAME/.VirtualBox/HardDisks/YOUR-FORMER-OS-NAME.vdi
    (You can't browse to that directory and filename, you have to type it!!!)
    The rest is self-explaining .......

    My USB stick was connected all the time! In VBox I marked the USB stick and started W2K3
    and ... olala ... the USB stick was available!!! But only if you start VBox as root!!!

    Hope you will be as succesfull as I was ......

    Next issue will be to get the internet running )

    cu
    aiko
    -----------
    Linux 2.6.27.7-9-pae i686//openSUSE 11.1 (i586)//3.5.10 "release 21.9" "release 4.9"
    on LENOVO 3000 N500

  6. #6
    Join Date
    Jun 2008
    Location
    UK
    Posts
    5,500

    Default Re: Virtualbox 3.0.6 USB support

    It's a bad idea to run VirtualBox as root, even though Yast (as root) installs it. There are plenty of previous VBox threads in the forum saying the same. I have just upgraded from 3.0.4 to 3.0.6 (non-OSE) as a normal user, using Yast (as root). One of the smoothest VBox installs to date (on 11.1), my VM picked up a USB memory stick that worked flawlessly and released back to the host on shutting down the VM. VBox closed normally, I rebooted the m/c and repeated the test. All done as normal user, and not a hiccup.

    I download VBox, place rpm(s) in a directory (any name you like) in /home. That directory is set up in Yast>Software Repositories, as a local repo and enabled. You then do the upgrade via Yast in the normal way. You can leave previous VBox rpm versions in that local repo, but I found I need to refresh the repo after adding the new rpm, to pick it up when in Yast>Software Management (or Install Software from Kickoff menu).

    A search of the forum for previous VirtualBox threads would have explained all this, and much more about attaching USB devices. There are threads more recent than the Howto for 2.0.2 (assume the OP refers to caf4926's). Howto's are often superceded by forum threads. You need to search for them.

  7. #7

    Default Re: Virtualbox 3.0.6 USB support

    Hi consused,
    I agree, starting anything as root is no good idea!!!
    The only workaround is to edit fstab or to umount and mount usbfs with new settings before using VBox after every reboot :-(
    But why is root able to do it without changing fstab? There must be another solution!!
    But for now I do the following as described in [Solved]USB only working for some devices, others greyed out (View topic) • virtualbox.org

    1. umount /proc/bus/usb/
    2. mount -n -t usbfs /proc/bus/usb /proc/bus/usb -o devgid=113,devmode=664
    (Of course the number given at devgid is the group ID of group "vboxusers".)

    I will test editing fstab later! The current fstab says:
    usbfs /proc/bus/usb usbfs noauto 0 0

    Anybody any better idea?
    -----------
    Linux 2.6.27.7-9-pae i686//openSUSE 11.1 (i586)//3.5.10 "release 21.9" "release 4.9"
    on LENOVO 3000 N500

  8. #8
    Will Honea NNTP User

    Default Re: Virtualbox 3.0.6 USB support

    consused wrote:

    >
    > It's a bad idea to run VirtualBox as root, even though Yast (as root)
    > installs it. There are plenty of previous VBox threads in the forum
    > saying the same. I have just upgraded from 3.0.4 to 3.0.6 (non-OSE) as
    > a* normal user*, using Yast (as root). One of the smoothest VBox
    > installs to date (on 11.1), my VM picked up a USB memory stick that
    > worked flawlessly and released back to the host on shutting down the VM.
    > VBox closed normally, I rebooted the m/c and repeated the test. All done
    > as normal user, and not a hiccup.
    >
    > I download VBox, place rpm(s) in a directory (any name you like) in
    > /home. That directory is set up in Yast>Software Repositories, as a
    > local repo and enabled. You then do the upgrade via Yast in the normal
    > way. You can leave previous VBox rpm versions in that local repo, but I
    > found I need to refresh the repo after adding the new rpm, to pick it up
    > when in Yast>Software Management (or Install Software from Kickoff
    > menu).
    >
    > A search of the forum for previous VirtualBox threads would have
    > explained all this, and much more about attaching USB devices. There are
    > threads more recent than the Howto for 2.0.2 (assume the OP refers to
    > caf4926's). Howto's are often superceded by forum threads. You need to
    > search for them.


    There is a subtle trap here. To install VBox, you need root privileges. To
    get the right permissions and location on the .virtualbox directory, you
    have to run the install as the intended user via sudo (or just su and NOT
    su - ). Something learned the hard way. Try all 3 and you'll see subtle
    (and some no-so-subtle) differences. As above, RTFM and do it their way.

    I'm still trying to figure out the magic incantation that will install VBox
    once and alow access to the same virtual machine by several users (one at a
    time) but so far I keep hitting the issues the OP found with one or more
    users no matter what I try.

    --
    Will Honea

  9. #9
    Join Date
    Jun 2008
    Location
    UK
    Posts
    5,500

    Default Re: Virtualbox 3.0.6 USB support

    Hi Will
    Seems a long time since we were thrashing this stuff around. Thanks for explaining the privileges, from under the hood. That's a neat way of nailing the subtleties.

  10. #10
    Join Date
    Jun 2008
    Location
    UK
    Posts
    5,500

    Default Re: Virtualbox 3.0.6 USB support

    Hi @aiko1603 and other interested users.

    You may find some of the old threads on enabling USB devices in VirtualBox, rather long and difficult to follow as several solutions were developed and some were rejected. I will give a link to the original thread containing this solution (arguably the best) at the end of this post. Anyway I've been using this one since VBox 2.2.0 and through all the upgrades to 3.0.6, so here it is:

    This is what my fstab contains (the permanent partition mounts are not shown here):
    Code:
    proc                 /proc                proc       defaults              0 0
    sysfs                /sys                 sysfs      noauto                0 0
    debugfs              /sys/kernel/debug    debugfs    noauto                0 0
    #usbfs                /proc/bus/usb        usbfs      noauto                0 0
    devpts               /dev/pts             devpts     mode=0620,gid=5       0 0
    Notice the usbfs statement is commented out by inserting "#" at the beginning of the line. That's the safe way to disable it, but you could also delete the line, after successful testing. It's not required, and some distros don't include it now.

    Your mount commands:
    Code:
    1. umount /proc/bus/usb/
    2. mount -n -t usbfs /proc/bus/usb /proc/bus/usb -o devgid=113,devmode=664
    I don't need these, as they belong to old solutions and the use of /proc/bus/usb was deprecated by the VirtualBox people. So start again without them.

    Proceed as follows:

    You should have commented out any usbfs statements in /etc/fstab as above, and remove any mount -a command in etc/init.d/boot.local.

    You need to start with an unmodified /etc/udev/rules.d/10-vboxdrv.rules file e.g. the one produced by a newly installed VirtualBox. Also make sure you don't have a 60-vboxdrv.rules file in that directory. If there is one delete it.

    Copy the file /lib/udev/rules.d/50-udev-default.rules into the directory /etc/udev/rules.d where it will take precedence. This will work according to the udev man page (to be found by entering man:udev in konqueror's address bar).

    The copied file now at /etc/udev/rules.d/50-udev-default.rules should contain amongst others, the following rule
    Code:
    # libusb device nodes
    SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device", NAME="bus/usb/$env{BUSNUM}/$env{DEVNUM}", MODE="0644"
    This default rule is preventing 10-vboxdrv.rules from working OOTB. Comment it out by editing the file and inserting "#" at the start of the line thus:
    Code:
    # libusb device nodes
    #SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device", NAME="bus/usb/$env{BUSNUM}/$env{DEVNUM}", MODE="0644"
    Save it, and reboot the system. I connect up the USB devices on the host, before starting VirtualBox. If you set them up correctly in VirtaulBox usb settings, they should be automatically acquired by the VM on starting it.

    Please note, that this solution is for openSUSE 11.1 only, and if openSUSE updates the default rules file /lib/udev/rules.d/50-udev-default.rules, then you will have to repeat the steps to copy it over to /etc/udev/rules.d and comment out the rule as before.

    For the next release of openSUSE (11.2), none of the above modifications should be necessary, and it will hopefully work OOTB.

    You can read the original solution-testing thread here. It's Solution #4, summarized in post #74.

    Good luck.

Page 1 of 2 12 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •