Mount a shared drive with VirtualBox
Case
You have to share some content between the host (eg: Linux Mint) and the resident (eg: Windows 7) systems, with Virtual Box.
Solution
- In the resident system, go to Virtual Box, then:
Machine
>Settings
> SharedFolders
> on the right:Add
> checkautomount
andpermanent
, browse to the folder, let’s sayD:\sharedFolder
- Launch the VM.
- Execute a terminal in host system:
- Grant rights of group
vboxsf
to usermint
:
sudo gpasswd -a mint vboxsf
- Create a “local” folder:
mkdir ~/sharedFolder
- Mount the folder
sharedFolder
on/home/
:
sudo mount -t vboxsf -o uid=1000,gid=1000 sharedFolder ~/sharedFolder