LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware - Installation (http://www.linuxquestions.org/questions/slackware-installation-40/)
-   -   Adding a new system to the Slackware LILO boot loader & Please help me! (http://www.linuxquestions.org/questions/slackware-installation-40/adding-a-new-system-to-the-slackware-lilo-boot-loader-and-please-help-me-4175435521/)

Forget-Me-Not 11-04-2012 12:20 AM

Adding a new system to the Slackware LILO boot loader & Please help me!
 
I used Slackware 13.37 to install LFS in partition sda2 # ext3

My friend told me that:
"After you finish LFS you have an extra OS, which is completely independent from your host"

I need to boot into LFS.

I mean "Adding a new system to the Slackware LILO boot loader"

Thank you very much!

segmentation_fault 11-04-2012 04:11 AM

If you read /etc/lilo.conf you can figure out what to put there. Eg
Code:

image = /path/to/lfs/kernel
    initrd = /path/to/lfs/initrd
    root = /dev/sda2 # your lfs root partition
    label = <whatever you like to identify it>
    read-only

Also see man lilo.conf for more lilo options and tweaks.

Forget-Me-Not 11-04-2012 08:22 AM

There are 2 paths

In LFS environment
root:/boot# ls
config-3.5.2 System.map-3.5.2 vmlinuz-3.5.2-lfs-7.2


In Slackware
root@localhost:/boot# ls
README.initrd@ config@ slack.bmp
System.map@ config-generic-2.6.37.6 vmlinuz@
System.map-generic-2.6.37.6 config-generic-smp-2.6.37.6-smp vmlinuz-generic-2.6.37.6
System.map-generic-smp-2.6.37.6-smp config-huge-2.6.37.6 vmlinuz-generic-smp-2.6.37.6-smp
System.map-huge-2.6.37.6 config-huge-smp-2.6.37.6-smp vmlinuz-huge-2.6.37.6
System.map-huge-smp-2.6.37.6-smp diag1.img vmlinuz-huge-smp-2.6.37.6-smp
boot.0800 diag2.img
boot_message.txt map

I read on some documentations

Quote:

modify lilo.conf to point to the image

First, I cd over to /boot:

System.map chain.b module-info-2.2.16-3ext3
System.map-2.2.16-3 initrd-2.2.16-3.img vmlinux-2.2.16-3
System.map-2.2.16-3ext3 vmlinux-2.2.16-3ext3
vmlinuz kernel.h
boot.b map vmlinuz-2.2.16-3
module-info vmlinuz-2.2.16-3ext3 module-info-2.2.16-3



Here you can see that I have a 2.2.16-3 kernel and I have added a second kernel with ext3 support (vmlinuz-2.2.16-3ext3)

http://surfer.nmr.mgh.harvard.edu/pa...n/ramdisk.html

I don't know how to added a second kernel.
Hope you show me! Thank you very much!

colorpurple21859 11-04-2012 08:58 AM

Boot slackware, mount your lfs partition on /mnt edit the /etc/lilo.conf and add the following
Quote:

image = /mnt/boot/vmlinux-2.2.16-3ext3
root = /dev/sda2 # your lfs root partition
label = <whatever you like to identify it>
read-only
rerun lilo

Forget-Me-Not 11-04-2012 09:05 AM

This is my kernel vmlinuz-3.5.2-lfs-7.2 !

Please help me!

mariostg 11-04-2012 09:07 AM

Why don't you read either Slackware documentation or the LFS one instead of some outdated ones. The reference you used is from 2001. It will not work soon or later. Have you read what segmentation_fault suggested. Check the lilo conf section here http://docs.slackware.com/slackbook:...91;]=lilo#lilo

Fix your lilo.conf file, run lilo. If you have errors when running lilo, post back here with your lilo.conf

Forget-Me-Not 11-04-2012 10:27 AM

1 Attachment(s)
Attached file is my lilo.conf which was modified.
After modification, I pressed <Ctrl> O.
This is the first time I use nano. Thus I opened new Konsole and run lilo
The result
I couldn't add lfs. It's still old kernel.

Quote:

root@localhost:~# lilo -v
LILO version 22.8, Copyright (C) 1992-1998 Werner Almesberger
Development beyond version 21 Copyright (C) 1999-2006 John Coffman
Released 19-Feb-2007 and compiled at 03:08:28 on Mar 27 2011

Warning: LBA32 addressing assumed
Reading boot sector from /dev/sda
Using BITMAP secondary loader
Calling map_insert_data
Mapping bitmap file /boot/slack.bmp
Calling map_insert_file

Boot image: /boot/vmlinuz -> vmlinuz-huge-smp-2.6.37.6-smp
Added Linux *

Writing boot sector.
/boot/boot.0800 exists - no boot sector backup copy made.
One warning was issued.
root@localhost:~#

Hope you help me!

colorpurple21859 11-04-2012 06:20 PM

For your /etc/lilo.conf to work like it is you will have to copy the lfs kernel to Slackwares /boot then rerun lilo.

Forget-Me-Not 11-05-2012 01:44 AM

1 Attachment(s)
:cry:I copied 3 files
config-3.5.2 System.map-3.5.2 vmlinuz-3.5.2-lfs-7.2

to directory
root@localhost:/boot

It would be
Quote:

README.initrd@ config@ slack.bmp
System.map@ config-generic-2.6.37.6 vmlinuz@
System.map-generic-2.6.37.6 config-generic-smp-2.6.37.6-smp vmlinuz-generic-2.6.37.6
System.map-generic-smp-2.6.37.6-smp config-huge-2.6.37.6 vmlinuz-generic-smp-2.6.37.6-smp
System.map-huge-2.6.37.6 config-huge-smp-2.6.37.6-smp vmlinuz-huge-2.6.37.6
System.map-huge-smp-2.6.37.6-smp diag1.img vmlinuz-huge-smp-2.6.37.6-smp
boot.0800 diag2.img
boot_message.txt map
config-3.5.2 System.map-3.5.2 vmlinuz-3.5.2-lfs-7.2
run lilo -v
The result's okey. Added lfs *

Then I executed command-lines as following:
a)http://www.linuxfromscratch.org/lfs/...09/theend.html

b)http://www.linuxfromscratch.org/lfs/...09/reboot.html

