XP/WIN7/Ubuntu tri boot?

flux

New Member
#1
I used to have a XP/Vista dual boot on my computer, but haven't been having a good experience with Vista, so now that WIN7 RC is out I'd like to go back to my XP:tongueout:RO and Win7.
As you can see there is no Vista in this tri boot, but I've heard that WIN7's bootloader is similar or the same as Vista's so I'm wondering if that will be enough if not disregard the rest of this post.

I plan to have 3 OS's on one physical drive. I heard the only way to install OS's onto logical partitions is that if the bootloader is installed to a primary one.

I plan to partition as follows:
C: 5GB FAT32 - primary - (is there a way to force the bootloaders to install on this partition?)
D: 30GB NTFS - logical extend (WINXP)
: 25GB EXT3 - primary (UBUNTU)
: 1GB SWAP - logical extended
E: 30GB NTFS - primary extend (WIN7)
F-H: random logical extended partitions for data and media

If there is a problem with the ordering of partitions or the state of each partition please feel free to suggest alternatives. Note that WIN7 RC will be with me till AUG2010.

Also the order of installation, should I do WINXP/WIN7/UBUNTU or UBUNTU/WINXP/WIN7

Thanks in advance.
 
#2
Hi flux, welcome to NST.
Your best bet, I think, is to install XP first, Win 7 next, and Ubuntu last (and choose the "Advanced" option during the Ubuntu setup, and specify the Ubuntu partition as where to install Grub, instead of to the MBR).
If you do that, then Win 7's boot files will go to the XP partition because it will still be marked to "active", so that is two systems' bootloaders you will have on that partition, and then with Ubuntu, when you add the entry under the Linux tab in EasyBCD's Add/Remove Entries section, and do not check the "Grub is not installed to the MBR/bootsector" box (because Linux will be on the same HDD as Windows), what will happen is there will be a redirector to the Linux partition from the Win 7 bootloader, and it will basically chainload the Linux Grub there.
Then, all you will need to do is use [thread=642]EasyBCD 2.0 Beta, build 61[/thread] to add the XP entry to your Win 7 BCD, and it will give you the option of auto-configuring boot.ini. Just hit Yes, and then you will have a triple boot.

Cheers.

Jake
 
Last edited:

Agys

New Member
#3
Hi there,

I'm hijacking this thread because my setup looks very much the same.
I installed on my NC10 Win XP when I got it a few weeks ago. Today I installed Ubuntu 9.04 Netbook Remix and later the Win 7 RC.

The current situation looks like this:
disk0: 160GB
partition 1: 100GB, Win XP
partition 2: 25GB, Win 7
partition 3: 23GB, Ubuntu
partition 4: 2GB, Ubuntu swap

After some googling and rebooting in the ubuntu-live-flashstick I got grub back to work after the Win 7 installation, so I can choose between the Vista bootloader or ubuntu. And the Vista loader boots fine into Win 7 or XP.
But I'd like to have three choices in one bootloader (either is fine for me).

After reading your description it looks like that the Win7 bootloader will be the choice for me. But I did not choose the advanced options during the ubuntu installations to place Grub somewhere specific...
Could you describe (or point me to the correct thread) the steps to correct this so I can really triple-boot and not dual-dualboot?
 

Terry60

Knows where his towel is.
Staff member
#4
Hi Agys, welcome to NST.
How exactly are you booting at the moment, from grub off a flashdrive or from the MBR of your HDD.
If you let Linux take over the MBR and that's what's controlling the boot, you don't have to boot XP through the W7 BCD. You could just add an entry to menu.lst for XP and chainload NTLDR.
 
#5
Hi there,

I'm hijacking this thread because my setup looks very much the same.
I installed on my NC10 Win XP when I got it a few weeks ago. Today I installed Ubuntu 9.04 Netbook Remix and later the Win 7 RC.

The current situation looks like this:
disk0: 160GB
partition 1: 100GB, Win XP
partition 2: 25GB, Win 7
partition 3: 23GB, Ubuntu
partition 4: 2GB, Ubuntu swap

After some googling and rebooting in the ubuntu-live-flashstick I got grub back to work after the Win 7 installation, so I can choose between the Vista bootloader or ubuntu. And the Vista loader boots fine into Win 7 or XP.
But I'd like to have three choices in one bootloader (either is fine for me).

