# TripleBoot - Xp/Vista/Ubuntu - StraightFromGrub- AvoidVistaBootloader



## aravind (Apr 22, 2011)

Hello!

I want to install Xp Professional, Vista Ultimate and Ubuntu all on a single hard disk on separate partitions in such a way that

1. I'm able to boot Xp, Vista and Ubuntu all from Grub with each Os having its individual menu choice (avoiding going through Vista Bootloader menu to reach Xp).

2. All three Os' are totally independent so that when I choose to reformat any of the 3 partitions, the other 2 Os' aren't affected by that.

Search results so far: One article(Create a triple boot VISTA/XP/LINUX) suggested the following
-Install Xp first.
-Hide Xp partition (so Vista doesn't write its boot files on the active Xp  partition.)
-Install Vista.
-Unhide Xp partition.
-Install Ubuntu.
-Choose to install Grub on the MBR. So it picks up the previous bootloaders.

Problem: I hid the Xp partition after installation through Gparted from a liveCD (I right-clicked on the partition and checked hidden. Hope that is all I have to do). Even so, during the Vista installation, Xp partition was visible and eventually Vista 'picked-up' Xp's bootloader. But I thought I'd proceed and see what other problems arise with this. I installed Ubuntu. Grub loaded on the MBR picked up the Vista bootloader and I was stuck with the two-step menu.
But the bigger problem that rose was that when I reformatted the Ubuntu partiton I was stuck with a Grub prompt no where to go(Another article suggested a fix to this as creating a separate boot partition with Grub files in it. But I'm yet to try that out as I'm stuck on the first step)(Multiple OS Installation -).

I would like some help on creating two totally independent Windows installations, each complete in its own partition.

Any help is appreciated.

P.S : I may have missed an article offering a solution to this already. Kindly pardon me if I have. I don't know if I'm using the right search terms. But I've been googling an entire day for this and turned up with only 2 or 3 relevant discussions and I'm stuck on the first step.


----------



## Krow (Apr 22, 2011)

I used to triple boot XP, Windows 7 and Linux Mint back home. Here is what I did back then.


Create two NTFS partitions, one for XP, one for Windows 7
Install XP on NTFS Partition 1
Install Windows 7 on NTFS Partition 2
Now you should have Windows 7 bootloader with Windows 7 and Earlier version of windows as the options
Now install Ubuntu/Mint from pendrive or CD and set partitions while installing
Create 2GB free space and assign it to swap
Create 15GB free space and make an ext4 partition with "/" as the mount point
Install Ubuntu/Mint
Now you should have GRUB loader with the Ubuntu/Mint, Win7 and XP

I am not sure if the last step works. What little I remember from long, long ago when I did this is that GRUB gives you an option to Windows 7 Loader only. When you select that, you get the option for Win7 or XP. It is just one extra key, did not bother me much.

I don't have the resources to try out the triple boot with two Windows options in GRUB right now.

The link from TE that you posted says:





> If for some reason GRUB has not recognized XP and Vista, and based on the partition scheme I have used, you can add the following to the end of your GRUB configuration file.
> 
> 
> title Windows Vista/Longhorn
> ...



Did you try that?

Almost all of the internet links to this article: *www.hevnikov.com/blog/2006/11/13/triple-boot-xp-vista-ubuntu-with-single-boot-screen/

But, the link is dead. Sadly, I can't find its content anywhere. 

See the picture here: Lifehacker, tips and downloads for getting things done

But the Hevnikov link is dead.


----------



## aravind (Apr 22, 2011)

Thanks for the reply Krow.



> It is just one extra key, did not bother me much.



I don't mind the extra key either. If Vista had picked up the Xp in the 'hidden' partition, wouldn't it mean that Vista had written its boot files in the active Xp partition? And if that is true, I wouldn't be able to boot into Vista if I decided to reformat the Xp partition sometime later, would I? (I have to admit I'm only beginning to learn about the booting process. So correct me if I was wrong).

As for correcting the Grub configuration file, I was a little iffy about messing with it earlier as I didn't have a decent understanding about it. I'll try it later tonight and let you know how that turns out.

