Created
December 14, 2014 20:37
-
-
Save ringods/6ea183c5b86ce95e8d90 to your computer and use it in GitHub Desktop.
VirtualBox and raw host disk access
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
virtualbox@host:~$ VBoxManage storageattach machine1 –storagectl “SATA Controller” –port 0 –type hdd –medium /home/virtualbox/virtualmachines/machine1/machine1-sda.vmdk |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
virtualbox@host:~$ VBoxManage internalcommands createrawvmdk -filename /home/virtualbox/virtualmachines/machine1/machine1-sda.vmdk -rawdisk /dev/sda -partitions 3,4 -relative | |
RAW host disk access VMDK file /home/virtualbox/virtualmachines/machine1/machine1-sda.vmdk created successfully. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
root@host:~# usermod –groups disk -a virtualbox |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
root@host:~# ls -l /dev/sda* | |
brw-rw—- 1 root disk 8, 0 Aug 20 15:11 /dev/sda | |
brw-rw—- 1 root disk 8, 1 Aug 10 17:37 /dev/sda1 | |
brw-rw—- 1 root disk 8, 2 Aug 10 17:37 /dev/sda2 | |
brw-rw—- 1 root disk 8, 3 Aug 21 09:43 /dev/sda3 | |
brw-rw—- 1 root disk 8, 4 Aug 21 09:43 /dev/sda4 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
virtualbox@host:~$ VBoxManage showvminfo machine1 | |
… | |
SATA Controller (0, 0): /home/virtualbox/virtualmachines/machine1/machine1-sda.vmdk (UUID: afc0a…) | |
… |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment