I've been using VirtualBox to have easy access to linux on my Windows 7 machine for a while, however, one thing that has always kept me from using it more consistently is the fact that my VMs usually come with a small native resolution making it difficult to work on my VM primarily. Well I decided recently I should change that, so that perhaps I will start using my VM more for a lot of my day to day needs.
It turns out changing this resolution is a bit more laborous that I would have thought. I started by giving my VM more video memory and more power in general, as well as updating drivers and that wasn't the problem. This is a VirtualBox setting that I need to change. In order to make those changes, follow the instructions below:
First click on the VirtualBox menu option "Devices" and look for "Install Guest Additions" (figure1). From there you will get a pop up asking if you trust this source and then you will be asked about downloading a CD image from the web, just proceed and wait for it to download and install whatever it needs to install. Once this is complete, the next step will vary slightly from distro to distro, but you basically want to mount whatever it downloaded. On Ubuntu 13.10, you should see an iso image appear on the bottom of your unity menu bar, click on that.
When you open the image you should see several options of files which you will have to chose the one appropriate to your need. Since my host is a Windows 7 64-bit, I will copy the file of the appropriate exe file to your desktop.
From here open you distro's terminal and go to desktop. For me it was just a matter of typing cd Desktop/
From here type
$ chmod +x xfilenamex
xfilenamex is the name of the file that you copied of course which in my case was
$ chmod +xVBoxWindowsAdditions-amd64.exe
This will give you priviledge to run this particular file. Next execute the file via
$ sudo ./VBoxWindowsAdditions-amd64.exe
again change the filename to whatever file pertains to your OS.This will ask you for your root credentials and install the guest additions. Now you can close your terminal and shutdown your VM
$ sudo shutdown -h now
From there go to your Windows 7 and open the windows terminal. If you don't know how, just type "cmd" on after pressing the windows button. From there look for the folder where your VM is installed on Windows. in my case it was under Program Files, but not the x86 one for some reason. There you should see Oracle\VirtualBox.
From there type
VBoxManage setextradata "xOSnamex" "CustomVideoMode1" "xresolutionx"
in my case
VBoxManage setextradata "u1310" "CustomVideoMode1" "1680x1050x32"
This didn't actually seem to do the trick, so I went ahead and also ran the following command:
VBoxManage setextradata global GUI/MaxGuestResolution 1680,1050
Now load your VM up as you normally would and this did the trick for me. I'm not sure if you need the first VBoxManage command so if you want to try just using the global command go ahead and try it out. If it works post a comment to let me know. Again I'm using a Windows 7 host OS, trying to run a Ubuntu 13.10 VM on it.
sudo apt-get install virtualbox-guest-dkms
ReplyDeletesudo apt-get install virtualbox-guest-x11
in case it doesn't work by manually running the additions. I needed to do this to my last install (ubuntu mate 15.10)