Connect read-only USB device to multiple VM's simultaneously

This is for discussing general topics about how to use VirtualBox.
Post Reply
cmundi
Posts: 2
Joined: 27. Jul 2009, 23:53
Primary OS: MS Windows XP
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: WinXP32

Connect read-only USB device to multiple VM's simultaneously

Post by cmundi »

I am evaluating VirtualBox PUEL. I have a USB flash drive used to distribute fixed data. I would like to mount it readonly and allow multiple guest VM's to read asynchronously from this USB device. Is this possible? By default (at least) it seems that a USB device can be captured by only one VM at a time.

Thanks,
Carlos
Sasquatch
Volunteer
Posts: 17798
Joined: 17. Mar 2008, 13:41
Primary OS: Debian other
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Windows XP, Windows 7, Linux
Location: /dev/random

Re: Connect read-only USB device to multiple VM's simultaneously

Post by Sasquatch »

You can't connect the same USB device to multiple physical machines, so don't ask for the impossible. Even if it's read only, only one machine can access it. Can more than one PC access the same cdrom on a physical level? No it can't, because it can't be in multiple places at the same time (i.e. other optical drives). Only through network sharing can you access the drive, but that's not the same.
Read the Forum Posting Guide before opening a topic.
VirtualBox FAQ: Check this before asking questions.
Online User Manual: A must read if you want to know what we're talking about.
Howto: Install Linux Guest Additions
Howto: Use Shared Folders on Linux Guest
See the Tutorials and FAQ section at the top of the Forum for more guides.
Try searching the forums first with Google and add the site filter for this forum.
E.g. install guest additions site:forums.virtualbox.org

Retired from this Forum since OSSO introduction.
mpack
Site Moderator
Posts: 39134
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Mostly XP

Re: Connect read-only USB device to multiple VM's simultaneously

Post by mpack »

cmundi, you can't do exactly what you asked, so I would recommend instead that you look at creating a shared folder that all the VMs can access. It does not need to be readonly, though that option is available. I've just tested it, and shared folders can exist on a removable drive. The drive doesn't even need to be plugged in when the VM starts.
cmundi
Posts: 2
Joined: 27. Jul 2009, 23:53
Primary OS: MS Windows XP
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: WinXP32

Re: Connect read-only USB device to multiple VM's simultaneously

Post by cmundi »

@mpack: Thanks for your reply which is actually helpful. I am successfully using your suggestion. Brilliant! Thanks!
Perryg
Site Moderator
Posts: 34369
Joined: 6. Sep 2008, 22:55
Primary OS: Linux other
VBox Version: OSE self-compiled
Guest OSses: *NIX

Re: Connect read-only USB device to multiple VM's simultaneously

Post by Perryg »

I became so frustrated with the way that USB worked in a Windows host that I switched to doing exactly this a long time ago.
Now I can access or not when I choose and do not need to deal with the problems. I leave USB switched off completely now.
Actually it works really well and Windows does not get mad anymore which in turn keeps me from getting upset too. Making this a win-win situation. :wink:
Post Reply