Installing Ubuntu 10.4 LTS on Windows Virtual PC on Windows 7
There's lots of info spread around on how to install various older versions of Ubuntu under various older versions of Virtual PC, but I didn't find any referring to the newish Ubuntu 10.4 and VPC on Win 7.
I did now find some useful command-line parameters in this blog post from Mark Wilson. I'm trying to make this post as complete as possible. If you have new or update or better info that is specific to the new changes in Ubuntu 10.4, let me know.
Here's what I did.
- Download Ubuntu.
- Download Windows Virtual PC.
- (You don't need to get Windows XP Mode, but if you want, it's nice.)
- (When you have VPC, you can also some of the various free IE browser testing VMs as well)
- Go into the Virtual Machines folder, and click Create Virtual Machine. Give you VM at least a gig of RAM. I have 8 gigs on my machine, so I give it probably more than was needed and allocated 3gigs.
When you create a Hard Drive, create a Fixed one rather than a dynamic one. I find this is faster and can avoid some strange disk errors with Ubuntu and the VM. I saw some strangeness with dynamically expanding disks.
In the Settings for your VM, tell it that the DVD drive actually be the Ubuntu ISO that you downloaded.
Hit OK and start your VM.
IMPORTANT: When it starts booting, hit ESC when you see a blinking cursor, then you'll find yourself here. If you let it just boot without hitting ESC it'll start a bit, then give up.
Hit F6, then ESC. Then add vga=791 noreplace-paravirt at the end of the white command line so it looks like:
You find yourself at a desktop...make sure that from Tools|Settings that your Network Card in the VM is attached to a REAL physical network card.
If you click in your VM, the mouse will be captured. You can get out with Ctrl+Alt+Left Arrow.
Double-Click Install Ubuntu and start the process using all the defaults.
Blah blah blah...
Wait a while...and IMPORTANT do not restart when it's done or you are screwed.
Instead, you need to make a few changes to make your new system bootable. Click "Continue Testing."
Now, go to the Places Menu in the top menu and click your File System. That will open up a disk browsing window with a GUID (yes, a GUID) in the title bar. You're going to need to type that, so get emotionally ready. You'll also want to rearrange the windows so you can open up a Terminal Window (from Applications, Accessories) and have the two near each other.
Now, open your Terminal. From Marks's blog, type:
sudo mount -o bind /dev /media/THATGUID/dev
sudo chroot /media/THATGUID/ /bin/bash
mount -t proc none /proc
That last line will bring up a text editor.
From the text editor, change "quiet splash" to VGA=788 or one of the VGA codes from this table. Mark also recommends commenting outu GRUD_HIDDEN_TIMEOUT with a #. Oddly, while the codes for resolutions seem to work initially, X switches back to 800x600 when it starts.
Save with Ctrl-X, then run nano /etc/grub.d/10_linux from the terminal to edit one more file. Add noreplace-paravirt (remember that) after args="$4" like this:
Finally, run "update-grub" from the command line. NOW you can restart using the on-off button dealie on in the upper-right corner. I had to hit enter a few times in text mode to get it to finally restart. Ignore the error about Casper and just press enter.
At this point with Ubuntu 10.4 on Virtual PC:
- No sound - faking it with modprobe snd-sb16 doesn't work
- No mouse wheel - hacks found around don't appear to work
- Difficult to change resolution.
Of course, using the Virtual Box virtualization tool works great with Ubuntu right out of the box and includes Virtual Additions that are custom to Linux and allow resizing, but I was (am) hoping to get this VPC thing working completely so I can stick with my one standard virtualization solution.
If you've solved any of these, specific to Ubuntu 10.4, then please let me know and I'll update this post.