I would like some clarification on two things
1. If I was right on the concept that I understood of the booting process on the first paragraph.
2. If the way I went about hiding the partition was right. I went into Gparted from a LiveCD, I right-clicked the partiton, and checked the hid/hidden tag in the flags option.

Thanks.


----------



## Krow (Apr 22, 2011)

aravind said:


> And if that is true, I wouldn't be able to boot into Vista if I decided to reformat the Xp partition sometime later, would I?


True.


> 2. If the way I went about hiding the partition was right. I went into Gparted from a LiveCD, I right-clicked the partiton, and checked the hid/hidden tag in the flags option.


I haven't used Gparted much. You can PM Liverpool_fan or Rahim to find out about this. AFAIK, Rahim booted 12 Linux distros from GRUB once. You should ask them about GParted.


----------



## doomgiver (Apr 22, 2011)

12??? damn!!! boo windows. if it wasnt for the games, i'd have dumped the crap out of the window (lol @ pun)


----------



## aravind (Apr 22, 2011)

Hello again!

I just realized that since Windows writes the boot files to the active partition always, there was a chance that although I'd hidden the Xp partition before the Vista install, there was a good chance I'd left it as the boot partition.

So next, I installed Xp(There were some complications here. More on that follows); hid the partition; changed the partition where I intended to install Vista as the boot partition and proceeding with booting from the Vista installer DVD.

Interestingly, I was stuck at the 'Windows is loading files' screen for multiple attempts.

Whats more interesting is that I was stuck at a similar screen while installing Xp earlier. But then I deleted the partitions I'd formatted for the intended Ubuntu install and the swap partition(I did that because there were locked signs(in Gparted) next to the extended partition and the swap partition inside it. And I wondered if that had something to do with it). Xp install proceeded fine.

I'm googling for an explanation for this. I'll post what turns out later.

I'm no techie. I've never even done a dual boot before myself. All this is fascinating! Cheers!


----------



## doomgiver (Apr 22, 2011)

The definitive dual-booting guide: Windows 7, Linux, Vista and XP step-by-step refer to this.
step by step with screenies. cant go wrong with screenines.


----------



## Krow (Apr 23, 2011)

In case you are fine with that extra key when booting, you may follow the steps I have listed. That should get you these options in GRUB:

Ubuntu/Linux Mint
Windows Vista/7 loader

When you click on Win Vista/7 loader, you will get a choice between Win Vista/7 and XP.





Alternatively, you may do this to get a triple boot with Vista/7 bootloader instead of GRUB:


Create 3 NTFS Partitions, one for Windows XP, one for Vista/7 and one for Ubuntu/Mint
Install XP in NTFS Partition 1
Install Vista/7 in NTFS Partition 2
Boot into Vista/7 and install Daemon Tools or Virtual Clone Drive
Mount Ubuntu/Mint ISO image file and click "Install inside windows"
Install Ubuntu/Mint in NTFS Partition 3
Now you would get a triple boot (I successfully did this long ago), but you will have a triple boot in Windows bootloader and not GRUB
You may create a fourth NTFS Partition and install Mint from inside Windows Vista/7 in NTFS Partition 4 to get quadro-boot
Enjoy the fruits of your hard work.


----------



## aravind (Apr 24, 2011)

Hello!

Showing a little progress.. 

Status:
Installed Xp, Vista and Ubuntu in such a way that I'm able to access each OS from its own individual Grub entry. Hurrah! The way I did it was exactly the way the gentleman suggested in this articleCreate a triple boot VISTA/XP/LINUX the only difference being, I did not hide the Xp partition after I'd installed Xp. Instead I just changed the active partition leaving Xp visible. (I previously had trouble running Vista setup when I had both hidden Xp partition and flagged the Vista partition as the boot partition. No hiccups now, though).

A thing I'm not able to understand right now is that, I was booting into whichever partition I mark as the boot partition. It might be some simple concept, but beyond my understanding now. Hope to catch it after reading a great article I came across a few minutes back. Multibooters, Vista Dual and Multibooting - A Guide to the Multiboot Process

Yet to do:
I'm yet to confirm if both the Xp and Vista installs are independent in their own partitions. Can anyone suggest me a simple way to do this? I thought of checking for the bootloaders in the respective partitions. Yet to find out where to look for.

I realise both the Windows are dependent on the Grub installed through Ubuntu. Hope to get around it thorough the Grub partition.

Will get back on further progress sometime later maybe.

Cheers!

P.S. Only saw your last post now, Krow. Will try it if things turn out messed up again  Cheers!


----------



## aravind (Apr 24, 2011)

Thanks for the link, Doomgiver. Am yet to see it. Will get back on that. Cheers!


----------



## doomgiver (Apr 24, 2011)

no problem, just dont wreck your computer


----------



## aravind (Apr 25, 2011)

Hello!

Here's what I did!

1. I partitioned my hard disk into 2 with Gparted from a LiveCD. One 30 GB partition first for a Vista install and a 25 GB partition following that for the Xp install. I formatted them both to the NTFS filesystem. I had space left unformatted on the 120GB hard disk.
2. I flagged the 25 GB partition as the boot partition.
3. I installed Xp in that.
4. I tried booting into it. It went fine.
5. Next, through GParted, I flagged the 1st 30GB partition as the boot partition and hid the Xp partition.
6. I ran the Vista install (Surprisingly, it went fine this time. I had problems with running the install previously after hiding the Xp partition). I installed Vista in the 1st 30 GB partition.
7. I restarted the computer.
8. It booted into Vista with no menu to get into Xp.(as I expected)(I assumed Vista installed itself as it would on a brand new harddrive; with all its files in its partition; not disturbing the Xp partition at all; overwriting the Xp entry in the MBR; not disturbing the PBR in the Xp partition. But later, complications that came up made me realise that this might not be what actually happened).
9. Then I created an extended partition(with GParted) in the unpartitioned space. I created swap and ext4 partitions and installed Ubuntu.
10. In the process, I let the Ubuntu setup write Grub to the MBR.
11. I restarted.
12. I was presented with 3 options in the Grub menu, one each for the 3 OS'.
13. I tried booting into all of them. They went great.


Now, I wanted to find out if both the Windows were independent of each other(that was the whole point of this exercise). I had no clue as to how I could find out which partitions the Ntldr and Bootmgr were residing in. So I thought, I'd do the whole process listed above twice(Yes! I did that!); delete the partitions containing the Windows, each in turn, and see what turns out.

Okay.
Steps 1 to 13(the first time).
14. I deleted(through GParted) the partition containing Xp.
What turned out:
I had the Grub menu on restart.
Boot into Ubuntu: fine
Boot into Vista: fine (Yippee!)(So, Vista, when installed after Xp, did not write any of its files in the Xp partition).
Boot into Xp: I was presented with an error report.(Obviously!Duh!) But the error message slapped me hard! "BOOTMGR is missing!" and I was left thinking what Bootmgr had to do with Xp.

Fine.

I deleted all the partitions again!

Steps 1 through 13 again:

14. I deleted (through GParted) the partition containing Vista.
I restarted. 
I was presented with the Grub menu.
Boot into Ubuntu: fine
Boot into Vista: Error: "no such partition".
Boot into Xp: (Moment of truth!) Error: " Windows could not start because the following file is missing or corrupt: <windows root>\system32\hal.dll."

I'm exhausted!

As I'm searching with the error messages, I'm wondering what exactly happened behind the scenes during those installs. I have no idea if the Vista install changed things in the Xp partition. Can anyone offer me an explanation? Or more theory behind those multiple Windows installs?

Thanks!


----------



## ico (Apr 25, 2011)

so, I guess you want three options in your GRUB menu?? 1) Linux 2) Windows XP 3) Windows 7. Am I correct?

If you let Windows 7 overwrite XP's bootloder and then install Linux, it gives you two options. 1) Linux 2) Windows.
And after selecting Windows, then you get the option for Windows XP and Windows 7. I guess this is what you *DON'T* want. 

Try this out:

1) Go to GParted and make partitions. The first partition should be NTFS for Windows 7 (primary), the second should be NTFS for Windows XP (primary) and then ext4 extended partitions for Linux.
2) Install XP on the second NTFS partition and then hide it using GParted later. Then after hiding it, install Windows 7 on the first NTFS partition.
3) Then unhide the XP partition later.
4) Install Linux with GRUB being on the MBR and GRUB will chainload them.

