|
In this tutorial we will assume the use of VirtualBox as the VM player (see: http://www.virtualbox.org/)
Enable Shared Folders. This allows both the virtual machine and the real computer to exchange files as both can read and writes files to any directories you specify as a shared folder.
In order for Shared Folders to work the 'Guest additions' software must be installed correctly. For more information, please see below. |
In the Settings window, select Shared Folders and click the blue folder icon with the green cross to create a new one.
In the window that appears, under Folder Path select the folder or directory on the host computer that will act as a shared folder (create it if it doesn't already exist). Then under Folder Name give it a name as it will appear on the virtual machine; shared_folder might be a good choice.
Make sure that Read-only is not selected and Auto-mount is selected.
With Auto-mount selected, the shared folder will be available when the virtual machine boots. It can normally be found in the directory /media/ with the prefix 'sf_' added to the shared folder name. If shared folders do not appear to work in the virtual machine, it may be that some additional software 'Guest Additions' is not installed. The version of Guest Additions installed must match the version of VirtualBox. If this is not the case, or in doubt, reinstall the Guest Additions software (see below). |
To have the monitor size in the virtual machine change size automatically as the virtual machine window is resized, select the 'Auto resize' option from the View menu when the virtual machine is active.
In order for this to work, some additional software might need to be installed on the virtual machine, known as Guest Additions. If this doesn't work, try installing (or reinstalling) the guest additions software.
The first time the virtual machine (VM) is started, the screen size may be set to 1024x768 pixels.
To change the screen size requires changing the desktop settings in the Linux virtual machine (similar to any Linux desktop)
Shared folders enable the host and guest machines to share files via a common folder (directory).
Please see instructions above for how to setup the shared folder for the virtual machine.
In order for this to work, some additional software might need to be installed (or reinstalled) on the virtual machine, known as Guest Additions. See below for more information.
It is important that the version of the Guest Additions installed on the virtual machine matches the version of the VirtualBox application. Problems have been found if they are not the same, shared folders & screen resizing may not work correctly, even if a version of Guest Additions is installed. In which case, re-install following the instructions below. Experience may vary, using more recent versions of Guest Additions may work. |
To install or re-install Guest Additions follow these instructions.
To check if guest additions is already installed run the following command in a Terminal:
lsmod | grep -i vbox |
if you see the following output (or similar), then the Guest Additions software is installed.
vboxsf 47936 0 vboxvideo 12669 1 vboxguest 293037 6 vboxsf drm 335594 3 vboxvideo |
Remove the Guest Additions packages by using the following command in a Terminal:
sudo zypper rm virtualbox-guest-x11 virtualbox-guest-tools |
Reboot then re-install following the instructions below.
These steps use the Mac OSX version of VirtualBox. Other systems may be slightly different.
First check that the necessary kernel files are installed:
zypper search kernel-devel |
If not, install them with the command:
sudo zypper install kernel-devel |
The installation needs to be done as the root user. This command will prompt for the root password 'metv1ew!
'
In the Terminal, change to the directory where the VBoxAdditions CD was mounted. This will be under the /run/media directory, followed by the username.
cd /run/media/openifs/VBOXADDITIONS_4.3.34_104062 |
To start the installation of the Guest Additions, type the following in the Terminal:
sudo ./VBoxLinuxAdditions.run |
This will prompt for the root password, usually 'metv1ew!'
The installation may report that Guest Additions is already installed and ask you to confirm. |
The installation only takes a few minutes.
Check that the user accounts have access to the shared folder. The shared folder is usually mounted in the /media
directory:
% ls -l /media drwxrwx--- 1 root vboxsf 170 Jun 2 2014 sf_shared_folder |
In the above example, the VirtualBox settings have used a shared folder name of 'shared_folder'.
For users to read/write to this directory, they must be in the 'vboxsf'
group. Look in the /etc/group
file to check:
% grep vboxsf /etc/group vboxsf:x:493:openifs,metview |
If the usernames are missing, add them using these commands:
sudo usermod -a -G vboxsf openifs sudo usermod -a -G vboxsf metview |
The user will need to log out then back in again for this change to take effect.
Please note that the user 'openifs' does not exist on the earlier OpenIFS Virtual Machines. |