Virtualbox

Raw access

First of all plug-in the device you want to access directly, e.g. a USB-Disk. Make sure, it is not mounted automatically.

On Windows, you also need the special device specification like “\\.\PhysicalDrive0” for the device. You can get it with the following command

wmic diskdrive list brief 

The result could look like

>wmic diskdrive list brief
Caption                       DeviceID            Model                         Partitions  Size
ST9320423AS                   \\.\PHYSICALDRIVE0  ST9320423AS                   3           320070320640
TOSHIBA MK1059GSM USB Device  \\.\PHYSICALDRIVE1  TOSHIBA MK1059GSM USB Device  1           1000202273280

In this example, I want to have raw access to \\.\PHYSICALDRIVE1

To enable RAW access to this device, you have to create a vmdk file with RAW access.

  1. Start VirtualBox as administrator
  2. Execute the following command as administrator!
VBoxManage internalcommands createrawvmdk -filename d:\vms\raw.vmdk -rawdisk \\.\PHYSICALDRIVE1

It should result in

>  VBoxManage internalcommands createrawvmdk -filename d:\vms\raw.vmdk -rawdisk \\.\PHYSICALDRIVE1
RAW host disk access VMDK file d:\vms\raw.vmdk created successfully.

You can read more about this procedure and alsow how to access single partitons in this document http://www.virtualbox.org/manual/ch09.html#rawdisk

You can now create a virtual machine and add the created raw.vmdk to it as HDD (on Windows make sure VirtualBox runs as Administrator).

O

public/virtualbox.txt · Last modified: 2015/08/11 08:20 (external edit)
CC Attribution-Share Alike 3.0 Unported
Driven by DokuWiki Recent changes RSS feed Valid CSS Valid XHTML 1.0