Click to See Complete Forum and Search --> : LILO Boot LILO


jus
10-05-2002, 11:54 PM
Greetings,

I have the following setup
/dev/hde = RH Linux 7.3 Distro Install
/dev/hdg = Linux from scratch install

While installing LILO for hdg, I had a curious though.
Is it possible to have LILO installed in the MBR on one hard disk actually boot LILO in the MBR in the second? The following is my lilo.conf on dev/hdg

prompt
timeout=50
default=redhat
boot=/dev/hdg
map=/boot/map
install=/boot/boot.b
message=/boot/message
linear

image=/boot/lfskernel
label=lfs
root=/dev/hdg1
read-only

other=/dev/hde
label=redhat

Upon selecting the "redhat" option, I simply get LILO on /dev/hdg again (as opposed to the one on /dev/hde as desired). After reading the LILO documentation thouroughly, I can only conclude that it has to do with the boot=/dev/hdg line. However excluding that line does not work at all.

Just curious if anyone has pulled this off, and if so, how did you do it??

slapNUT
10-06-2002, 06:42 AM
I'm not sure I understand the problem but I think you can't boot Redhat cause it just goes back to lilo prompt.

Here's what I think you need to do.
Boot off the redhat bootdisk or rescue from cdrom. Edit the Redhat /etc/lilo.conf and make sure the boot= line points to the MBR for the Redhat drive e.g.
boot=/dev/hde
Also verify the root= is correct for the image section e.g.
root=/dev/hde1 <- or whatever it should be.

Save that and run lilo.

Reboot into the LFS distro and edit /etc/lilo.conf and change the redhat section like this:
other=/dev/hde1
table=/dev/hde
label=redhat

Save that and run lilo.

jus
10-06-2002, 11:19 AM
Hey slapNUT,

Thanks for the reply.

Allow me to clarify my situation. I have no problem booting the REDHAT kernel from the LFS drive, but what I want to do is have LILO on hdg chain.b over to LILO on hde. As a result when BIOS runs LILO on hdg, and I select the redhat option, I get the redhat LILO boot screen, and vice versa. More of an exercise really. If it works, theoretically, I could switch back and forth between LILOs never actually starting an OS. :D

That little piece of lunacy was inspired by the following article:

http://www.netspace.net.au/~gok/power2bash/power2bash/power2bash-3.html

All part of my LFS twisted education. :D

sharth
10-06-2002, 11:42 AM
check the other lilo config file and make sure that it is installed on the other mbr.

slapNUT
10-08-2002, 06:46 PM
OK I think I understand now.

I don't think you can do it by putting lilo on the MBR but if you boot off the linux partition then I think it would work. The reason I don't think it will work putting lilo on the MBR is that you would need an entry in lilo.conf on hdg like this:
other=/dev/hde
And then you would have the reverse in the lilo.conf of hdg and this would not work.

Now this is theory only but if you booted into each distro separately and activated each linux partition as bootable using fdisk then installed lilo on the linux partition rather than the MBR then you could put entries in the lilo.conf of each drive that points to the lilo on the other drive e.g

lilo.conf hdg1
other=/dev/hde1
table=/dev/hde
label=RedHat

lilo.conf hde1
other=/dev/hdg1
table=/dev/hdg
label=LFS

jus
10-08-2002, 10:14 PM
Thanks for the suggestion slapNUT.

Will give it a try.

I wonder, will writing a boot loader to a partition that already contains a file system corrupt the filesystem? Or does mkfs start after the magic number on a partition?

Will try to scare up another hard drive and test it there first ;)

thanks again slapNUT.

Jussy is learning at the speed of light :cool: