Sunday, March 15, 2009

How to Dual Boot Linux with Windows XP

*** Disclaimer ***
If something goes wrong, it's a real possibility that your stuff could be lost. DO NOT follow this guide unless you have some sort of Install CD handy. There's nothing worse than having your bootloader messed up and not having a CD to restore it with. Also, I highly suggest that you read this guide before you start, and then print it out so that you will have it with you as you go through the installation itself.

This guide will cover how to shrink your currently installed Windows XP partition and install Ubuntu. The end result will allow you to select either Linux Ubuntu or Windows when you turn on your computer. If you choose Windows, it will load Windows, just like the way it is for you now. If you choose Linux, it will load Ubuntu. Very simple and easy.



This will not delete any of your currently existing files and you will be able to access Windows. You will have a fully working Windows XP along with a fully working Linux Ubuntu.

Now, let the games begin.

FIRST unplug any external hard drives, USB drives, iPods, MP3 players, or any storage media of any kind:

If you have less than 512MB RAM, do not follow this guide. You can determine your amount of RAM by click Start > Run and then typing "dxdiag" and then clicking ok. And then click "No". It doesn't matter if anything is digitally signed. Your amount of RAM should be present in that menu. I would also not recommend following this guide if you have an HD that's smaller than 40gb.

1.Download and install WinRAR and PowerISO

2.Install both of the programs.

3.Download Ubuntu from http://www.ubuntu.com/getubuntu/download

4.When the download finishes, make sure you have a blank CD in the drive.

5.Open PowerISO, click burn on the toolbar and then in the image file section, click the 3 dots and select the Ubuntu iso, then select the lowest burning speed in the drop-down, and then click burn.

6.When it finishes, make sure the new CD is in the drive and the drive is closed.

7.A menu should pop up. If it doesn't eject the CD and reinsert it. If that doesn't work, just reboot and skip to Step 9.



8.Select "Demo and Full Installation." It should now take you to a new menu. Check the option "Reboot Now" and hit Finish.



9.An Ubuntu menu should appear on reboot. If not, you may need to enter your BIOS so that your computer will boot from the Ubuntu CD. If you do not know how to do this, follow this guide. It is very easy. Once you get to the Ubuntu CD's Menu, a list of languages should pop up. Select English and hit enter.



10.Next, select "Try Ubuntu without any change to your computer" and hit enter. Ubuntu should now load.



11.Assuming that everything went as planned, you should now be greeted with a nice, simple, pretty Ubuntu desktop. If not, then post what went wrong in my thread. But nothing should go wrong. This is what Ubuntu will be like once you install it; except that this version is MUCH slower because it is running off of a CD. Feel free to play around before you continue on in this guide.



12.Double-Click Install on the desktop when you are done looking at Linux. A new window should popup (It might take a moment to load).

13.Select your language in the menu to the left and click Forward.



14.Simply click Forward afterwards, Ubuntu should automatically set a good city for it's timezone. If not, select your own and then click Forward.



15.In the next Window, simply click Forward again unless you know what you're doing.



16.A loading menu should popup. Just wait. In the next window, make sure the first option is selected and use the slider to select the % on your hard drive that should be devoted to Linux. Personally, I give XP 40% and Ubuntu the other 60%. Click Forward when you are done. Click Continue and then Forward again.



17.Ubuntu will now partition your disk for the dualboot. Just kick back for a second and let it finish.

18.When it finishes, you will come to this screen. This is easy, just fill in the information. Click Forward. (Name, Log-in name, Password, and PC name)

19.Ubuntu will now say that it is ready to install to the hard disk. Click Install.



20.Click back and relax once again. Depending on your PC, this will either take five minutes or a while. You may want to get a snack or a cup of tea or something. Congratulations, you've gotten past most of it.



21.When installation finishes, click Restart Now. Before Ubuntu completely shuts off, it should prompt you to remove the CD. Remove the CD and hit enter. When it reboots, do not touch anything. Just let it load. Ubuntu should start running.


22.IF you get a prompt asking you to choose an operating system to load, just select the first option and hit enter. If not, just continue to step

23. Ubuntu will load for the first time. YAY! :D


24.You should get to a login screen. Login using the username and password you inserted into the install program earlier.

25.When you are on your desktop, click "Applications > Accessories > Terminal"



26.Type "sudo gedit /boot/grub/menu.lst". That's with an l, as in a non-capital L. NOT a 1. Hit enter. A text editor should pop up in a moment.