After reading your description it looks like that the Win7 bootloader will be the choice for me. But I did not choose the advanced options during the ubuntu installations to place Grub somewhere specific...
Could you describe (or point me to the correct thread) the steps to correct this so I can really triple-boot and not dual-dualboot?
What was the order you installed the OSes? Was Ubuntu last? If so, then Grub will be installed to the MBR of that drive.
As Terry said, you can just add an entry to your Ubuntu menu.lst (which can be found at boot/grub/menu.lst on your Ubuntu partition) to boot XP.
In you case, the syntax would probably be something like
Code:
title XP
root (hd0,0)
chainloader +1
or
Code:
title XP
find --set-root--ignore-floppies /ntldr
chainloader /ntldr
You can put the entry at the end of the menu.lst file, so it is the last boot entry. Just remember, if you use the second example, there will need to be a NTLDR (along with NTDETECT.COM and BOOT.INI) in the root of the XP partition, and nowhere else. Otherwise, it wouldn't know which one to pick. You will also need to remove the XP entry from Win 7's BCD with EasyBCD if you use this method.

Or you have the option of running Startup Repair (most likely 2-3 times since it can only fix one thing per pass) from Win 7's DVD (while booted from it) to put Win 7's bootloader back in charge of the boot. Then you can use [thread=642]EasyBCD 2.0 Beta[/thread] to add a normal Linux entry to the Win 7 menu, with the "Grub is not installed to the MBR/bootsector" checkbox not checked, since it is on the same hard drive as Windows, making sure to point it at the correct partition from the "Device" drop-down menu under the Linux tab.
And then you will have a triple boot. :smile:
 

Agys

