LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices

Reply
 
Search this Thread
Old 10-20-2004, 11:57 PM   #1
c31c
Member
 
Registered: Mar 2004
Location: Planet Earth
Distribution: Arch Linux
Posts: 106

Rep: Reputation: 15
Question Slack and other Distros: Multi Boot Questions


Hi
I've just installed Fedora Core 2, but without GRUB, as I don't know much about it and felt quite unsure. So after installing I just booted my working Slack, tried to change lilo.conf several times, but I only got the message that the FC kernel was not found.
Then I got the idea to just copy the FC kernel, System.map, initrd and config to my /boot directory, and it works.
But now I have some questions: Is there another way of adding other Linux distros under LILO? Are there any problems when I just copy the kernel?

Thanks
 
Old 10-21-2004, 03:32 AM   #2
justwantin
Member
 
Registered: Aug 2003
Location: Melbourne, Australia
Distribution: Slackware, Slackware ARM, Salix and Porteus
Posts: 551

Rep: Reputation: 43
You can boot any number of systems from lilo but lilo will be referencing the address of the /boot directory and root in relation to the filesystem of the system in which the /etc/lilo.conf resides and on which the command /sbin/lilo is run

For example consider the two lilo stanzas below from an /etc/lilo.conf on one of my machines. The first stanza is for booting the system on which my lilo.conf resides and from where I run /sbin/lilo. The kernel image is located in /boot. However, lilo has to find the kernel image for the other system on hda5 the path for which in the filesystem is /mnt/hda5. I have had as many as 4 linii plus windows booting in one box from two hardrives with lilo. I'm sure there's others who've done more.

If you have two separate kernel images available for the same system in the same /boot, your two stanzas would be identical except for the names of the image and maybe the addition of an initrd.gz for one of them. Sorry I don't have a ready example of this available for you.

image = /boot/vmlinuz-generic-2.6.7
initrd = /boot/initrd.gz
root = /dev/hda11
label = slack
vga = 791
read-only

image = /mnt/hda5/boot/vmlinuz
root = /dev/hda5
label = cb-slack
append = "devfs=mount hdc=ide-scsi"
vga = 791
read-only

Awhile back I did a long email to a friend to help him understand setting up lilo for dual booting and later I turned it into a sort of HowTo which you can find here if you need more of an explanation. http://members.optusnet.com.au/~rick...dual_boot.html

Cheers

Last edited by justwantin; 10-21-2004 at 03:34 AM.
 
Old 10-21-2004, 08:39 AM   #3
c31c
Member
 
Registered: Mar 2004
Location: Planet Earth
Distribution: Arch Linux
Posts: 106

Original Poster
Rep: Reputation: 15
thanks!
that's what I needed to know
SO i have to mount the partition my kernel is on first.
thanks a lot, your guides on your website are helpful, too
 
Old 10-21-2004, 03:16 PM   #4
justwantin
Member
 
Registered: Aug 2003
Location: Melbourne, Australia
Distribution: Slackware, Slackware ARM, Salix and Porteus
Posts: 551

Rep: Reputation: 43
From the statement below I'm not sure if you understand it correctly.

Quote:
SO i have to mount the partition my kernel is on first.
There is no partition order required except that if you dual boot with windows, it usually ends up in hda1 because thats where it likes to be. As far as lilo is concerned, it does not matter where other kernels are as long as they are in the /boot directory of the root files system of the system you want to boot. There can be be exceptions to that but not for what you want to do let's leave it at that.

So each stanza in lilo points to another kernel but not necessarily another partition and it does or doesn't matter the order in which the stanzas are placed. In the /etc/lilo.conf. example I gave you last night I actually reversed the order that they occurred in my config file as I thought it would be easier to understand.

However below is that complete /etc/lilo.config. Note that if I do not make a selection before timeout the default kernel (default = slack) will be used even though the stanza labeled as slack (label = slack) is listed second in the config file. If I did not nominate a default kernel the kernel listed in the first stanza (label = cb-slack) would be used by default.

boot=/dev/hda
vga=normal
default=slack
prompt
nowarn
timeout=100

image = /mnt/hda5/boot/vmlinuz
root = /dev/hda5
label = cb-slack
append = "devfs=mount hdc=ide-scsi"
vga = 791
read-only

image = /boot/vmlinuz-generic-2.6.7
initrd = /boot/initrd.gz
root = /dev/hda11
label = slack
vga = 791
read-only

