LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Dual booting Windows XP and RH9 (https://www.linuxquestions.org/questions/linux-newbie-8/dual-booting-windows-xp-and-rh9-143160/)

roguecoolman 02-06-2004 08:03 PM

Dual booting Windows XP and RH9
 
I know there are some threads on dual booting, but I thoght i'd run this method by and see if everyone thinks it should work or not.

I have a PRIMARY 30 gig MASTER drive loaded with winXP.

I have a SECONDARY 20 gig MASTER drive loaded with linux red hat 9.

Due to case configuration I opted to put the drive on the secondary master because it allowed more air flow.

So I can boot into each drive seperately no problem.

so I've searched the net for dual booting ideas and heres a few that i've stumbled upon:


*note* I'm a linux newbie, so if the methods i'm doing are totally wierd and wrong, please teach nicely thanks :)

I first ran

I ran DF command and the /boot is on HDC1

grub-install /dev/hda1

then i did:

dd if=/dev/hdc1 of=/linux.bin bs=512 count=1

copied the file to a floppy.

went into my winxp

then copied the file C:\

edited boot.ini file to have the entry:

c:\linux.bin="redhat"


but all i get is:

GRUB and screen frozen.

does this method work? can anyone suggest a working method?

thanks:

homey 02-06-2004 09:36 PM

Quote:

grub-install /dev/hda1
Not good! That should be grub-install /dev/hda

Other than that, I'm not sure just what you were trying to do.

spuzzzzzzz 02-06-2004 09:37 PM

I'm not quite sure how your method would work. This is what I would do:
Boot up into linux (using a boot floppy if you have to).
On a command line:

root@localhost# grub

you will get a grub command prompt:

grub> root (hd2,0)
grub> setup (hd0)
grub> quit

then edit the configuration file /boot/grub/grub.conf (this example is taken from the gentoo site):

# Which listing to boot as default. 0 is the first, 1 the second etc.
default 0
# How many seconds to wait before the default listing is booted.
timeout 30
# Nice, fat splash-image to spice things up :)
splashimage=(hd2,0)/grub/splash.xpm.gz

title=Linux 2.4.22
# Partition where the kernel image (or operating system) is located
root (hd2,0)
kernel (hd2,0)/kernel-2.4.22 root=/dev/hdc2

# The next three lines are only if you dualboot with a Windows system.
# In this case, Windows is hosted on /dev/hda1.
title=Windows XP
root (hd0,1)
chainloader +1

syg00 02-06-2004 10:01 PM

Re: Dual booting Windows XP and RH9
 
Quote:

Originally posted by roguecoolman
I have a PRIMARY 30 gig MASTER drive loaded with winXP.
I have a SECONDARY 20 gig MASTER drive loaded with linux red hat 9.
So I can boot into each drive seperately no problem.
I ran DF command and the /boot is on HDC1
grub-install /dev/hda1 <<<<< === ????
then i did:
dd if=/dev/hdc1 of=/linux.bin bs=512 count=1

Presuming the above is a typo, looks reasonable.
How about posting grub.conf and device.map - probably in /boot/grub

roguecoolman 02-10-2004 11:21 AM

sorry that was a typo.

what I was trying to achieve was to let windows boot manager handle the booting. Or so I've been told what this method i was reading up on does.

what i did was i formatted my drive and let linux configure its own size for the /boot.

aparently the method i'm using the /boot cannot be bigger than 8.5gigabytes. I didn't know what the /boot did so i allocated it 10 gigs.

after i reformatted, linux set it to 100megabytes.

df command showed hdc1 as the /boot

i made sure during the install i used GRUB and uncheck load grub into MBR option.

finished my setup.

ran that dd command.

copied the file into my c:\ (on the XP parition)

edited my boot.ini file:

added:

c:\bootsect.bin="Red Hat Linux 9"


works like a charm now. dual booted both paritions and it both work fines.


thanks for replying guys : )

kLUMSY bOT 02-11-2004 02:30 AM

pop this into the success section. let others know that thier dualbooting woes can be fixded.

syg00 02-11-2004 03:52 AM

Quote:

Originally posted by kLUMSY bOT
pop this into the success section. let others know that thier dualbooting woes can be fixded.
Sounds like a good idea - this subject comes up all the time.
FWIW, I prefer to use the NT bootloader. You just *KNOW* that windows will overwrite the MBR everytime you do an update.
I have to keep a Win system available - what you have done is the best option.

kLUMSY bOT 02-11-2004 03:54 AM

oh. you're using the windoors bootloader to load linux?

syg00 02-11-2004 04:01 AM

Ooops sorry if I was muddying the waters.
I use the NTLDR to give me the option - as roguecoolman was looking to do.

Go to win, or to the GRUB stage 2.
As it turns out, I also have an entry in there so I can get back to Windows.
Circles within circles .... :)

kLUMSY bOT 02-11-2004 04:03 AM

ah. clever! i dint get you. :D

abs 02-21-2004 04:14 PM

Quote:

Originally posted by spuzzzzzzz
# The next three lines are only if you dualboot with a Windows system.
# In this case, Windows is hosted on /dev/hda1.
title=Windows XP
root (hd0,1)
chainloader +1

shouldn't the root line be root (hd0,0)? in the grub documentation, i found it as:
# For booting Windows NT or Windows95
title Windows NT / Windows 95 boot menu
root (hd0,0)
makeactive
chainloader +1

spuzzzzzzz 02-21-2004 04:55 PM

I'm not quite sure why I put (hd0,1) instead of (hd0,0), but I may have done it for a good reason. (hd0,1) points to the second partition of the first drive (aka /dev/hda2). (hd0,0) points to the first partition of the first drive (aka /dev/hda1). The correct one to use depends on how your hard drives are partitioned.

abs 02-21-2004 06:09 PM

precisely. u have it on hda2? so i guess u've changed that root bit but didn't change the comment right? makes sense now.

btw, the bootsect.S in /usr/src/linux-<kernel_version>/arch/i386/boot is the actual boot sector info for linux that would be written to the mbr ? if yes, is this the file i need for linux.bin or bootsect.bin (wuteva name) for the c:\linuxboot.bin? also, is the '.bin' required?

Demonbane 02-21-2004 08:18 PM

Quote:

btw, the bootsect.S in /usr/src/linux-<kernel_version>/arch/i386/boot is the actual boot sector info for linux that would be written to the mbr ? if yes, is this the file i need for linux.bin or bootsect.bin (wuteva name) for the c:\linuxboot.bin? also, is the '.bin' required?
No you have to extract either grub/lilo, no the .bin isnt required, you can use whatever filename you like(but keep it simple).

abs 02-22-2004 12:38 AM

another thing. from what i understand, suppose i install lilo/grub to the boot sector of whichever drive (not hda), then if i've configured multiple kernels in lilo.conf and grub.conf, i will still have just one boot sector file to copy to windows, right? so i'm chain loading lilo (or grub) from the windows boot?

it would be something like:
win xp
linux

(if i choose linux) then:
linux 2.4.x
linux 2.6.x


All times are GMT -5. The time now is 12:46 PM.