I am trying out Sun’s Virtual Box this term. I’m going to be doing a fair amount of development in C and C++ which means using gcc on Ubuntu. I’m pretty invested in the software on my Windows 7 laptop and yes, I’ve got Cygwin, but I prefer working with C and C++ on Ubuntu. I tried dual booting Vista and Ubuntu before upgrading from Vista to Windows 7, and I generally didn’t like the whole dual-boot experience.
Enter Sun’s Virtual Box. I worked with virtual servers using VMWare while studying databases at BCIT last year, but I found VMWare was a real memory pig and I wanted to try something that was a) open source, b) free and c) free.
Setting up Ubuntu 9.10 as a guest on my Windows 7 host was almost too easy. The only problem? The Virtual Box User Manual doesn’t include a clear step-by-step recipe for installing Guest Additions, which is the Virtual Box “partner” we have to install on the virtual machine. It integrates the virtual machine with the host machine so you don’t have to do weird screen resize things or mouse captures or anything that offends the intuition. Here’s what I did:
- download and install Virtual Box
- download the iso for Ubuntu 9.10 and use your favourite iso mounting software to mount it in your host (I used VirtualCloneDrive)
- start Virtual Box and create a new Virtual Machine
- install Ubuntu in the Virtual Machine (Virtual Box’s wizard asks some set-up questions and you just point it to the iso and wait–go make a sandwich or something)
- once Ubuntu’s up and running, choose Devices/Install Guest Additions from the menu bar in the virtual machine’s window
- ignore the weird warning message Ubuntu spits out (check the app bar to find it if it’s not maximized)
- double-click the GUESTADDITION disc which appears on the Ubuntu desktop
- run the autorun.sh script
- reboot the Ubuntu machine. Done.
It’s seriously that simple. It’s completely moron-proof. I did this without any trouble at all. The Virtual Box wizards take over when you create a new virtual machine, and then when you open it the first time it cues you for the iso of the operating system (in my case Ubuntu 9.10) to install.
I have 2 partitions on my hard drive, a big Windows 7 partition and a smaller 25 GB docs folder which is mounted to my Windows as drive D called shared. I wanted to give the Ubuntu virtual machine read/write access to my D drive, and I did this in two steps:
- close the virtual machine and edit its Shared Folders (at the bottom of the virtual machine’s Details tab) to include shared
- reboot the virtual machine and use this command in a terminal window:
sudo mount -t vboxsf shared /home/christopher/shared
Again, crazy easy.
Talking about crazy easy, I made us new pajama bottoms during the Christmas break and started planning my next big art project. I’ll post some pictures about it on orangewool once more work is done.