lots of tech info here

How to Dual Boot with Linux and Windows XP

NOTE: _This article was written in 2004 and a lot of things may be outdated here._

You can set your computer to dual boot either with the Windows NT bootloader, Grub, LILO or any other bootloader.

My Windows partition is at /dev/hda1 and Linux partition is at /dev/hda2. The boot is at /dev/hda4.

Grub as the bootloader

I use Gentoo, so I'm listing the steps to install and configure Grub for Gentoo users.

First, emerge Grub with

emerge grub

Edit /boot/grub/grub.conf:

title           Gentoo
root            (hd0,1)
kernel          /kernel-2.6.15-gentoo-r4 root=/dev/hda4 vga=791

title           Microsoft Windows XP
rootnoverify    (hd0,0)
chainloader     +1

NOTE: In my laptop, /dev/hda1 is (hd0,0) /dev/hda2 is (hd0,1)

LILO as the bootloader

If you want to let LILO be the bootloader, just click on 'yes' during the installation; thats what I did.

I selected graphical LILO as the bootloader for my computer at home and GRUB at work in the Plant Pathology dept where I worked (until 2002).

Windows NT bootloader as the default bootloader

However, if you want Windows NT bootloader as your default bootloader, follow the steps below.

Recovering a lost LILO

Boot into Linux using a Linux boot floppy and type


Removing LILO

If you have Win 95/98, type FDISK /mbr

If you have Windows 2000, boot from the Windows 2000 CD and type fixmbr

Or else, from Linux, type /sbin/lilo -u

Removing Grub (and installing LILO)

If you have Grub as your default bootloader and want to replace it with LILO, here is what you do.

To remove Grub, you have to create a /etc/lilo.conf that describes your setup.

Type lilo -v to replace Grub with LILO.

Removing Grub (and installing Windows bootloader)

If you have Grub as your default bootloader and want to replace it with the Windows bootloader, you have two options.

Execute the fixboot command in Windows. It may work.

Or else, reinstall Windows.

Updated on 01 Dec 2004 {Created on 02 Dec 2004}

If you liked this article, follow us on Facebook and Twitter (@aruljohn).

Share this with Others