LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 06-22-2008, 10:16 PM   #1
trist007
Senior Member
 
Registered: May 2008
Distribution: Slackware
Posts: 1,033

Rep: Reputation: 69
I need help configuring LILO


I installed windows xp professional on sda1. Then I installed Fedora 8 on sda5. sda2 is the /boot, sda 3 is the extended, and sda4 is the swap file.

Then I installed backtrack2 on sda6. For some reason, a complete copy of sda6 is made into sda6_1 when I view them in Konqueror. Anyhow, here is my lilo.conf


boot = /dev/sda
bitmap=/boot/splash.bmp
prompt
timeout = 20
vga = 0x317
default=WindowsXP
image = /boot/vmlinuz
root = /dev/sda6
initrd = /boot/splash.initrd
label = Backtrack2
read-only
other=/dev/sda1
label=WindowsXP
other=/dev/sda2
label=Fedora


I want to be able to get a menu to boot to winxp, fedora, or backtrack2. With this .conf I go straight to backtrack2 with no menu options. What should I do?

Each time I installed a new OS I overwrote the MBR on dev/sda

Last edited by trist007; 06-22-2008 at 10:32 PM.
 
Old 06-23-2008, 12:01 AM   #2
kilgoretrout
Senior Member
 
Registered: Oct 2003
Posts: 2,532

Rep: Reputation: 210Reputation: 210Reputation: 210
The first thing to do is change this line:

timeout = 20

to this:

timeout = 200

The times in lilo.conf are give in tenths of a second so a timeout of 20 is actually 2 seconds. I think that is just too fast for you to get into the menu. By the time you see it, lilo times out and tries to go straight into the default, "WindowsXP", which is not properly configured if I'm not mistaken. I think your windows entry should look like this:

other=/dev/sda1
label=WindowsXP
table=/dev/sda

instead of just:

other=/dev/sda1
label=WindowsXP

so just add the table=/dev/sda line per the above.

Make the above changes to lilo.conf and then open a console, su to root and run:

# lilo -v

to write the changes to the mbr. Reboot and see if your menu entries work.
 
Old 06-23-2008, 01:19 AM   #3
trist007
Senior Member
 
Registered: May 2008
Distribution: Slackware
Posts: 1,033

Original Poster
Rep: Reputation: 69
Thanks man it's working better, just need to work out a few more kinks. Here's my lilo.conf now

boot=/dev/sda
bitmap=/boot/splash.bmp
prompt
timeout=50
vga=0x317
default=WindowsXP
image=/boot/vmlinuz
root=current
initrd=/boot/splash.initrd
label=Backtrack2
read-only
other=/dev/sda1
label=WindowsXP
table=/dev/sda
other=/dev/sda4
initrd=/boot/initrd-2.6.25.6-27.fc8.img
label=Fedora(2.6.25.6-27.fc8)
table=/dev/sda

Can I change the bitmap to whatever pic I want?
How do I add spaces to WindowsXP to make it Windows XP? I tried with spaces and with quotations but I get an error after running lilo -v in console

Also, I'm having trouble starting Fedora, I get an error on the initrd= line. What goes there? Anything else I need?
Thanks again.
 
Old 06-23-2008, 08:30 AM   #4
trist007
Senior Member
 
Registered: May 2008
Distribution: Slackware
Posts: 1,033

Original Poster
Rep: Reputation: 69
I'm having trouble getting the Fedora to boot.
It seems that sda2 is the boot partition, sda3 is the swap.
sda4 is the extended and sda5 is the / partition for Fedora. Here's my lilo.conf

boot=/dev/sda
bitmap=/boot/splash.bmp
prompt
timeout=50
vga=0x317
default=WindowsXP
image=/boot/vmlinuz
root=current
initrd=/boot/splash.initrd
label=Backtrack2
read-only
other=/dev/sda1
label=WindowsXP
table=/dev/sda
other=/dev/sda5
image=/boot/vmlinuz-2.6.25.6-27
initrd=/boot/initrd-2.6.25.6-27.fc8.img
label=Fedora(2.6.25.6-27.fc8)
table=/dev/sda

I use Konqueror to view the partitions. For some reason sda4 isn't mounted and I can't mount it because it's an extended partition. So I did some reading and ppl say not to mount the extended partitions but to mount the logical ones. So now I take a look at sda5, the / Fedora partition. For some reason the /boot dir in sda5 is empty. Was this because when LILO overwrote the MBR it deleted grub along with all the initrd and images? So how would I boot to Fedora? Well, the lilo.conf above gives me errors saying

