Windows XP and Linux Dual Boot setup

This will hopefully be a quick tutorial on how to set up a dual boot system between Windows XP and Linux, quickly. In this example I used Mandrake Linux vers 10 (official) however I believe it could work with most flavours just fine.

The key to the installation is that Windows XP needs to be installed as the first partition on the hard drive.

Primary Objective: Windows XP home edition using NTFS and Linux (Mandrake 10 official) peacefully co-existing on a single hard drive.

Secondary Objective: Avoiding having the boot loader installed on the master boot record.

Required software: Windows XP and a Linux distribution such as Mandrake or Redhat that has a competent disk partitioning tool included in the installation.

Additional software: Partition Magic 8 or another partition manipulation tool that will allow you to set the active partition to whatever you desire. �Parted� is a free command line partitioning tool that I believe will work to this end. The additional software will allow us to achieve the secondary objective. Warning …early versions of Partition Magic could mess up an NTFS installation just by starting the program, without making any changes!

Disclaimer: I am providing this information in hopes that it will save someone time, effort and frustration. This tutorial is written for users that are already familiar with installing operating systems and partitioning hard drives. I cannot guarantee that it will work for everyone and all situations. Be advised that the steps listed will erase all information from the drive and mistakes in the use of any software that manipulates the contents of a hard drive (though unlikely) can cause irreparable damage. I will not be held accountable for any problems you may incur.

Now, that said let’s get on with it, shall we?

Hardware: The computer I used in this situation is a Compaq Presario 2110 US laptop. For anyone who might have gotten to this page looking to check compatibility between the Presario 2110 and Mandrake Linux 10, I can tell you that all hardware, save the modem, seem to be compatible and working properly without any effort on my part. I do not have a dial up connection so I have not tried the built in modem.

The specs given by Compaq are rather generic. The CPU is AMD Athlon XP 2000+ mobile, ( 1.667Ghz), 512MBsdram, ATI Radeon Mobility stealing 32 Megabytes of the system RAM, 10/100 Ethernet card built in, modem built in, and a 60 gigabyte Toshiba hard drive. Not a bad little laptop for all around use.

The Procedure:

Wipe the hard drive clean of all info. You can do this with Fdisk, Partition Magic 8 or even by starting the Linux Installation and quiting after deleting the existing partitions.

Next, decide what sizes you want your partitions to be. If you have software that will allow you to change the active partition, then you will want to include a second primary partition of about 102 megabytes following the first partition that will hold Windows XP. The key to success will be to have the Windows XP partition be the first partition on the drive. Somehow I was able to get around this at one time, but have not been able to avoid it many times since.

I decided to create a 7GBNTFS primary partition for Windows XP. Followed by a 102MB EXT3 primary partition for my Linux /boot to avoid using the MBR to hold the boot loader. Next would be the regular ext3 logical partitions for root / 10GB, SWAP 1024MB, /home 39GB or so, then a 3GB FAT32 partition for sharing between Windows and Linux.

So first step, install Windows XP. The Windows XP install will ask you to create a partition for Windows XP, just create one from the empty space, set the size you desire and format it NTFS. Then proceed to install XP and make sure it boots and whatnot to your liking.

Step 2, now that Bill has had his way with you and your hard drive, go take a shower to wash the stench of Windows off of you or until �The Crying Game� flashbacks have subsided.

Step 3, It’s penguin time! Begin installing Linux and create the partitions as you would like. Remember to omit the /boot primary partition if you are content to trust the MBR or do not have access to a program to change the active partition.

Step 4, Format the new partitions and install the Linux distro and your selected stuff but at the end of the install it will ask you about the boot loader configuration…

Step 5, Select your boot loader. I used Grub as my boot loader and suggest you do also. I like LILO better, however I have had some really weird things happen with LILO like not always booting and it seemed to occur on newer hardware. But you can use LILO if you wish.

Step 6, Double check to make sure that the boot loader has the options set so that you can boot from the various Linux kernels or Windows.

Step 7, Install the boot loader… If you decided to install the boot loader to the MBR, then basically you don’t have to do anything. Most distro’s will do that by default. �Install boot loader to /dev/hda.� If you choose this you can finish up whatever steps necessary to complete the install and when you reboot you should have the selections to boot Linux or Windows. You are done.

If on the other hand you decided not to trust the master boot record, then you need to do things a tad differently. You will want to tell Linux to install the boot loader to /dev/hda3 or wherever you set your /boot partition. Now remember, you must only choose this option if you have a program at your disposal to make that partition active. Now finish up any leftover installation options and ….

Step 8, Reboot. Now when you do this, if all went right, you will not have any options to select at boot and Windows should start up. This is because the MBR still points to hda1 which is WinXP. So shutdown and reboot with whatever program you choose to use, IE Partition Magic 8, and set the active partition to hda3 ( the /boot partition.). Then reboot again and if all went well, then you should see the Grub boot loader and can now select which version of Linux or Windows you set up. I suggest you reboot and try each selection to endure everything is up to par.

Step 9, Bask in the glory of the Penguin and enjoy tailoring the system to your liking!

This entry was posted in Linux. Bookmark the permalink.

Comments are closed.