Try this out.

*Edit:*
ok I read the article which you posted in the first post. We both are saying the same thing. Have you followed it thoroughly?

This would have been easier if you had two Hard disks.


----------



## aravind (Apr 25, 2011)

Well! I got 3 options in the Grub menu mate!

What I want is a situation where I can delete either Windows partition without affecting the other Windows install.

I want each Windows to be self-sufficient in its own partition.

I've posted what I did (in detail) in the previous post, Ico.
Yes! We're both saying the same thing. 

 I've got my wish half-fulfilled in having individual menu choices. But the second part of the wish is apparently asking for too much, mate!  Cheers!


----------



## ico (Apr 25, 2011)

Apologies for not reading the whole thread.

If you want each Windows installation to be self sufficient, it is best to install them in two separate hard disks.


----------



## doomgiver (Apr 25, 2011)

wow, aravind, you are totally serious about this, ya?
if i knew of an award for badassery shown during pursuit of geeky knowledge, i'd gladly give it to you.


----------



## aravind (Apr 25, 2011)

lol-@Doomgiver's comment. Thank you, mate. 

@ico - Maybe I'll settle for something like that if I don't end up with a solution in another 2 days or so, mate. Till then... 

I heard of (I'm yet to find a good one. It's late here. Will search for it tomorrow morning.) programs capable of making an image of an entire partition. If so, I was wondering if the following steps might help. Since I don't really know a whole lot about how these work and I don't really have the time to dive into the depths of it (I'd love to. But, I just don't have the time), I'd love it if someone with knowledge about these can tell me if, and why, it won't work.
1. I install Xp in one partition.
2. I take an image of the partition.
3. I reformat that partition.
4. I install Vista in another partition. (This should be something like an install on a new computer).
5. I write the image back on the partition that originally held Xp. (This image should be complete in itself, right)?
6.Now, if I install Ubuntu in a logical partition(shouldn't really matter where) and write Grub to the MBR, will Grub pick the Xp bootloader?

I don't know if I could search the web for a situation like this. It would be really nice if someone with knowledge about this can help.

Thanks and cheers!


----------



## doomgiver (Apr 25, 2011)

did you try and make a separate /boot partition?
then you can install the grub to the mbr, and run 





> sudo update-grub


 from linux

you could also try to change the boot settings via easybcd.


----------



## Krow (Apr 26, 2011)

I'm glad you managed to triple boot. Kudos to you for that. But now all this booting logic is going over my head. 

I never tried so hard to understand what happens and why it happens.

I like your spirit aravind. keep going.


----------



## aravind (Apr 26, 2011)

@Doomgiver - I was thinking about trying the boot partition after I manage the Windows' issue, Doomgiver. (I guess you're suggesting about making the Windows' installs not dependent on the Linux install, which I used to write Grub to MBR. If not, I didn't understand clearly what you're suggesting, mate).

@both Doomgiver and Krow - Thanks a lot for your encouragement, guys. I hope I'll post how I managed to get what I wanted within 2 more days 

I have no idea how I missed this page. Apparently I didn't use the term 'multiboot' in Google before (I have no idea how)   There this page was in the 1st search results page.

Goodells.Net :: Understanding MultiBooting

I'll try it tomorrow and post my tryst with Partimage. 

Cheers!


----------



## doomgiver (Apr 26, 2011)

yeah, you got it.

so, you are trying to know what is going on when the windows installs its boot data?

well, one solution is to make a separate boot partition for each install (like /boot of linux, but i have NO idea how to do that with windows), and add each boot entry to mbr via easybcd. 
else, it looks like you are stuck with xp and 7 joined together, coz one of those WILL be in charge of booting them both



> When we boot any one of the operating systems we want all other OS partitions to be hidden, but want the two data partitions to remain visible. Our data files can then be accessed regardless of which OS we boot into. Hiding a partition means it is ignored while another OS is booted--it will not be assigned a drive letter, and files on it will not be accessible.



oh, so this is what you mean!!

great link!! its going straight to my drive


----------

