• Virtualbox - How To Share USB Device


    Hey Everyone,

    As the subject states, I have a USB drive I’d like to share with a VM running under Virtualbox. It doesn’t seem to want to ‘share’ the drive, even though Antergos sees it without any issues.

    Is there an easy way to resolve this issue? TIA.

  • @a4orce84

    To detect USB drives under virtualbox you can try 2 things.

    1. Add an entry at configurations like the picture

    0_1534359577515_Screenshot_4.png
    Play with different controlers, one of them may work.

    1. Adding vboxsf and your user to /etc/group
      Mine it’s like this:
    vboxsf:x:109:fernando
    
  • Unfortunately, option #2 did not work for me. No USBs detected in my VM or inside Virtualbox. Are there steps missing?

  • @a4orce84

    Are there steps missing?

    Did you install the vbox ectensions?

    https://download.virtualbox.org/virtualbox/5.2.18/Oracle_VM_VirtualBox_Extension_Pack-5.2.18.vbox-extpack

    from https://www.virtualbox.org/wiki/Downloads page

    You need to download it, go to file > preferences > extensions > click add >select the downloaded file.

    Maybe rebooting after adding to groups too…

  • @fernandomaroto @a4orce84
    Or install AUR package virtualbox-ext-oracle to the host.

  • And install virtualbox-guest-utils and virtualbox-guest-dkms to the guest…
    and linux headers… ;)

  • @manuel
    Maybe, i have all the things both you and me described here, and my virtuablox works fine.

    But i think he needs to install the vbox extension, that enables the usb controlers for sure.

  • @fernandomaroto Agreed, the extensions are required.

  • Hey Guys,

    So I installed the following packages specifically:
    virtualbox-ext-oracle
    virtualbox-guest-utils
    virtualbox-guest-dkms

    After installing everything, when I restarted I was greeted with this error:
    https://imgur.com/a/E7rRgUC

    An issue with Virtualbox kernal? Regardless, I tried again to see if USB would work in my Virtualbox VM, and it did NOT.

    Is there something else I need to do, or am missing to get things working properly? Thanks in advance for everyone’s time and help, it is greatly appreciated!

    Thanks,
    Asif

  • @a4orce84 this error is shown here also but virtualbox is working perfectly… you can ignore this error.

    0_1534434854184_usb-vb.png

    pacman -Qs virtualbox
    
    local/virtualbox 5.2.18-1
        Powerful x86 virtualization for enterprise as well as home use
    local/virtualbox-ext-oracle 5.2.18-1
        Oracle VM VirtualBox Extension Pack
    local/virtualbox-guest-iso 5.2.18-1
        The official VirtualBox Guest Additions ISO image
    local/virtualbox-guest-modules-arch 5.2.18-1
        Virtualbox guest kernel modules for Arch Kernel
    local/virtualbox-guest-utils 5.2.18-1
        VirtualBox Guest userspace utilities
    local/virtualbox-host-dkms 5.2.18-1
        VirtualBox Host kernel modules sources
    
  • Here is my output:

    [[email protected] ~]$ pacman -Qs virtualbox
    local/virtualbox 5.2.18-1
        Powerful x86 virtualization for enterprise as well as home use
    local/virtualbox-ext-oracle 5.2.18-1
        Oracle VM VirtualBox Extension Pack
    local/virtualbox-ext-vnc 5.2.18-1
        VirtualBox VNC extension pack
    local/virtualbox-guest-dkms 5.2.18-1
        VirtualBox Guest kernel modules sources
    local/virtualbox-guest-utils 5.2.18-1
        VirtualBox Guest userspace utilities
    local/virtualbox-host-modules-arch 5.2.18-1
        Virtualbox host kernel modules for Arch Kernel
    

    And when I try to access the USB drive in my VM, I see this:
    https://imgur.com/a/vRD671i

    No USB devices. Should I match and install the exact packages you have @joekamprad ?

  • @a4orce84
    This link may help: https://forum.antergos.com/topic/9319/how-to-install-virtualbox

    It is important to install correct packages to host and guest, not everything to both. :)

  • @a4orce84 you need to follow the wiki to get virtualbox fully working, and make sure you have installed the guest addition inside windows (virtual) also!

  • Followed the wiki, and installed the correct packages. We are getting closer, but no cigar yet:

    Screenshot:
    https://imgur.com/a/5IkYI6p

    Windows tried to install a device driver for the USB drive I have connected (PNY in the screenshot above), but it fails. Can’t “mount” the drive inside my Windows VM.

  • @a4orce84
    So you have Antergos as host, and Windows as guest?

    In that case, on Antergos you need packages:

    linux-headers and/or linux-lts-headers depending on your kernel
    virtualbox
    virtualbox-guest-iso
    virtualbox-host-dkms
    virtualbox-ext-oracle  (from AUR)
    

    The above assumes using dkms, which is easier if you happen to run a different kernel.

    On Windows you need to install Oracle’s Guest Additions. It will appear as CD drive after you install it in the VM’s Devices menu, Insert Guest Additions CD image). On the CD there’s a file VBoxWindowsAdditions.exe that you need to run.

    Guest Additions are provided by Antergos to Windows (that virtualbox-guest-iso you installed to Antergos).

  • And the USB devices AFAIK can be used only on one “side” at a time, i.e. on Windows or on Antergos but not both.

  • @manuel said in Virtualbox - How To Share USB Device:

    It is important to install correct packages to host and guest, not everything to both

    The problem is that if you install virtualbox, for some reason it installs both host and guest into the host machine.

    To fix this error described by @a4orce84 it’s needed to uninstall virtualbox-guest-dkms with -Rdd (in the host machine) option and remove de module with sudo rm /usr/lib/modules-load.d/virtualbox-guest-dkms.conf

    @a4orce84 Did you install the extensions from virtualbox i linked there? You really need it.
    https://download.virtualbox.org/virtualbox/5.2.18/Oracle_VM_VirtualBox_Extension_Pack-5.2.18.vbox-extpack

    Another thing since you’re running windows is to install Vbox stuff inside it.
    Go to devices>add guest image> go to my computer> run vbox installer> restart

  • @manuel, I answer your questions directly below:

    So you have Antergos as host, and Windows as guest?
    Yes

    Current packages I have installed (that match @joekamprad installation):

    [[email protected] ~]$ pacman -Qs virtualbox
    local/virtualbox 5.2.18-1
        Powerful x86 virtualization for enterprise as well as home use
    local/virtualbox-ext-oracle 5.2.18-1
        Oracle VM VirtualBox Extension Pack
    local/virtualbox-ext-vnc 5.2.18-1
        VirtualBox VNC extension pack
    local/virtualbox-guest-iso 5.2.18-1
        The official VirtualBox Guest Additions ISO image
    local/virtualbox-guest-modules-arch 5.2.18-1
        Virtualbox guest kernel modules for Arch Kernel
    local/virtualbox-guest-utils 5.2.18-1
        VirtualBox Guest userspace utilities
    local/virtualbox-host-dkms 5.2.18-1
        VirtualBox Host kernel modules sources
    

    Guest Additions:
    I do not see an optical drive to mount:
    https://imgur.com/a/eXGNh4a

    Is this a separate step and how do I install it?

    @fernandomaroto, I answer your questions directly below:
    Uninstall ‘virtualbox-guest-dkms’:
    ****This is directly the opposite of what @manuel said: ****
    Manuel: In that case, on Antergos you need packages:

    linux-headers and/or linux-lts-headers depending on your kernel
    virtualbox
    virtualbox-guest-iso
    virtualbox-host-dkms
    virtualbox-ext-oracle  (from AUR)
    

    VirtualBox Extensions:
    I’m honestly not sure, I see it listed under extensions in my VirtualBox preferences here:
    https://imgur.com/a/illzEQv

    VirtualBox Installer Inside Windows:
    I do not have the ‘add guest image’ option as you are referencing:
    https://imgur.com/a/eXGNh4a


    It’s somewhat hard to understand what is missing @manuel and @fernandomaroto, you are both giving me conflicting messages at least with the specific VirtualBox packages I should be installing (install dkms, uninstall dkms, etc.).

  • Sorry guys! I just went back and realized one of you were talking about ‘virtualbox-host-dkms’ and the other was talking about ‘virtualbox-guest-dkms’. All starting to get a bit confused with my old eyes I suppose.

    Either way, my current virtualbox package list is the following:

    [[email protected] ~]$ pacman -Qs virtualbox
    local/virtualbox 5.2.18-1
        Powerful x86 virtualization for enterprise as well as home use
    local/virtualbox-ext-oracle 5.2.18-1
        Oracle VM VirtualBox Extension Pack
    local/virtualbox-ext-vnc 5.2.18-1
        VirtualBox VNC extension pack
    local/virtualbox-guest-iso 5.2.18-1
        The official VirtualBox Guest Additions ISO image
    local/virtualbox-guest-modules-arch 5.2.18-1
        Virtualbox guest kernel modules for Arch Kernel
    local/virtualbox-guest-utils 5.2.18-1
        VirtualBox Guest userspace utilities
    local/virtualbox-host-dkms 5.2.18-1
        VirtualBox Host kernel modules sources
    

    Let me know if I need to remove or install any additional packages at all. Thanks again, all your time and help is super appreciated.

  • @a4orce84

    Uninstall virtualbox-guest-dkms as you do not need them on host installed, only if you run antergos as a virtual machine… and keep virtualbox-host-dkms is not the opposite ;)

    virtualbox-guest-modules-arch and virtualbox-guest-utils are not needed also… wiki say:

    sudo pacman -S virtualbox virtualbox-guest-iso net-tools linux-headers virtualbox-host-dkms
    
usb116 virtualbox46 device28 share10 Posts 33Views 1542
Log in to reply
Bloom Email Optin Plugin

Looks like your connection to Antergos Community Forum was lost, please wait while we try to reconnect.