New Member
#6
The order of installation was:
Win XP
Ubuntu
Win 7
and Ubuntu again, as it seemed the fastest solution to regain grub (I tried supergrub but it didn't really work...)

So I'll try adding that entry to grub, thank you!

Update:
Well, this didn't work, since the entry for the Windows 7 bootloader is
title Windows 7 (loader)
rootnoverify (hd0,0)
savedefault
makeactive
chainloader +1

so adding another entry for (hd0,0) also started the win7 bootloader.
And your second proposed entry with find --set-root... printed the message "error 15: file not found".

If I understand the situation, (hd0,0) should direct to XP and (hd0,1) the the win7 installation, but because win7 overwrote the old XP loader and didn't create a new one, (hd0,0) points to win7 loader and (hd0,1) doesn't work at all.
Correct?

And the fix for that would be to boot from the win7 dvd and let startup repair kill grub? I'd rather not, first because getting grub the first time wasn't as easy as I thought :wink: and second because I've installed from a flashstick from inside XP because it wasn't bootable...
 
Last edited:

Terry60

Knows where his towel is.
Staff member
#7
If you want to use grub ( as I do, in its HnS version) to boot a number of independent systems, then they'll each need their own boot files.
You've let W7 take over the XP boot by installing the W7 boot files into the XP partition, so they're not independent, and can only be booted by grub in the way you're currently doing.
You'll either need to do a lot of changing of the Windows boots, with a repair Install of XP, switching W7 to be "active", repairing the W7 boot 2 or 3 times, and then configuring grub to chain them as described before; or you can let W7 control the boot, and just add an entry for Ubuntu using EasyBCD 2.0.
First you'd need to restore the MBR to look for bootmgr, then add an Ubuntu entry. Normally you'd just add a Linux entry without ticking the "grub is not..." box since Linux shares the same HDD, but in this case, since you didn't install grub to the ubuntu partition, you'd need to tick the box, which will install Neogrub in W7 and use it to chain to ubuntu from the W7 bootmgr.
 
#8
If "ntldr" is not being found when using the second type of entry I described, in your menu.lst, then you will need to use [thread=642]EasyBCD 2.0 Beta[/thread]. Just open up Tools>Auto-configure boot.ini.
When the window pops up, you should see a link to a page at Neosmart.net where you can download the NTLDR and NTDETECT.COM files. Once you download them, simply place them into the root of the XP partition. Hopefully boot.ini will exist already, but if it doesn't, you can go ahead, and use the auto-configurator in EasyBCD to create one that is configured correctly.
Then the entry should work.
 
Last edited:

Agys

New Member
#9
The XP Partition contains already boot.ini, ntdetect.com and ntldr. So this shouldn't be the problem.

I'll try to make a bootable win7-flashstick, but as it didn't work last time, I'm not so sure about this time..
 
#10
Ok, so how about this:


  1. Create a random text file (you can put whatever you want in it) using Notepad, save it as "XPfinderfile.txt" without the quotes.
  2. Place it in the root of the XP partition.

Then change the entry to say the following instead:

Code:
title XP
find --set-root--ignore-floppies /XPfinderfile.txt
chainloader /ntldr
I think your problem is you have multiple "ntldr" files on your system, in different places.
 

Agys

New Member
#11
Where should be another one? The win7 partition contains only autoexec.bat, config.sys and the page- and hiberfile.

But I found a tutorial how to create a working bootable win7 stick. Perhaps this will make system repair possible...
I'll keep you up to date :wink:
 
#12
Where should be another one? The win7 partition contains only autoexec.bat, config.sys and the page- and hiberfile.

But I found a tutorial how to create a working bootable win7 stick. Perhaps this will make system repair possible...
I'll keep you up to date :wink:
How is a bootable Win 7 stick going to help your problem any? Are you planning to use it every single time to boot your 3 systems?
Try my last suggestion, and see if it works.
 

Agys

New Member
#13
I'll try it, but if it doesn't work, I'll need a Win DVD (or as in my case with no dvd-drive, a flash stick) to switch from grub to the winloader.

Update:
I tried placing files in the winxp (as well as the win7) partition with different names, but grub wasn't able to find one of them. Is grub able to search in ntfs partitions at all?
 
Last edited:
#14
I'll try it, but if it doesn't work, I'll need a Win DVD (or as in my case with no dvd-drive, a flash stick) to switch from grub to the winloader.

Update:
I tried placing files in the winxp (as well as the win7) partition with different names, but grub wasn't able to find one of them. Is grub able to search in ntfs partitions at all?
Good question. Now that I think about it, the standard GNU Grub probably can't (though I believe NeoGrub, which is basically a modified version of Grub for Windows, can). So you would need to use standard Grub syntax if you were going to boot XP or Win 7 that way. Unfortunately, it would require the boot files of both OSes on their own respective partitions, and nowhere else.
Yeah, at this point, your best bet may be to figure out how to get a bootable Win 7 ISO to work on a UFD, and then use that to put Win 7's bootloader back in charge of the boot, with Startup Repair.
Another option you can use to do that, if you don't want to go to all that work, is use the MbrFix tool (which can be found in the /bin directory of the EasyBCD program files folder).

So, boot into Win 7, open up EasyBCD>Useful Utilities>Power Console, and run the following command:

Code:
MbrFix /drive 0 fixmbr /vista /yes
That should replace Grub's MBR with a Vista compatible one, which is basically the same thing as Win 7's. And you should be able to boot that way, provided the XP partition is still set to "active". And then just use [thread=642]EasyBCD 2.0 beta[/thread] to add an entry to boot Ubuntu, from the Linux tab in the Add/Remove Entries section of EasyBCD.

EDIT: Or an entry like this for XP should work:
Code:
title XP[FONT=monospace]
rootnoverify (hd0,0)
[/FONT]chainloader +1 /ntldr
 
Last edited:
#15
Thanks Coolname007

Followed you're instructions.

I got a now all 3 booting. The Win7 bootloader loads straight to XP or 7 and chains to the grub loader.
 
#16
Great! :smile: Happy to hear it.
Let us know if you experience any more problems, flux.

Jake
 

Agys

New Member
#17
So, boot into Win 7, open up EasyBCD>Useful Utilities>Power Console, and run the following command:

Code:
MbrFix /drive 0 fixmbr /vista /yes
That should replace Grub's MBR with a Vista compatible one, which is basically the same thing as Win 7's. And you should be able to boot that way, provided the XP partition is still set to "active". And then just use [thread=642]EasyBCD 2.0 beta[/thread] to add an entry to boot Ubuntu, from the Linux tab in the Add/Remove Entries section of EasyBCD.
This was just the fastest way to do it. (Well, I still have to boot through grub to get into ubuntu, but I set it to 2 seconds until it chooses the default, so thats OK).

A big Thank you to Coolname and Terry!
 
#18
Need help!

Hi,
Cool post.Please help me how to triple boot XP/WIN 7/UBUNTU 9.04.
I installed Win XP/WIN 7 first. Now I have Win 7 RC bootloader. After wards I installed Ubuntu 9.04 on separate partition. But now the Ubuntu bootloader does not show. Only Win 7 boot menu shows up. I can only boot Ubuntu with Live CD only. What changes should i make to allow Ubuntu boot from hard disk.

Configuration:
Pentium D 2.66 Ghz, D101 ggc motherboard, ATI Radeon 200 Chip set, 1.5 gb ram.
 
#19
Hi,
Cool post.Please help me how to triple boot XP/WIN 7/UBUNTU 9.04.
I installed Win XP/WIN 7 first. Now I have Win 7 RC bootloader. After wards I installed Ubuntu 9.04 on separate partition. But now the Ubuntu bootloader does not show. Only Win 7 boot menu shows up. I can only boot Ubuntu with Live CD only. What changes should i make to allow Ubuntu boot from hard disk.

Configuration:
Pentium D 2.66 Ghz, D101 ggc motherboard, ATI Radeon 200 Chip set, 1.5 gb ram.
Hello, shreen. Welcome to NST.
Just add a simple Linux entry under the Linux tab in the Add/Remove Entries section of EasyBCD (use the [thread=642]beta[/thread] version since it has more Linux support). Don't check the box that says "Grub is not installed to the MBR/bootsector", since Ubuntu is on the same HDD as the primary bootloader (i.e. Win 7's). Make sure to point the entry at the correct partition under the "Device" drop-down menu under the Linux tab, and then you will have a triple boot. :smile:

Cheers.

Jake