I have a Linux image running on an early 2013 MacBook Pro. The MBP is fitted with a SD card socket.
The VM is working AOK but I want to access a SD card from the VM. Is it possible to connect a VirtualBox VM to the SD card socket?
If so how do I go about achieving this?
Can a Macbook Pro SD card be accessed by a VirtualBox Linux VM?
-
- Site Moderator
- Posts: 39134
- Joined: 4. Sep 2008, 17:09
- Primary OS: MS Windows 10
- VBox Version: PUEL
- Guest OSses: Mostly XP
Re: Can a Macbook Pro SD card be accessed by a VirtualBox Linux VM?
An SD card is no different than any other USB memory stick (internally such devices are attached to the USB bus).
So yes, you can access it as a USB device. Or, if you don't need sector level access then you can access it even more simply using a shared folder. Don't try to do both at the same time.
So yes, you can access it as a USB device. Or, if you don't need sector level access then you can access it even more simply using a shared folder. Don't try to do both at the same time.
Re: Can a Macbook Pro SD card be accessed by a VirtualBox Linux VM?
Thanks @mpack
I thought as much but appreciate the confirmation. Anticipating this I've been studying the advice in forum topic viewtopic.php?f=35&t=82639 regarding "Capturing a USB device in VirtualBox".
Following this guidance I've clicked the USB icon at the bottom of the screen, found reference to the "Apple Internal Memory Card Reader", selected this with a pop up confirmation that the device has been "Captured". I tried to attach a screen image of the desktop showing this pop up but I'm apparently too much of a newbie to have that permission to do that as yet.
My problem is the device does not appear to be showing up as accessible to the OS. I ran the command in a terminal window and in addition to VM file disk there is a device showing as:
I thought as much but appreciate the confirmation. Anticipating this I've been studying the advice in forum topic viewtopic.php?f=35&t=82639 regarding "Capturing a USB device in VirtualBox".
Following this guidance I've clicked the USB icon at the bottom of the screen, found reference to the "Apple Internal Memory Card Reader", selected this with a pop up confirmation that the device has been "Captured". I tried to attach a screen image of the desktop showing this pop up but I'm apparently too much of a newbie to have that permission to do that as yet.
My problem is the device does not appear to be showing up as accessible to the OS. I ran the
Code: Select all
sudo fdisk -l
This does not appear to be the SD card.Disk /dev/loop0: 252.8MiB ...
Last edited by socratis on 23. Feb 2018, 05:38, edited 1 time in total.
Reason: Added missing URL.
Reason: Added missing URL.
Re: Can a Macbook Pro SD card be accessed by a VirtualBox Linux VM?
As an alternative I tried running the Debian image native off an external USB stick with the same sized disk space as the VM and had no difficulty accessing the SD Card device.
Whatever is problem while running as a VM appears to be isolated to the VM environment.
Whatever is problem while running as a VM appears to be isolated to the VM environment.
-
- Site Moderator
- Posts: 27329
- Joined: 22. Oct 2010, 11:03
- Primary OS: Mac OS X other
- VBox Version: PUEL
- Guest OSses: Win(*>98), Linux*, OSX>10.5
- Location: Greece
Re: Can a Macbook Pro SD card be accessed by a VirtualBox Linux VM?
Take a look at ch. 8.8.8. USB card reader settings. It's too small, so I'll quote the whole ch. here:
Sometime the distinct "hardware presence" is required to trigger services/daemons in the guest.The following setting defines access to a USB Card Reader by the guest environment. USB card readers are typically used for accessing data on memory cards such as CompactFlash (CF), Secure Digital (SD) or MultiMediaCard (MMC).
--usbcardreader on|off: Enables/disables the USB card reader interface.
Do NOT send me Personal Messages (PMs) for troubleshooting, they are simply deleted.
Do NOT reply with the "QUOTE" button, please use the "POST REPLY", at the bottom of the form.
If you obfuscate any information requested, I will obfuscate my response. These are virtual UUIDs, not real ones.
Do NOT reply with the "QUOTE" button, please use the "POST REPLY", at the bottom of the form.
If you obfuscate any information requested, I will obfuscate my response. These are virtual UUIDs, not real ones.
Re: Can a Macbook Pro SD card be accessed by a VirtualBox Linux VM?
Ok, and where does this setting go? How is it used?
I have a Ubuntu 18.04.3 LTS guest running on my MacBook Pro using VB 6.1. I have setup a filter in the VM's Settings assigning the Card Reader (Apple Internal Memory Card Reader [0820], Vendor ID 05ac, Product ID 8406, Revision 820, ...) but Ubuntu never sees the card reader.
I have also tried assigning it using the USB tool in the status bar at the bottom of the guest's window, but then I get a message:
"Failed to attach the USB device Apple Internal Memory Card Reader [0820] to the virtual machine <VMname>".
Whenever I plug in a SD card, the Mac mounts the partitions.
I operate VB exclusively through the GUI. Is this something that should be done via CLI?
I have a Ubuntu 18.04.3 LTS guest running on my MacBook Pro using VB 6.1. I have setup a filter in the VM's Settings assigning the Card Reader (Apple Internal Memory Card Reader [0820], Vendor ID 05ac, Product ID 8406, Revision 820, ...) but Ubuntu never sees the card reader.
I have also tried assigning it using the USB tool in the status bar at the bottom of the guest's window, but then I get a message:
"Failed to attach the USB device Apple Internal Memory Card Reader [0820] to the virtual machine <VMname>".
Whenever I plug in a SD card, the Mac mounts the partitions.
I operate VB exclusively through the GUI. Is this something that should be done via CLI?
-
- Site Moderator
- Posts: 20945
- Joined: 30. Dec 2009, 20:14
- Primary OS: MS Windows 10
- VBox Version: PUEL
- Guest OSses: Windows, Linux
Re: Can a Macbook Pro SD card be accessed by a VirtualBox Linux VM?
If "this setting" refers to '--usbcardreader on|off', a quick way to find it is to open the PDF copy of the Virtualbox manual found in the Virtualbox installation folder and search for 'usbcardreader'.Nap wrote:where does this setting go? How is it used?
My searching reveals to me that '--usbcardreader' is part of the command-line 'vboxmanage modifyvm' command.