Finally I rebooted computer. And the output is not as expectation. I kept it in attached file.

Might you help me? Thank you very much!

colorpurple21859 11-05-2012 05:35 AM

looks like your kernel is missing some drivers to boot correctly and/or you need to create an initrd. If you make an initrd you will need to copy it to the slackwares /boot and rerun lilo.

onebuck 11-05-2012 07:26 AM

Member Response
 
Hi,

@OP
If you do not have the newest LFS book then look at: www.linuxfromscratch.org/lfs/downloads/6.5/LFS-BOOK-6.5.pdf

EDIT: Current Book: LFS-BOOK-7.2.pdf

Plus beta Slackbook: http://slackbook.org/beta/#id342781

Slackware Doc Project is new documentation project that has loads of useful information.

Plus a few more;
Quote:

SlackwareŽ Linux Essentials <- Official Guide + 'Hacker Public Radio Interview with Alan Hicks Hosted by klaatu on 2009-06-29'
SlackwareŽ Basics <- 'SlackwareŽ Linux Basics is a book that aims to provide an introduction to SlackwareŽ Linux.' + The Slackware Linux Basics Translation Project + Download Page for available translations
Slackware-FAQ <- 'LQ Wiki'
SlackWiki Project <-- unofficial Slackware wiki; primarily maintained by regulars on ##slackware/freenode irc channel.
Slackers Bible 'Technical Manual For The People ... By the People' + stale1 +stale2
Cooking Up Some Slack. (CUSS) <- LQ Post 'Cooking Up Some Slack (or CUSS) is a website that explains how to make your own SlackwareŽ-based distribution.' + Additional read if you want to use SlackwareŽ 12.1 or >.

Above links are from SlackwareŽ-Links.

Forget-Me-Not 11-05-2012 11:50 AM

1 Attachment(s)
After I added

initrd = /boot/initrd

It look like more optimistic than the first. However it's still a my bug. Did you see it before which I kept it in attached file?
This one took me a long time. Hope me will receive your help to complete it! Thank you so much!

See you tomorrow. Good night!

colorpurple21859 11-06-2012 10:18 PM

add this line to the lfs entry
Code:

append = "root=/dev/sda?"
and rerun lilo. ? is your lfs partition number

Forget-Me-Not 11-08-2012 06:00 PM

Sorry!It still doesn't work! :(

markush 11-09-2012 09:08 AM

Hello,

I'd like to see the output of
Code:

fdisk -l
and
Code:

df -h
when Slackware is running. I would suggest to do the following, compile lilo for your LFS and install it, then configure it to install on the superblock of the partition where your LFS-boot directory is (where the kernel resides) and let this chainload from Slackware's lilo. This means to have lilo installed on both, Slackware and LFS. (that's what I would do).

Markus

BTW: maybe you'd be better off if you use Slackware for some month and get some experience with it. Then you're ready for LFS.


All times are GMT -5. The time now is 12:14 AM.