Boot other: /dev/sda5, loader CHAIN
Fatal: First sector of /dev/sda5 doesn't have a valid boot signature

I also put the image and initrd from another computer with the same versions, but it doesn't work. I noticed that when I use other=/dev/sda4 for the Fedora option it says

Boot other: /dev/sda4, on /dev/sda, loader CHAIN
Added sda4

Boot image: /boot/vmlinuz-2.6.25.6-27
Fatal: open /boot/vmlinuz-2.6.25.6-27: No such file or directory

So it seems I need to add the image and initrd to this /boot dir in sda4, but since sda4 is an extended partition, I can't mount it. What do I do?
Thanks in advance.
 
Old 06-23-2008, 08:41 AM   #5
trist007
Senior Member
 
Registered: May 2008
Distribution: Slackware
Posts: 1,033

Original Poster
Rep: Reputation: 69
Here's my original lilo.conf right after I installed backtrack2


boot = /dev/sda
prompt
timeout = 20
bitmap=/boot/splash.bmp
change-rules
reset
vga = 0x317
image = /boot/vmlinuz
root = current
initrd = /boot/splash.initrd
label = bt
read-only

I took out reset and change-rules. What do they do exactly? I checked out examples online and none had them so that's why I took them out. Also, the first line was blank, is there a reason for the first line being blank and starting the boot=/dev/sda on the 2nd line?
 
Old 06-23-2008, 08:13 PM   #6
kilgoretrout
Senior Member
 
Registered: Oct 2003
Posts: 2,532

Rep: Reputation: 210Reputation: 210Reputation: 210
Just working with the fedora section:

other=/dev/sda5
image=/boot/vmlinuz-2.6.25.6-27
initrd=/boot/initrd-2.6.25.6-27.fc8.img
label=Fedora(2.6.25.6-27.fc8)
table=/dev/sda

This looks like a real mess. You are mixing up chain loading concepts with standard lilo configuration methods. Basically, what you first have to determine is the path to the fedora vmlinuz and initrd.img as seen from Backtrack. To properly state that path, you need to have an entry in the Backtrack /etc/fstab for the boot partition of fedora which you indicate is sda2. Just to illustrate, let's assume that sda2 is formatted ext3 and Backtrack is to be configured to mount sda2 on /mnt/sda2. Then the fstab entry for sda2 in Backtrack would look like something like this:

/dev/sda2 /mnt/sda2 ext3 defaults 1 2

Your path to the fedora vmlinuz and initrd.img from Backtrack's point of view would be through that mount point, /mnt/sda2/boot/vmlinuz-2.6.25.6-27 and /mnt/sda2/boot/initrd-2.6.25.6-27.fc8.img.

Given this data, your lilo.conf entry for fedora would be:

image=/mnt/sda2/boot/vmlinuz-2.6.25.6-27
root=/dev/sda5
initrd=/mnt/sda2/boot/initrd-2.6.25.6-27.fc8.img
label=Fedora(2.6.25.6-27.fc8)
read-only

So your new lilo.conf would read after apporpriate editing and adding a little white space to make it more readable:

boot=/dev/sda
bitmap=/boot/splash.bmp
prompt
timeout=50
vga=0x317
default=WindowsXP

image=/boot/vmlinuz
root=current
initrd=/boot/splash.initrd
label=Backtrack2
read-only

other=/dev/sda1
label=WindowsXP
table=/dev/sda

image=/mnt/sda2/boot/vmlinuz-2.6.25.6-27
root=/dev/sda5
initrd=/mnt/sda2/boot/initrd-2.6.25.6-27.fc8.img
label=Fedora(2.6.25.6-27.fc8)
read-only

After making these edits on lilo.conf and before running lilo -v to write them to the mbr, you have to mount sda2 or lilo -v will give an error as it won't be able to find fedora's vmlinuz or initrd.img if sda2 is not mounted.

Last edited by kilgoretrout; 06-24-2008 at 01:31 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
Configuring Lilo? Ricky2004 Linux - Software 5 05-06-2005 04:15 PM
Configuring Lilo Brad4321 Linux - Newbie 6 09-26-2004 11:11 AM
configuring lilo ksd Slackware 30 10-14-2003 10:49 AM
Configuring LILO NiallC Linux - Software 9 07-04-2003 01:39 PM
Configuring LILO iqlinux Linux - Software 7 01-31-2001 11:53 PM


All times are GMT -5. The time now is 03:52 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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration