Wednesday, April 25, 2007

Adventures with XP and Ubuntu

About a month ago I got a new laptop at work. A nice one (or at least, nicer than my old one) -- a Lenovo ThinkPad T60p. The little bundle of computing power has a Core 2 Duo processor, 3GB of memory and a 100GB hard drive. Emboldened by the success stories of Sam Ruby and Jason McGee, I installed PartitionMagic 8.0, shrank the XP partition down to 65GB and carved out 35GB to install Ubuntu. As I said, this was about a month ago. I use Ubuntu on my custom-built desktop at home (which is another, even longer story), and knew that Feisty Fawn was due in mid-April so I decided to leave the partition empty.

Fast forward to April 19. Feisty Fawn goes public! Woohoo! Fire up BitTorrent, snag the ISO's (i386, BTW -- I got burned putting AMD64 binaries on my home machine) and start the install. On the whole, I'd say it went pretty cleanly. Had to click through a few quasi-nasty messages about using non-open video drivers for the ATI chips in the laptop, but that's far better than the old status quo. So I'm sitting there looking at my newly-installed Ubuntu 7.04 desktop and it occurs to me that I've done this all wrong...

I expect I could have mounted my NTFS partition as read-only under Ubuntu, but there are still several internal things at IBM that only run cleanly under Windows XP. Things like accessing printers, submitting expenses and building presentations. I'd spend a significant portion of my time rebooting back and forth between Ubuntu and XP. It occurred to me that I could get all the things I wanted from Ubuntu (rich command line tools, real filesystem, superior editors, etc.) by running it in a virtual machine -- I didn't need to let it own the entire machine! No problem, I figured, I'll just boot back to XP, use PartitionMagic to rejoin the partitions and host Ubuntu under VMware. That's when the fun began.

Apparently installing grub on the boot partition modifies the master boot record (MBR) in such a way that PartitionMagic can't recognize it anymore. PM steadfastly reported error 117 and refused to even start. That sucked. So I googled various combinations of "remove", "grub", "fix" and "MBR". The universal solution seemed to be to boot off the XP CD, go into recovery mode and do "fdisk /mbr". Except I don't have an XP CD -- we have a group of folks at work that install XP for us and we never see the CD's. That sucked even more.

I was desperate. So desperate that I made it all the way to the 3rd page of Google results before I ran across exactly what I was looking for on the Novell website. 15 minutes later, the partition was gone. An hour after that, Ubuntu was running under VMware and things have been peachy ever sine. Thank you Novell!