Just to cover all bases lets say you had two kernels in the same /boot on the same partition and both could be used to boot into the same filesystem. The lilo.conf might look like this. Note that I have removed the "default =" declaration so that by default the first kernel listed, i.e. /boot/vmlinuz, is the default kernel.

boot=/dev/hda
vga=normal
prompt
nowarn
timeout=100

image = /boot/vmlinuz
root = /dev/hda5
label =slack
append = "devfs=mount hdc=ide-scsi"
vga = 791
read-only

image = /boot/vmlinuz-test
root = /dev/hda5
label = test
append = "devfs=mount hdc=ide-scsi"
vga = 791
read-only

This may have gotten a bit verbose. Before I settled down with Slack, I was installing every linux that came down the pike. Multi-booting frustrated me no end until I got it right in my head. Maybe this will eliminate you going through the same pain I did.
 
Old 10-21-2004, 08:39 PM   #5
c31c
Member
 
Registered: Mar 2004
Location: Planet Earth
Distribution: Arch Linux
Posts: 106

Original Poster
Rep: Reputation: 15
thanks a lot, but I guess I already got it.
I haven't tried out yet though.

Now my lilo.conf looks like that (approx., I'm on Win now, can't check...):

boot=/dev/hda
vga=normal
default=WindowsXP
prompt
timeout=30

image = /boot/vmlinuz //link to vmlinuz-2.6.8.1
root = /dev/hdb5
label = Slackware_10_2.6.8
vga = 791
read-only

image = /boot/vmlinuz-2.4.26
root = /dev/hdb5
label = Slackware_10_2.4.26
vga = 791
read-only

image = /boot/vmlinuz-something-Fedora //sorry forgot
initrd = /boot/initrd-something-Fedora.gz
root = /dev/hdb7
label = FC2
read-only

other = /dev/hda1
table = /dev/hda
label = WindowsXP


I guess that's it.
So I already knew what you said about order and stuff, the only thing I didn't know was that just

image = /boot/vmlinuz-something-Fedora //sorry forgot
initrd = /boot/initrd-something-Fedora.gz
root = /dev/hdb7
label = FC2
read-only

won't work when I don't have that kernel in my slack /boot....
In other words, I thought that lilo would "look" at the root specified partition and look in the /boot it finds there and look for the kernel there.

So if I got everything right, mounting FC2 on e.g. /mnt/fc2 and changing lilo.conf to

image = /mnt/fc2/boot/vmlinuz-something-Fedora //sorry forgot
initrd = /mnt/fc2/boot/initrd-something-Fedora.gz
root = /dev/hdb7
label = FC2
read-only

will work, eh?!

sorry for that confusing text, 3:41 right now....
but thanks a lot for helping me
 
Old 10-22-2004, 05:28 AM   #6
justwantin
Member
 
Registered: Aug 2003
Location: Melbourne, Australia
Distribution: Slackware, Slackware ARM, Salix and Porteus
Posts: 551

Rep: Reputation: 43
Quote:
will work, eh?!
I don't think so..................but maybe I missed something.

How many hard drives do you have in that box? If you only have 1 then your windows would be on hda1 and everything else would be from hda5 onwards. If you have 2 then hdb it is but what do you have on hdb1 out of curiosity/

Do all those kernels reside in the same /boot directory? Do you plan on booting the Fedora kernel from inside a slackware system. If not, you shouldn't be saying its in /boot if your Fedora / is on /dev/hdb7. Where do you mount the Fedora / filesystem if you are running lilo from slackware and slackware / is on is on hdb5

As an educational experience, as root run lilo -v 3 so that it will give you a more verbose error output. You will be given line numbers (about) where there is a problem. Step through the problems.

From experience I found it better not to stay up late on a computer or drink beer when doing something serious on an internal combustion engine.

Last edited by justwantin; 10-22-2004 at 05:29 AM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
multi-boot questions cwhh Fedora - Installation 4 09-17-2005 07:28 PM
doubt regarding boot loader while installing multi distros b0nd Linux - Newbie 2 09-07-2005 12:49 PM
Is there a limit to number of distros I can multi boot? glenn69 Linux - Newbie 1 10-12-2004 02:50 PM
Need help with boot loader. Multi boot questions. Grub? 1993gt40 Linux - Software 1 10-16-2003 08:28 PM
best order to install distros in multi-boot yowwww Linux - General 5 05-12-2003 11:32 PM


All times are GMT -5. The time now is 09:42 PM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration