Linux

VirtualBox – Increasing Your Screen Resolution

January 30, 2009

Since I’m currently taking Windows 7 for a test drive I had to set up a copy VirtualBox with Ubuntu 8.10 in order to make use of the terminal (I can’t stand PuTTY or any other Windows alternative).  In the past I had always used VMWare so this was my first venture into the land of VirtualBox.   Overall I found it much easier to install and make use of, but I was stumped when it came to making the window bigger than 800×600.  Within the Ubuntu session it only let me choose 640×480 or 800×600, which didn’t work for me. So I did some research and eventually came up with a solution.


Use your host key (ie: Right Ctrl) to escape out of the confines of the Ubuntu desktop, and click the Devices drop down, and then Install Guest Addons.  This will mount a virtual CD within your Ubuntu session. I actually got an error at this step but I just hit Ok and it didn’t effect me. Now you should see a CD icon on your desktop.

 

Open up your Terminal and type:

cd /media/cdrom0

In this folder there are some scripts for 64 bit linux and 32 bit.  For some reason the 64bit ones failed to work for me, so I had to use the 32 bit ones within 64 bit linux.  I would suggest doing the same.

sudo sh ./VBoxLinuxAdditions-x86.run

This will configure your Ubuntu session so that it can allow you to use higher resolutions. First you must reboot your Ubuntu session or restart the display manager by hitting Ctrl+Alt+Backspace.  Next go to:

System
Preferences
Screen Resolution

Set your resolution and hit apply.

Only registered users can comment.

  1. Hey, I found your article on dzone.com. I’m also a user of VirtualBox. I found it to be a lot more lightweight than VMWare and it is particularly useful to install it on home desktop because it is appears to me to be less system intensive and easier to use.

    Regarding with screen resolution, I am assuming Windows 7 is your host OS and Linux is your guest OS. After you installed the “Guest Addition”, the screen resolution will automatic adjust when you simply adjust the Guest OS windows on your desktop. It is not necessary to set your screen resolution manually in the Linux OS.

    In addition, another useful trick is ‘Ctrl-F’ if you want it to be full screen.

    Good luck and have fun!

  2. Perhaps you’re running a different version than I am but I do not get that same result on my work or home computers. When I resize the Guest OS window it does not adjust the resolution of the Guest OS. So if it was set to 800×600 I would end up with a gray frame around it filling the rest of the window. If I set it’s resolution to match my Host OS and then shrink the window I end up with scrollbars in order to access the areas outside of what is showing.

    And yes, Ctrl+F is quite useful. If I have a monitor free that’s what I end up using.

  3. If you want to change the screen size, after you install the Virtual machine, change it in the display properties of the operating system. It will automatically change your virtual box size too. I think this is what you are talking about FettesPS.

  4. Great thanks for this tip, it worked like ice cream! I think they have made it pretty simple with VirtualBox 4.1.8 and Ubuntu 11.10. No more hacks needed – just install the VirtualBox Guest Additions and you are done.

    TIP: After rebooting Ubuntu, instead of maximizing the VirtualBox window, resize it by pulling the sides to bigger and bigger size, up to your full screen size. Then on maximizing the window, Ubuntu filled up the whole window. Now I have Ubuntu running at 1600×1080.

    I did not need to run the additions from the command prompt. In the Devices menu, the last option is VirtualBox Guest Additions. Select that and it installs directly.

    I had checked out some of the other hacks earlier but all were pretty complex and involved changes to xorg.conf. In Ubuntu 11.7, there is no xorg.conf.

  5. Just FYI for anyone who stumbles across this and gets confused, if you don’t see “Devices”, It’s because you’re in scale mode. To get out of it, hold your host key (default right ctrl) and hit ‘c’. You should see devices appear on the menu bar of the Guest OS window

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.