How to change the screen resolution in Ubuntu running in VirtualBox
I just took the dive into setting up a virtual machine on my home PC, and decided to install Ubuntu on it. I’ve had several dedicated Linux/*nix boxes at home in the past, and have several at work, so I finally decided to add a flavor of *nix back to my home OS lineup.
All went well (installing VirtualBox was simple and only took a few no-brainer mouse clicks), and installing Ubuntu in a virtual maching within VirtualBox was just as easy. I did run into a little problem that took me a few searches on Google to find, so I’m repeating the instructions here so that I don’t have to go looking for this solution in the future.
The problem was that the virtual machine running Ubuntu would only use 800×600 resolution. I could not get it do use any other resolutions. I tried accessing the vBoxGuestAdditions, but this did hot help. I found the following instructions at http://www.sysprobs.com.
With Ubuntu running in a VirtualBox virtual machine, open up a a terminal window (Application -> Accessories -> Terminal) and type the following at the prompt:
sudo apt-get update
This checks (over the internet) for updates that may be available for the Ubuntu installation.
The following two commands will download and install the latest essential updates for the installation, and then will download and install the latest guest display utilities for X11.
sudo apt-get install build-essential linux-headers-$(uname -r)
sudo apt-get install virtualbox-ose-guest-x11
Restart the virtual machine and try resizing it’s window once it has restarted. The resolution should change as the screen size changes from maximized, windowed, etc. At least it did for me!