27.Scroll down to the section between "## ## End Default Options ##" and "### END DEBIAN AUTOMAGIC KERNELS LIST". Btw, don't do **** unless I tell you. Don't delete ANYTHING or edit ANYTHING unless you know what you're doing. **** this up, and you risk making it so that you cannot boot into either Ubuntu or XP. But if I tell you that you can edit it, feel free. It should look something like this (Numbers will be different):


title Ubuntu, kernel 2.6.20-15-generic
root (hd0,1)
kernel /boot/vmlinuz-2.6.20-15-generic root=UUID=fe7bf845-7ce9-4733-b6de-f70f2b62076d ro quiet splash
initrd /boot/initrd.img-2.6.20-15-generic
quiet
savedefault

title Ubuntu, kernel 2.6.20-15-generic (recovery mode)
root (hd0,1)
kernel /boot/vmlinuz-2.6.20-15-generic root=UUID=fe7bf845-7ce9-4733-b6de-f70f2b62076d ro single
initrd /boot/initrd.img-2.6.20-15-generic

title Ubuntu, memtest86+
root (hd0,1)
kernel /boot/memtest86+.bin
quiet


28.We want to "comment out" the entries that say "Recovery mode" and "memtest". To do that, make it look like this:


title Ubuntu, kernel 2.6.20-15-generic
root (hd0,1)
kernel /boot/vmlinuz-2.6.20-15-generic root=UUID=fe7bf845-7ce9-4733-b6de-f70f2b62076d ro quiet splash
initrd /boot/initrd.img-2.6.20-15-generic
quiet
savedefault

#title Ubuntu, kernel 2.6.20-15-generic (recovery mode)
#root (hd0,1)
#kernel /boot/vmlinuz-2.6.20-15-generic root=UUID=fe7bf845-7ce9-4733-b6de-f70f2b62076d ro single
#initrd /boot/initrd.img-2.6.20-15-generic

#title Ubuntu, memtest86+
#root (hd0,1)
#kernel /boot/memtest86+.bin
#quiet


29.To change the name of Ubuntu on the bootscreen, just edit the part after "title" in the first entry. Like this:


title Linux Ubuntu Intrepid Ibex
root (hd0,1)
kernel /boot/vmlinuz-2.6.20-15-generic root=UUID=fe7bf845-7ce9-4733-b6de-f70f2b62076d ro quiet splash
initrd /boot/initrd.img-2.6.20-15-generic
quiet
savedefault

#title Ubuntu, kernel 2.6.20-15-generic (recovery mode)
#root (hd0,1)
#kernel /boot/vmlinuz-2.6.20-15-generic root=UUID=fe7bf845-7ce9-4733-b6de-f70f2b62076d ro single
#initrd /boot/initrd.img-2.6.20-15-generic

#title Ubuntu, memtest86+
#root (hd0,1)
#kernel /boot/memtest86+.bin
#quiet


30.Afterwards, leave it alone and scroll down to after "### END DEBIAN AUTOMAGIC KERNELS LIST". You should see something like this:


# This is a divider, added to separate the menu items below from the Debian
# ones.
title Other operating systems:
root


# This entry automatically added by the Debian installer for a non-linux OS
# on /dev/sda1
title Microsoft Windows XP/Vista/ME/2000
root (hd0,0)
savedefault
makeactive
chainloader +1


31.Let's make that look better by commenting out the title and root of the "Other Operating Systems" section. Like so:


# This is a divider, added to separate the menu items below from the Debian
# ones.
#title Other operating systems:
#root


# This entry automatically added by the Debian installer for a non-linux OS
# on /dev/sda1
title Microsoft Windows XP/Vista/ME/2000
root (hd0,0)
savedefault
makeactive
chainloader +1


32.If you want, rename the Windows entry. You can change it to whatever you want. Like so:


# This is a divider, added to separate the menu items below from the Debian
# ones.
#title Other operating systems:
#root


# This entry automatically added by the Debian installer for a non-linux OS
# on /dev/sda1
title Microsoft Windows XP Professional
root (hd0,0)
savedefault
makeactive
chainloader +1


33.At the top of the gedit screen, click "Save".

34.Reboot. Your Ubuntu installation is complete and your GRUB menu should be all pimped out. You MIGHT have to fix back your menu.lst after you update.

35.Now thank me for making this huge guide.

Enjoy the power of Linux!!

-End Note-
If you have a SATA harddrive you may get an error when booting ubuntu. All you have to do is add "irqpoll noprobe=ata4" to the end of the GRUB boot.lst.

If you don't understand how to do that just Google "irqpoll noprobe=ata4" and you should be able to find a guide.