LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 07-23-2003, 03:11 PM   #1
General_Tso
Member
 
Registered: Jan 2003
Location: New York, NY, USA
Distribution: Mac OS X (10.4.6), Ubuntu 6.06
Posts: 183

Rep: Reputation: 30
LILO: Two Distros, Separate Drives


Folks,

Sorry for yet another LILO question. I have lilo installed on my MBR, and RH9 and Debian installed on hda and hdb respectively. Do I need their kernels to be in the same location for LILO to work properly? Right now, I have them in /dev/hda/boot and /dev/hdb/boot.

Thanks,

GT
 
Old 07-23-2003, 03:13 PM   #2
Proud
Senior Member
 
Registered: Dec 2002
Location: England
Distribution: Used to use Mandrake/Mandriva
Posts: 2,794

Rep: Reputation: 116Reputation: 116
I have a similar layout. Your lilo.conf for each install simply has to have the correct path to where the relevant files are mounted at the time when you run lilo.
 
Old 07-23-2003, 03:36 PM   #3
General_Tso
Member
 
Registered: Jan 2003
Location: New York, NY, USA
Distribution: Mac OS X (10.4.6), Ubuntu 6.06
Posts: 183

Original Poster
Rep: Reputation: 30
Proud,

Do you mind posting your lilo.conf? As is mine looks like the following:

# Security
password=[omitted]
# Support LBA for large hard disks
lba32
#General Section
boot=/dev/hda
timeout=200
default=RedHat9
vga=normal
map=/boot/map
install=/boot/boot-menu.b
# Red Hat Linux 9.0
image=/boot/vmlinuz-2.4.20-8
label=RedHat9
root=/dev/hda2
read-only
append="hdc=ide-scsi hdd=ide-scsi root=LABEL=/"
initrd=initrd-2.4.20-8.img
# Debian GNU/Linux 3.0r1
[I don't know what to stick here.]

Thanks,

GT
 
Old 07-23-2003, 04:38 PM   #4
Proud
Senior Member
 
Registered: Dec 2002
Location: England
Distribution: Used to use Mandrake/Mandriva
Posts: 2,794

Rep: Reputation: 116Reputation: 116
Well I have two Mdk9.1 installs on seperate partitions, but the principal is the same.
For the kernels not on the /boot partition (ie on the other mounted partition) I have entries like:
Code:
image=/mnt/hdb1/boot/vmlinuz
	label="Mdk9.1hdb1"
	root=/dev/hdb1
	initrd=/mnt/hdb1/boot/initrd.img
instead of
Code:
image=/boot/vmlinuz
	label="Mdk9.1hdb5"
	root="/dev/hdb5"
	initrd="/boot/initrd.img"
Simply mount the partition of the other harddrive which contains the /boot directory (hdb2?), and then copy in your case Debian's lilo.conf kernel entries but with the /mnt/hdb2/ string in front.
 
Old 07-23-2003, 05:33 PM   #5
Skyline
Senior Member
 
Registered: Jun 2003
Distribution: Debian/other
Posts: 2,104

Rep: Reputation: 45
Re-enforcing what PROUD said - the idea is to temporarily mount the partiton that contains the kernel from your 1st distro into a mount point in the 2nd dsitro.

Then simply copy over the relevant LILO settings from your 1st dsitro's mounted partition into your 2nd distro's Lilo.conf file.

Then - you'll have to modify the path to the kernel and possibly initrd.img file in the 2nd dsitro's lilo.conf file - remember your're taking into account the mounted nature of the kernel at that point.

Once youve done this save the lilo.conf file then

SU
Root password

/sbin/lilo

this will run the map installer and re-install LILO.
 
Old 07-23-2003, 05:50 PM   #6
synecdoche
Member
 
Registered: Jul 2003
Location: British Columbia, Canada
Distribution: CollegeLinux 2.5
Posts: 148

Rep: Reputation: 15
I'm curious-- why do you have two installs of the same distro on one computer? I've heard of having different distros on the same computer, but not two copies of the same one.

Just wondering what the advantage is... Work/play installs, or what?

Thanks,
dave
 
Old 07-23-2003, 05:55 PM   #7
Proud
Senior Member
 
Registered: Dec 2002
Location: England
Distribution: Used to use Mandrake/Mandriva
Posts: 2,794

Rep: Reputation: 116Reputation: 116
First it was 9.0, then 9.0 & 9.1. Then 9.0 became 9.1server style, but broke, and now I have 9.1 'stable(r)' and 9.1 'test'. If a new package doesnt cause problems I install it on my stable(r) one too. Plus it's a full backup incase I get hosed via testing apache or something. All helps speed the learning process.
 
Old 07-24-2003, 08:28 PM   #8
General_Tso
Member
 
Registered: Jan 2003
Location: New York, NY, USA
Distribution: Mac OS X (10.4.6), Ubuntu 6.06
Posts: 183

Original Poster
Rep: Reputation: 30
I guess I need spoon-fed here. I mounted the temporary "/boot" from the first distro on my second distribution, but I got kernel panics when I rebooted. What do you have to do next? I'm struggling here.

BTW, here's a copy of my lilo.conf:

# Security
password=[omitted]
# Support LBA for large hard disks
lba32
#General Section
boot=/dev/hda
timeout=200
default=RedHat9
vga=normal
map=/boot/map
install=/boot/boot-menu.b
# Red Hat Linux 9.0
image=/rhboot/vmlinuz-2.4.20-8
label=RedHat9
root=/dev/hda2
read-only
append="hdc=ide-scsi hdd=ide-scsi root=LABEL=/"
initrd=/rhboot/initrd-2.4.20-8.img
# Debian GNU/Linux 3.0r1
image=/boot/vmlinuz-2.4.18-bf2.4
label=DebianWoody
root=/dev/hdb2
read-only

Thanks,

GT
 
Old 07-24-2003, 09:16 PM   #9
Skyline
Senior Member
 
Registered: Jun 2003
Distribution: Debian/other
Posts: 2,104

Rep: Reputation: 45
Hi General TSO

Are these 2 Paths correct given that you should have temporarily mounted Red Hat's Root partition to /mnt in Debian

image=/rhboot/vmlinuz-2.4.20-8
initrd=/rhboot/initrd-2.4.20-8.img

I personally would temporarily mount Red Hats Root partition to a directory in Debians /mnt - Red Hats root partition will contain a boot directory inside with the Red Hat kernel image in it


So in Debian - if the mount point is

/mnt/tso

then you should modify the LILO lines to read

image=/mnt/tso/boot/vmlinuz-2.4.20-8
initrd=/mnt/tso/boot/initrd-2.4.20-8.img

Last edited by Skyline; 07-24-2003 at 09:20 PM.
 
Old 07-24-2003, 10:27 PM   #10
General_Tso
Member
 
Registered: Jan 2003
Location: New York, NY, USA
Distribution: Mac OS X (10.4.6), Ubuntu 6.06
Posts: 183

Original Poster
Rep: Reputation: 30
Hey, Skyline.

Well, I mounted /dev/hda1 (where I mounted /boot of RH9) at /rhboot--hence the /rhboot/vmlinuz-2.4.20-8, etc. Let me give it a try on /mnt. That might make all the difference. But, just to clarify, I have one boot partition for Red Hat on hda1 and one for Debian on hdb1. I'm not sure if that itself is wrong.

Thanks,

GT
 
Old 07-24-2003, 10:42 PM   #11
Skyline
Senior Member
 
Registered: Jun 2003
Distribution: Debian/other
Posts: 2,104

Rep: Reputation: 45
Hi General TSO

Again - I personally would just mount Red Hat's ROOT partition - not its Boot partition - inside Red Hat's Root partition there's a little boot directory containing all the relevant files -

If you create a directory in Debian's /mnt and call it "tso" you'd do

mkdir /mnt/tso

now - if Red Hat's Root partition was on /dev/hda2 then you would just want to mount this partition - youd do

mount -t ext3 -o rw /dev/hda2 /mnt/tso

This would create a temporary mount

Then just copy over Red Hats LILO settings into Debain's LILO.conf file

Then modify the relevant paths until youve got this :

image=/mnt/tso/boot/vmlinuz-2.4.20-8

initrd=/mnt/tso/boot/initrd-2.4.20-8.img

Remember - because of the temporary mount of Red Hats root partition - the paths to the kernel etc have temporarily changed - so you have to modofy the paths in light of this - dont worry - LILO resolves all this behind the scenes.

Once youve succesfully edited lilo.conf in Debian then run the map installer as root

/sbin/lilo
 
Old 07-25-2003, 12:56 PM   #12
General_Tso
Member
 
Registered: Jan 2003
Location: New York, NY, USA
Distribution: Mac OS X (10.4.6), Ubuntu 6.06
Posts: 183

Original Poster
Rep: Reputation: 30
Skyline,

When I mount /dev/hda2 at /mnt/redhat, I can see the various directories of my Red Hat including /boot but there are no files contained within them. Still, I tried editting lilo.conf and got a "no such file or directory" message for /mnt/redhat/boot/vmlinuz-2.4.20-8.

What am I missing here?

Thanks,

GT
 
Old 07-25-2003, 02:54 PM   #13
Skyline
Senior Member
 
Registered: Jun 2003
Distribution: Debian/other
Posts: 2,104

Rep: Reputation: 45
Hi General tso

When you've mounted Red Hat's Root partition to /mnt/redhat in Debian are there any files at all in any of the Red Hat directories or is it just the case that there are no files in Red Hat's Boot directory.

When I Multiboot Linux distros - I only use a series of Root partitions and 1 Swap partition - I never use separate Boot partitions as the relevant kernal image is always contained within a little boot directory inside the respective root partition - in your scenario what might have happened is that because youve got a Boot, Root and Swap partition set up for Red Hat, maybe Red Hat has put the kernel etc into the separate boot partition - not into the boot directory of the root partition - this is only a guess.

That specific error message youve got implies that there is no kernel image in /mnt/redhat/boot - this might be explained by what Ive just said?

I would try your original idea again of mounting the entier Red Hat Boot partition to a mount point in Debians /mnt

So if your entire Red Hat boot partition was on /dev/hda1 and youve created /mnt/redhat in Debians /mnt then do

mount -t ext3 -o rw /dev/hda1 /mnt/redhat

Now - because you haven't got Red Hats root partition mounted you can't copy over Red Hats LILO settings so use these - there based on what youve posted before with a modiication or two.


image=/mnt/redhat/vmlinuz-2.4.20-8
label=RedHat9
root=/dev/hda2
initrd=/mnt/redhat/initrd-2.4.20-8.img
append="hdc=ide-scsi hdd=ide-scsi root=LABEL=/
read-only


Rememeber to save lilo.conf when youve put this in then as root user run

/sbin/lilo

re-post if your still having difficulty
 
Old 07-27-2003, 07:55 PM   #14
General_Tso
Member
 
Registered: Jan 2003
Location: New York, NY, USA
Distribution: Mac OS X (10.4.6), Ubuntu 6.06
Posts: 183

Original Poster
Rep: Reputation: 30
Skyline,

I mounted hda1 and saw all the files there, so I retried the process. I made the appropriate modifications without any problem, and it adds "RedHat9" and "DebianWoody." There is a little asterix next to RedHat9, however--I'm not sure if that's indicating that its the default or what. When I reboot, the results are the same: kernel panic.

Any ideas?

Thanks,

GT
 
Old 07-27-2003, 10:03 PM   #15
Skyline
Senior Member
 
Registered: Jun 2003
Distribution: Debian/other
Posts: 2,104

Rep: Reputation: 45
Hi General TSO

Yes - in your scenario - you'll need Red Hat's Boot partition mounted - (when multibooting I've got so used to just using a series of Root partitions and one Swap partition - thats why I was looking at the Root partition earlier - in hindsight in this scenario were youve got a Boot, Root and Swap partition for Red Hat - Red Hat has put its kernel image etc in the separate Boot partition /dev/hda1 - not in the boot directory of its Root partition - so yes - its the boot partition that needs to be mounted)

Can you post your lilo.conf file again - we're nearly there.

Just one last thing - did the Kernel Panic refer to a Root filesystem not being found/mounted ? - if so - and if youve got this line

root=/dev/hda2

in your Red Hat LILO entry - then take it out -


Last edited by Skyline; 07-27-2003 at 10:10 PM.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Multi Booting 4 separate Distros w/GRUB rickbman Linux - Distributions 5 05-14-2006 04:30 AM
Separate drives to install XP and Linux wxman2 SUSE / openSUSE 5 08-29-2005 02:45 PM
separate drives for Win-ME & Linux cellularhero Linux - Newbie 3 10-13-2004 11:22 PM
Dual-booting with two separate hard drives leeman_s Linux - General 3 01-22-2003 11:16 PM
how-to for using lilo to boot two separate drives jackopa Linux - General 4 04-19-2002 02:39 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 05:08 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration