VirtualBox shared folder permission settings and how to use them _virtualbox

Source: Internet
Author: User
Tags documentation virtualbox shared folder

VirtualBox shared folder permission settings and how to use them

Environment:
Host: Windows XP
Virtual machine: VirtualBox
Client (Guest): slackware/ubuntu/...

Read my last article. A friend who installs additions for VirtualBox should be aware that VirtualBox Guest additions needs to be installed before you can set up VirtualBox shared folders. If it is not installed, refer to my previous article.

A shared folder is a way for the host's wendows and client Linux to share files with each other. In the current architecture situation, you need to set up a directory on the host, Windows, to do the shared directory, I am the D disk SharedFolder directory as a shared directory with the path of D:/sharedfolder. Here's how to set up a shared folder specifically. Referring to VirtualBox's help documentation (in the section of Virtual Guest additions), I found the following steps to complete the shared folder settings.

1. Set up a directory on host Windows as a shared directory (you do not need to set shared properties under Windows, but it is also a common folder). (I set it up: D:/sharedfolder)

2. On the virtual machine VirtualBox, if the Linux operating system on the virtual machine is not started, specify D:/sharedfolder as the shared folder in the set-> data space, and specify the name that it maps to in Linux, by default, as with your directory name, I'm sharedfolder here. You can see it clearly when you open the dialog box. If the Linux operating system on the virtual machine is started, the same settings can be made in the device-> allocation data space.

3. Open a console on the virtual machine and execute the following command under root permissions:

#mkdir/mnt/share// Create a directory to mount the shared folder, of course you can create a directory anywhere.
Then run the command: mount-t vboxsf [-o OPTIONS] sharename mountpoint. Here sharename is the default name I mentioned above Sharedfolder,mountpoint refers to where you want to mount a Windows shared folder on Linux. Here's what I'm using:

#sudo mount-t vboxsf sharedfolder/mnt/share//ubuntu , you need to use the root permission before adding sudo.

If you want to automatically mount the shared folder when the system starts, you can add a record to the/etc/fstab as follows:

sudo pico/etc/fstab

Add a sentence:

Sharedfolder/mnt/share vboxsf Defaults 0 0

Save and exit, the folder will be mounted automatically when the system starts up to/mnt/share

This shared folder is actually mounted as if it were mounted on another device.

Note that the commands here are for Linux clients. The Windows client uses a different command. You can refer to the Help documentation for VirtualBox.

4. This allows the file to be placed under the D:/sharedfolder of the Windows host and can be seen in the/mnt/share of the Linux client.

Thank you for reading, I hope to help you, thank you for your support for this site!

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.