- Sun ™VirtualBox™ (available at http://www.virtualbox.org)
- Microsoft® Windows® XP/Vista
- Ubuntu 8.10 (used in this tutorial, previous versions compatible) installed in VirtualBox
Virtualization offers you a great opportunity to set a virtual environment to test different operating systems without the hazard of damaging the main (or host) operating system. However, sometimes the installed system acts different in the virtualized environment. For example, the installed Ubuntu in VirtualBox by default sets the 800x600 screen resolution.
Even if the user activates the full screen mode, the resolution still remains the same. Unfortunately, if you open the Screen Resolution dialog (System > Preferences > Screen Resolution) from the Ubuntu menu, you won’t see any suitable high resolution picks.
However, there is a solution for this problem. First of all, before starting the virtual Ubuntu environment, check if there are no images mounted in the virtual CD/DVD drive for the current virtual machine.
Now start the Ubuntu virtual machine. When the Ubuntu OS is completely loaded, make sure the mouse is not being captured by the guest environment (if it is, press the right Ctrl button to release capture). Navigate through the Devices menu to reach the Install Guest Additions option.
After you click on this option, a virtual image will be automatically mounted in the current guest system (Ubuntu in this case) and the user will most likely see a Autorun option.
Click on Cancel, as the mounted image does not contain Autorun files. Now, go to the Terminal (Applications > Accessories > Terminal). When the terminal window opens, type the command:
Now, depending on your system, type in the terminal (for 32bit systems):
sudo bash ./VBoxLinuxAdditions-x86.run
For 64bit systems, type:
sudo bash ./VBoxLinuxAdditions-amd64.run
You may be asked for your account password. Type it if asked for and press Enter. The installation process shall now begin. After the installation is complete, you should see something similar to this:
Restart your virtual environment. Still, after this process we will not see any additions to the screen resolutions list. We have to do one more thing – edit the xorg.conf file.
NOTE: I am using Ubuntu 8.10 for this tutorial. This system implements an automatic backup feature for the xorg.conf file, so if the file is corrupt, the system will ask the user if he wants to restore the older xorg.conf file. In the previous versions of Ubuntu the auto-backup feature is not present and your system may be irreversibly damaged if the file becomes corrupt. PLEASE, MAKE SURE YOU BACKUP YOUR XORG.CONF FILE BEFORE PERFORMING ANY CHANGES TO IT.
Open the terminal window (Applications > Accessories > Terminal) and type:
sudo gedit /etc/X11/xorg.conf
Remember, that UNIX-like systems are case-sensitive when it comes to entering file path, so X11 is not the same as x11. Make sure you follow the indicated letter case.
After pressing Enter, the gedit window should appear.
Now, we should add some additional configuration information to this file:
The text highlighted with a red frame is the representing the settings you should add to the xorg.conf file. In the Modes section, you can set the resolutions you want to add. I added a 1600x800 resolution (for a wide screen). If you don’t use a wide screen, you can set the standard 1024x768 resolution.
Save the file and restart the virtual environment. Now your virtual Ubuntu environment can work on a high resolution, so you can work in the full screen mode.
- Dennis (Core)
You can download this tutorial in PDF format.
The file is presented as an attachement to this tutorial.
Number of downloads: 4103