How to dual boot Windows and linux without changing the Windows Master Boot Record:
(I'm assuming you've read other FAQs on how to install linux to your partition of choice. I recommend creating a partition on a second hard drive. That's the risk free option if you don't want to destoy Windows on your primary partition. But you should be able to create a partition on your primary hard drive by using software that can non-detructively resize your Windows partition. QTParted is a good program which can be downloaded if you're running the ubunut live CD. Back up though. It doesn't always work. I don't think the partition resizer in the ubuntu installer can do non-destructive.)
When installing ubuntu, install the boot loader (GRUB) to a floppy disk instead of the MBR. ie. when prompted for grub location enter: /dev/fd0
Boot into ubuntu with the floppy.
Open a terminal window.
Copy your bootloader from the floppy to a file called bootsect.lnx with this command:
dd if=/dev/fd0 of=bootsect.lnx bs=512 count=1
Save that file somewhere that you can access from within Windows. ie a FAT partition, a USB drive, a floppy (but not your boot floppy!) Don't try saving it to an NTFS Windows XP partition from within linux. (Bad!)
Reboot into Windows. (hint: take the floppy out of the drive. Keep it somewhere as a rescue boot floppy.)
Copy bootsect.lnx from wherever you had stored it to c:\bootsect.lnx
Open a file called c:\boot.ini
(It's normally a hidden read-only file, so you may have to change the folder and file options.)
After opening boot.ini add the following line to the end of it and save it:
c:\bootsect.lnx=”Linux”
Reboot your system.
You will be prompted to boot either Windows or Linux and your MBR hasn't been changed at all!
It's magic!
I use this setup to boot ubuntu from the third partition of my second hard drive. As ubuntu is on a second drive I haven't made any changes to my Windows partition at all! Risk free.
(If you do screw up your MBR and can't get into Windows try booting your Windows rescue CD and then type 'fdisk /mbr' to restore it. If you already have ubuntu installed I think you can make a boot floppy this way, but I"m not 100% certain: In a console, type grub-intall /dev/fd0.)
I apologize if to anyone who's already read this in the installation forum but someone suggested it would be more useful to post this here.
James.
Bookmarks