Jeff Duntemann's Contrapositive Diary Rotating Header Image

January 11th, 2008:

Booting Kubuntu from a Removable Drive

Pete and I discovered something interesting recently, almost by accident. Ok, it was almost entirely by accident. But it's useful nonetheless: We figured out how to install and boot Kubuntu on a removable hard drive after Kubuntu's installer failed to see the removable drive.

I've written about Dell's SX260/270 small form factor desktop here a number of times. It's a tiny little micro-tower made from laptop parts, especially Dell's Inspiron line. Its single most useful feature is its “media bay,” a front-panel slot that accepts several different kind of removable drives, including floppies, Zip 100s and 250s, CD and DVD drives of all stripes, and hard drives in appropriate cartridges. These cartridges are available empty, and Pete and I each bought such a cartridge plus an 80 GB notebook drive to install in it. The idea was to install Kubuntu on the cartridge drive, and then figure out how to dual-boot between Windows on the main hard drive and Kubuntu in the cartridge drive.

Except that I couldn't get Kubuntu's installer to see the cartridge drive, and thus couldn't do the install. Oh, well. We were interested enough in configuring Kubuntu and experimenting with some OSS titles accessible by KDE package manager Adept to pull the main Windows hard drive out of my SX270 lab machine and drop the new, empty hard drive into the main internal drive slot in its place. From there it was a typical and easy Kubuntu install, and we spent an afternoon trying things out. (Adept is a marvelous thing!) The next day I wanted to use my scanner downstairs, but the scanner software was installed under Windows, and HP infamously does not provide Linux drivers for its products. So I pulled the Kubuntu drive out of the SX270 and put the Windows drive back in. On a whim I installed the Kubuntu drive in my empty media bay cartridge and plugged the cartridge in to the machine's media bay to see what the boot process would do. I restarted the SX270, and wham! Kubuntu booted.

It's obvious in hindsight: The BIOS lists the CD drive ahead of the internal hard drive in boot order, and the CD drive lives in the media bay. In fact, anything with a master boot record plugged into the media bay will boot (or try to boot) before the internal hard drive.

There is a downside to using Kubuntu from the SX260/270 media bay: There's only one media bay, so with the Kubuntu hard drive cartridge plugged in, there's nowhere to put my media bay optical drives. (I could buy a USB optical drive, but that's yet another piece of hardware to keep track of.) The real solution is to figure out how to make grub dual-boot Windows and Kubuntu from separate partitions on the 120 GB internal hard drive. Remarkably, O'Reilly does not have a book on grub, even though they have whole books on numerous deep-geek software packages with user bases (barely) in double digits. (There are millions of grub installs. Maybe tens of millions.) So I've been reading the scraps posted here and there online and will figure it out eventually.

I guess I should have known that anything in the media bay would boot before the main hard drive. I freely admit that I didn't. Sometimes, well, you just get lucky.