Monday, August 30, 2010

Note about permissions in VirtualBox physical hard disk usage in Linux host

From VirtualBox manual: "Starting with version 1.4, as an alternative to using virtual disk images, VirtualBox can also present either entire physical hard disks or selected partitions thereof as virtual disks to virtual machines...
...this type of access is called "raw hard disk access"; it allows a guest OS to access its virtual hard disk without going through the host OS file system."
Do read the manual (part 9.7.1 at now) and do it at your own risk! Here we will talk only about permission problem you can get in Linux host. That, you will need read/write access for the entire disk (or selected partitions). For example:

$ VBoxManage internalcommands createrawvmdk -filename $HOME/.VirtualBox/HardDisks/sda2.vmdk -rawdisk /dev/sda -partitions 2

set up an image for access /dev/sda2 in Linux host. User needs read/write access to this partition. Otherwise, we will get some messages like this while adding sda2.vmdk to a virtual machine:

NS_ERROR_FAILURE (0x80004005)
Component: 
HardDisk
Interface: 
IHardDisk {xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx}
Callee: 
IVirtualBox {xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx}

Check the physical disks properties:

$ ls -l /dev/sda*

brw-rw---- 1 root disk 8, 0 2010-08-30 21:53 /dev/sda
brw-rw---- 1 root disk 8, 1 2010-08-30 12:22 /dev/sda1
brw-rw---- 1 root disk 8, 2 2010-08-30 21:31 /dev/sda2
brw-rw---- 1 root disk 8, 5 2010-08-30 12:22 /dev/sda5

We can see one solution to grant permissions is adding username to the disk group, for example, by editing /etc/group file. And don't forget to re-login.

18 comments:

Commercial Electricians said...

Good post mate..Thanks for sharing mate

Commercial Electricians

HDD said...

Today, I managed to boot from physical drives. This required;

60 min straight forward reading
30 min writing this

20 min trying different options in VirtualBox

Pankaj Yadav said...

Awesome post! After Look at this I can’t stop myself to go for shopping just loving it. Airtel Free Internet Tricks Also check freecharge coupon code

shubham chugh said...

VirtualBox Vs VMware which is the best tool ?

manish dhanda said...

Romantic Songs
Sultan Ali Khan

Savita Bhabhi said...

who say seo is simplied thing
veteransdayimagesquotes

Rishabh Sharma said...

Idea Check Number

Whatsapp Group Names

Trickideas

Satta King 2017 results
Bigg Boss 11 online
Voting Process of Bigg Boss 11
Coinbase Promo code

Gopikrushna Sahoo said...

how to download Videos From voot

kajol sharma said...

The hopefuls of Bigg Boss 11 are yet to be concluded. The contenders are exclusively at the attentiveness of the group of Bigg Boss – who incorporate the generation and host group of the show. There are hypotheses that the host, Salman Khan is likewise a dynamic part to choose who might be chosen as hopefuls.
Bigg Boss 11 Live Promo
Watch Bigg Boss 11 Videos Online
Bigg Boss 11 Voting by Mobile SMS
Bigg Boss 11 Live Episodes

Ajit Agrawal said...

This is a great blog. keep sharing such nice post for us. Here are my sites for voot bigg boss 11 and Bigg Boss 11.

alan morris said...

This is a assortment of some wonderful Halloween coloring web pages selected predicated on their innovativeness and reliability. Select these as each is absolute to make an outstanding holiday art for your children. The fun and educative color sheets are well suited for small children, pre-schoolers, kindergarteners as well as teenagers.
Halloween Costume Ideas
Happy Halloween Wishes
Halloween pictures 2017
Halloween Costumes for women

rajeevguesskaro said...

Outstanding post, you have pointed out some good details , I too conceive this s a very fantastic website.
Bigg Boss 11 Prediction

kajal sharma said...

Veterans Day is not to be mistaken for Memorial Day. Veterans Day commends the administration of all U.S. military veterans, while Memorial Day is a day of recalling the men and ladies who kicked the bucket while serving.
Happy veterans day quotes
Happy Veterans Day Images
Veterans Day History
Happy Veterans Day Quotes
Happy Thanksgiving 2017 Wishes

Iam Blogger said...


Halloween Day
Halloween Pumpkin Carving Ideas
Halloween Costume Ideas
Halloween Couple Costume Ideas
Halloween Day Quotes
When Is Halloween 2017?
Halloween Costume Ideas For Girls
Halloween Costume Ideas For Boys
Halloween Costume Sale & Discount
Halloween Pumpkin Images

Iam Blogger said...

Halloween Party Ideas
Halloween Pumpkin Stencil Carving Pattern
Halloween House Decoration Ideas
How To make Creepy Halloween Spider Cupcake
Happy Halloween Message
Halloween Make Up Ideas
Halloween Day Poems
Halloween Day SMS
Halloween Wallpapers
Halloween Day Songs

Iam Blogger said...


Halloween Day Images
Halloween Day Sayings
Halloween Day Wishes
Halloween Day Pumpkin Pictures Download
Halloween Day Quotes Saying
Halloween Day Images HD
Halloween Day One Liners
Happy Halloween Wishes SMS
Happy Halloween Background Images
Happy Halloween Message

Iam Blogger said...

Happy New Year 2018 Images
Happy New Year 2018 Pictures
Happy New Year 2018 Wallpapers
Happy New Year 2018 Quotes
Happy New Year 2018 Wishes
Happy New Year 2018 Message
Happy New Year Images 2018
Happy New Year Greetings 2018
Happy New Year Wallpapers 2018

Iam Blogger said...


Also Read
Happy New Year 2018 Wishes
Happy New Year 2018 Quotes
Happy New Year 2018 SMS
Merry Christmas 2017 Images
Merry Christmas 2017 Greetings
Merry Christmas 2017 Wallpapers
Veterans Day
Veterans Day Quotes
When Is Veterans Day