Virtual Machines are similar to isolated containers. Guest operating systems on virtual machines cannot access your Share computer files.
So you need to create a Share Folder in software like VirtualBox or VMware so you can easily share files between the guest and host operating systems.
In order for the guest operating system (or virtual machine operating system) to do this, the virtual machine must assume a shared folder similar to the network share folder and build it there.
After that, the guest operating system can look like folders Internet sharing also has access to the folder created on the PC.
VirtualBox Virtual Machine
As mentioned in the introduction, you must create a shared folder between the two operating systems to access files. The Shared Folder feature works on VirtualBox virtual machines and on both Windows and Linux guest operating systems alike.
To use it, you need to install a Guest Additions on your virtual machine guest operating system. Click on the Devices tab and then click Insert Guest Additions CD image while the virtual machine is running and start installing it on the virtual machine.
click on the Machine upper tab, go to Virtual Machine Settings and select Shared Folders. Here you can see any shared folders you’ve already created.
But if you haven’t done so already: In this section you will find two types of shared folders, the first of which is Permanent Folders, which will share files until they are deleted as a shared folder.
The second type are temporary folders (Transient Folders) that are deleted as soon as the virtual machine is restarted or turned off.
Here you can click on the Add or Add button to add a new shared folder or right-click on an existing list and select Add Shared Folder .
The path to the created folder is the one where you are given the address and with the name you selected will be placed on the host operating system (the main operating system you have installed on your system).
By default the virtual machine provides full read / write capability for the shared folder.
But if you want to restrict the freedom of the virtual machine and the operating system on it can only read the host operating system files through the shared folder or not allow file transfer or file creation, read-only.
Also, if you check the Auto-mount option, the guest operating system on the virtual machine automatically activates the folder sharing feature each time you boot.
The Make Permanent option also prompts the shared folder to become the default virtual machine folder (always present).
If you are running a Windows operating system on a virtual machine (as a guest operating system), you should see a shared folder as a network share file.
Open the Windows browser (in Windows 8: This PC) and select the Network section as shown below and look for VBOXSRV.
You can also mount this folder with a few commands.
Do this using the following command in Windows and paste NAME with your subscription folder name:
net use x: \\ vboxsvr \ NAME
Use the following command on Linux and use the folder name instead of NAME. The / mnt / folder path is also the directory of the shared folder.
It should be noted that you must have created the folder before using this command.
mount -t vboxsf NAME / mnt / folder
VMware Virtual Machine
Shared Folders feature on Vmware virtual machine can also be created on both Windows and Linux operating systems. But first you need to have VMware Tools installed on your virtual machine before you can use this feature.
In the Virtual Machine menu you should find the option to install or update the VMware Tool (if your version is not the latest version you should update it).
Then go to the Virtual Machine Settings window:
For example, in the Vmware Virtual Machine you will need to select the Player tab from the top, go to the Manage section, and then click Virtual Machine Settings.
You can access this feature (shared folder) by clicking on the Options tab and selecting Shared Folders.
Add the folder you want to share from.
All of these folders will be displayed in the virtual machine with the name you selected. By default, Vmware VMware gives you full access to read / write files.
But with the Read-only option like the previous virtual machine
you can deprive the machine of the ability to write inside the folder.
A shared folder similar to the Internet network sharing folder will appear on the guest operating system Windows. It can be found under the name vmware-host.
You can increase the speed of transfer and use of the sharing folder by ticking “Map as a network drive in Windows guests”.
And instead of looking for shared files on the network,
the file sharing folder using this feature has a special drive and is displayed in your computer’s drive window.
If you are using a guest Linux operating system,
then you should find the Vmware subscription directory in the / mnt / hgfs / root directory.
Keep this in mind;
if you use multiple virtual machines then you must share a folder for each. You also need to be very careful when using shared folders,
because if your virtual machine is at risk of a virus,
the virus can get out of the virtual machine and infect the contents of the shared folder.