Have you installed Ubuntu 11.04 as a virtual machine in VirtualBox but have had problems getting the Shared Folders feature to work? We were able to add a shared folder, but were unable to access it.

We found the secret to accessing shared folders in an Ubuntu 11.04 virtual machine in VirtualBox. VirtualBox adds a user group called “vboxsf” to the Ubuntu 11.04 virtual machine. Any user that needs to have access to shared folders defined for that virtual machine need to be a member of that group. This article shows you how to add a user to the vboxsf group.

Setting up shared folders in VirtualBox is fairly straightforward. Select Shared Folders from the Devices menu.

The Shared Folders screen on the Settings dialog box displays. Use the buttons on the right side to add folders from your host machine to the Folders List. Refer to the help in VirtualBox for more information about adding shared folders.

Once you have added your shared folders in VirtualBox, you must add users in the Ubuntu 11.04 virtual machine to the vboxsf group created by VirtualBox. To do this, select Administration | Users and Groups from the System menu in the Ubuntu virtual machine.

On the Users Settings dialog box, click Manage Groups.

The Groups settings dialog box displays. Scroll down in the list of groups and select the vboxsf group. Click Properties.

On the Properties box for the vboxsf group, select the check boxes in the Group Members box for the users you want to add to the vboxsf group and click OK.

To make this change, you must provide authentication. Enter your user account password in the Password edit box and click Authenticate.

You are returned to the Groups settings dialog box. Click Close and then also click Close on the Users Settings dialog box.

Now, you should be able to access your shared folders in the /media/sf_Ubuntu_11.04 folder.

NOTE: The name of the folder inside the media folder that contains the shared folders in VirtualBox always starts with “sf_” and continues with the name of your virtual machine.

Remember to add any new users you add to your Ubuntu 11.04 virtual machine to the vboxsf group if you want them to be able to access the shared folders.