LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - General (http://www.linuxquestions.org/questions/linux-general-1/)
-   -   4 primary partitions, windows dual boot trouble (http://www.linuxquestions.org/questions/linux-general-1/4-primary-partitions-windows-dual-boot-trouble-150002/)

geekX 02-24-2004 01:48 PM

4 primary partitions, windows dual boot trouble
 
I installed gentoo on a 40gig harddrive at work. I made 4 partitions:

1 - 100MB (boot partition)
2 - 512MB (swap partition)
3 - 30GB (root partition)
4 - whatever was left so that I could install windows on it.

I installed gentoo (using the first 3 partitions) and it was all working fine. Within a day or two I had to install windows xp to work on some proprietary stuff, of course. ..

I figured I'd just install it on the 4th partition, but the windows install complained that there is no free space. so I removed the 4th partition, thinking it probably wants to create it's own. Then it said I already have the maximum amount of partitions! So it seems that windows only recognises up to three partitions... I ended up removing the boot partition (now there's free space at the start of the device) thinking that I could just boot using a boot cd and then fix it later, and created the partition in the +/- 10 gigs free at the end.

Now I'm getting vmware and I want to fix linux again. (without messing up my xp install - just in case). Can I just recreate the partition at the front (using the 100mb free space) without screwing up windows? As in - does it only check the amount of partitions when you install, or should I rather use gentoo without a /boot partition and rather boot off my root partition? (how do I then create /boot on my root partition? so I just create an empty folder? what do I have to copy to it, apart from my kernel?)

I'f I'm going to install lilo again, then it will override the boot sector, so will I be able to dual boot windows by just adding an entry for it in lilo.conf? At home I have two seperate harddrives, so I never ran into this issue before.

aaa 02-24-2004 02:23 PM

I'm guessing that when you deleted the boot partition you had to make changes in Gentoo. The same goes for Windows. Let's say your hard drive is hda. It was like this:

hda1 - boot
hda2 - swap
hda3 - root

Now with the boot deleted, it probably looks like this:

hda1 - swap
hda2 - root
hda3 - Windows

The partitions' names change. When you recreate the boot, the names will change again. You'll have to adjust Gentoo & Windows, because Windows will be hda4 instead of hda3 and become confused. To adjust Windows, you edit the boot.ini file.

whansard 02-24-2004 02:31 PM

you could have made the partition in advance and installed windows on it.
windows will boot with 4 primarys, but the windows installer isn't forgiving
about other OS's on the computer, and MS will not go to the trouble to
make their installer work with a bunch of different configurations. Hence,
the stupid error messages. windows wants to be the only primary.
you can boot linux from a logical drive, if you don't want to argue with windows.

geekX 02-25-2004 02:22 AM

Quote:

Originally posted by aaa
The partitions' names change. When you recreate the boot, the names will change again. You'll have to adjust Gentoo & Windows, because Windows will be hda4 instead of hda3 and become confused. To adjust Windows, you edit the boot.ini file.
where do I find this boot.ini file? I don't have a lot of data on windows yet, so I'll just back up, add the boot partition again, change this ini file and reinstall lilo to get rid of Microsoft's boot loader.

should that work? how do I create a boot partition? can I just format it as ext2, copy the kernel and run lilo and will that copy all the necessary files?

aaa 02-25-2004 03:04 PM

C:\boot.ini
See the MS knowledgebase for help on it. Don't forget to back it up.
To create a partition, you use fdisk. Linux partitions are of type 82 or 83 (one is for swap). Then you format the partition using mke2fs for ext2.
You don't really need a boot partition, you can go without one. Just boot with a bootdisk and replace the stuff deleted (the kernel image, among other things, was in the boot directory/partition, and was probably deleted), and reinstall lilo. 'fixmbr' from the Windows XP cd will restore the mbr in case you mess up.

geekX 02-25-2004 05:42 PM

thanks a lot. I'll try that. Will definitely back things up and wait for the weekend before I try it, though.


All times are GMT -5. The time now is 06:31 PM.