• Log in or sign up for an account here: https://www.sythe.org/login

XP dual boot to Ubuntu

Joined
Jan 21, 2007
Sythe Gold
0
Messages
1,587
Location
Los Angeles, CA
How would one dual boot XP and Ubuntu linux with XP already installed without losing files? Pretty straight forward question...I looked on google but I couldn't find anything without me having to start off with a fresh HDD...
 
Defrag your hard drive, boot up the Ubuntu livecd, and use the "Partition Editor", under System, to shrink the NTFS filesystem. Then create a new ext3 partition and select that to be mounted as "/" when you install.
 
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.)

Hope thats helps :)

http://ubuntuforums.org/showthread.php?t=56723
 
Oh lmao I didn't even see your post
What do you mean by "to shrink the NTFS filesystem"?

EDIT: woah eric your irc rank just dissapeared XD
now its back...
 
Oh lmao I didn't even see your post
What do you mean by "to shrink the NTFS filesystem"?

EDIT: woah eric your irc rank just dissapeared XD
now its back...
Well, you see the massive graphical display on the partition editor? You see the arrows denoting how they can be dragged? DRAG IT TO SHRINK THE FILESYSTEM. SHRINK MEANS TO MAKE SOMETHING SMALLER.
 
I know what shrink means calm down lol
What should I shrink it to...
Leave Ubuntu as much space as you think you'll need. If you have a big enough disk, give Ubuntu about 10GB.
 
Runescape Gamblingrunescape gambling
Back
Top