Using shared folders in VirtualBox

The shared folder concept in VirtualBox is extremely useful for sharing files between the host and guest OS. To be able to use shared folders you need to install VirtualBox guest additions to the guest OS. This is usually achieved by using the “Install Guest Additions…” option from the Devices menu. The next step is to create a shared folder by using the “Shared Folder…” option from the Devices menu.

To access the shared folder from Linux, mount it as follows

mount -t vboxsf share_name mount_point

share_name is the name you gave to the shared folder, use all upper case (even if the name you set is in smaller case). mount_point is the folder on the guest OS where the shared folder will be mounted, usually a folder under /mnt.

If you set the Auto-Mount option while creating the shared folder, you don’t need to manually mount the shared folder. You’ll need to add your login to the vboxsf group though, to be able to access it

sudo adduser login vboxsf

Remember to log out and in again, or reboot, after doing that.


2 thoughts on “Using shared folders in VirtualBox

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s