Switching distros

Q I am running Ubuntu 8.10 and Windows XP on a single 80GB hard disk (50GB for Linux, the rest for Windows). I want to remove Ubuntu and install another distro (I've not decided which yet). The problem is that if I use Windows Hardware Management to wipe the Linux partitions it removes Grub and I can't load XP. If I don't do that, I'm ending up with the old swap partition floating about unused, as I don't have the skills with partitioning to deal with it. Is there a really easy method that won't waste the Swap space that I can use?

A There are a couple of ways around this. One is to boot from your Windows rescue CD (or partition) and run fixmbr from the rescue console. This restores the bootloader to the default Windows setup, making Grub unnecessary. Alternatively, you can simply run your new distribution's installer without changing anything. When you get to the partitioning section of the installation, tell it to use your existing root and swap partitions, and your existing /home partition if you have one. Let it reformat the root partition but not /home. It will then reinstall Grub, set up to dual boot your new distro and Windows.

Most distro's installers are quite sophisticated in their approach to partitioning, so provided you check what it's going to do before you commit anything to disk, this is generally the best way to approach partitioning problems. Most installers use parted to perform the partitioning (the same program used by most Linux graphical partitioning tools), so there's really no advantage in trying to second guess the system, especially if you're perfectly happy with your existing partition layout.

Back to the list