LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   Kernel recompile, LILO warning and Kernel-panic (https://www.linuxquestions.org/questions/slackware-14/kernel-recompile-lilo-warning-and-kernel-panic-575822/)

Tux-Slack 08-09-2007 02:47 AM

Kernel recompile, LILO warning and Kernel-panic
 
I'm having trouble with compiling my own kernel(2.6.22.1 to be exact). I download the source, extract it to /usr/src, fix /usr/src/linux symlink to point to the new kernel tree, copy .config from old (Slack12 original)kernel to my new kernel, run make menuconfig to add some ACPI stuff to it and compile, make returns no errors, so doesn't make modules_install, but then I run make install witch installs the kernel corectly only LILO returns an warning:
Code:

root@xendria:~# lilo
Warning: LBA32 addressing assumed
Added Linux *
One warning was issued.

And this is my /etc/lilo.conf :
Code:

# LILO configuration file
# generated by 'liloconfig'
#
# Start LILO global section
boot = /dev/hda2
#compact        # faster, but won't work on all systems.
prompt
#timeout = 300
# VESA framebuffer console @ 1024x768x256
vga = 773
# Normal VGA console
# vga = normal
# VESA framebuffer console @ 1024x768x64k
# vga=791
# VESA framebuffer console @ 1024x768x32k
# vga=790
# VESA framebuffer console @ 1024x768x256
# vga=773
# VESA framebuffer console @ 800x600x64k
# vga=788
# VESA framebuffer console @ 800x600x32k
# vga=787
# VESA framebuffer console @ 800x600x256
# vga=771
# VESA framebuffer console @ 640x480x64k
# vga=785
# VESA framebuffer console @ 640x480x32k
# vga=784
# VESA framebuffer console @ 640x480x256
# vga=769
# ramdisk = 0    # paranoia setting
# End LILO global section
# Linux bootable partition config begins
image = /boot/vmlinuz
  root = /dev/hda2
  label = Linux
  read-only # Non-UMSDOS filesystems should be mounted read-only for checking

Well then when I reboot I get an error that it cant mount /dev/hda2 and has tried with XFS(although hda2 is Ext3) and complains something about a block at (3,2) and then Kernel-panic.

LILO is located/installed on hda2 not on MBR.
And I really don't have any idea what's going on.

mattydee 08-09-2007 10:18 AM

Did you make sure that the ext3 filesystem was compiled into the kernel and not as a module?
You will need an initrd if ext3 was compiled as a module.

Also, are you saying you did or didn't do make modules_install?

bioe007 08-09-2007 10:32 AM

i like this way:
Code:

$make menuconfig # change options, especially compile in fs support
$make bzImage && make modules
#su
Password:
#make modules_install
#cp arch/i386/boot/bzImage /boot/bzImage-2.6.22.1
#cp System.map /boot/System.map-2.6.22.1
#rm /boot/System.map && ln -s /boot/System.map-2.6.22.1 /boot/System.map
#vi /etc/lilo.conf  # add my new entry
#/sbin/lilo

If you don't get any errors from that, but it still won't boot, you haven't compiled in your fs support or '/' device drivers.
You can recompile with these things built in, or make an initrd for fs support.
Code:

#mkinitrd -c -k 2.6.22.1 -m jbd:ext3 -o /boot/initrd-2.6.22.1.gz
#ln -s /boot/initrd-2.6.22.1.gz /boot/initrd.gz

then edit lilo.conf and add this line:
Code:

initrd=/boot/initrd.gz
IMO I would also not rely on a single lilo.conf entry. Its very helpful to leave at least your last known good kernel around as the vmlinuz and just add new entries, that way you can (theoretically) always boot.

hth

Tux-Slack 08-09-2007 02:08 PM

Quote:

Originally Posted by mattydee
Did you make sure that the ext3 filesystem was compiled into the kernel and not as a module?
You will need an initrd if ext3 was compiled as a module.

Also, are you saying you did or didn't do make modules_install?

So that was the problem?
I've checked the File Systems part in te menu again and ext3 was compiled as module yes, and no I didn't have a initrd, but I did make modules_install
I've compiled ext3 fs support not as a module, I'll reboot and report. Thank you.

MannyNix 08-09-2007 02:48 PM

:twocents:
Sometimes it doesn't hurt to do
Code:

make mrproper
inside the /usr/src/linux (this will also delete any .config* or changes you may have) Then after the make mrproper, cp .config (a working one) to /usr/src/linux and make menuconfig or make oldconfig (if using an older kernel version).
LFS recomends make mrproper:
Quote:

This ensures that the kernel tree is absolutely clean. The kernel team recommends that this command be issued prior to each kernel compilation. Do not rely on the source tree being clean after un-tarring.
http://www.linuxfromscratch.org/lfs/...08/kernel.html
again, my :twocents:
Btw i have a similar lilo warning, still not sure how to fix it:
Code:

  /sbin/lilo
Warning: LBA32 addressing assumed
/proc/misc: No entry for device-mapper found
Is device-mapper driver missing from kernel?
Failure to communicate with kernel device-mapper driver.


onebuck 08-09-2007 03:16 PM

Quote:

Originally Posted by mannyslack
:twocents:
Sometimes it doesn't hurt to do
Code:

make mrproper
inside the /usr/src/linux (this will also delete any .config* or changes you may have) Then after the make mrproper, cp .config (a working one) to /usr/src/linux and make menuconfig or make oldconfig (if using an older kernel version).
LFS recomends make mrproper:
http://www.linuxfromscratch.org/lfs/...08/kernel.html
again, my :twocents:
Btw i have a similar lilo warning, still not sure how to fix it:
Code:

  /sbin/lilo
Warning: LBA32 addressing assumed
/proc/misc: No entry for device-mapper found
Is device-mapper driver missing from kernel?
Failure to communicate with kernel device-mapper driver.


Hi,

Quote:

excerpt from one of my '/etc/lilo.conf';

# LILO configuration file
# generated by 'liloconfig'
#
# Start LILO global section
boot = /dev/hda
message = /boot/boot_message.txt
prompt
timeout = 50
lba32
compact

#default boot
default = Linux

menu-title=" Willi's Computer "

Notice the lba32 in the global section of the '/etc/lilo.conf' file.

Quote:

excerpt from 'man lilo.conf'

lba32 Generate 32-bit Logical Block Addresses instead of cylin-
der/head/sector addresses. If the BIOS supports packet address-
ing, then packet calls will be used to access the disk. This
allows booting from any partition on disks with more than 1024
cylinders. If the BIOS does not support packet addressing, then
'lba32' addresses are translated to cylinder/head/sector ('geo-
metric'), just as for 'linear'. All floppy disk references are
retained in C:H:S form. Use of 'lba32' is recommended on all
post-1998 systems. Beginning with LILO version 22, 'lba32' is
the default disk addressing scheme.
The 'man lilo.conf' explains it very well.

MannyNix 08-09-2007 03:39 PM

Thanks onebuck, i don't wanna hijack this thread; i added lba32 compact, but still the same. Maybe something wrong w/kernel .config. Will keep and eye in here and here
Anyway i still left lba32 & compact in lilo.conf, Thanks again

onebuck 08-09-2007 03:48 PM

Quote:

Originally Posted by mannyslack
Thanks onebuck, i don't wanna hijack this thread; i added lba32 compact, but still the same. Maybe something wrong w/kernel .config. Will keep and eye in here and here
Anyway i still left lba32 & compact in lilo.conf, Thanks again

Hi,

What about your BIOS? It sounds like a geometric problem. Is your BIOS current?

wadsworth 08-09-2007 05:45 PM

When you put the .config from 2.6.21.5 into the 2.6.22.1 directory,
did you run "make oldconfig" first thing?

Also, have a look at /boot/README.initrd
I had to make an initrd.gz to get my 2.6.21.7 slimmed-down kernel to boot.

Good info on lba32, I was wondering about that myself.

Tux-Slack 08-10-2007 04:59 AM

The kernel works, but I'm stuck with 2.6.21.5 still because I have trouble finding a working rt2500 driver. When I compile it I always get that "mac" is not a member of some struct, forgot the name, but when if I comment out the line where it calls for mac from that struct the driver just doesn't work later. Oh well. Will try to download newer version and play with it a bit more, but problem in this thread was solved. Thank you everyone.

*************
Edit:
Fix that problem as well.

onebuck 08-10-2007 05:54 AM

Hi,

Quote:

Originally Posted by Tux-Slack
Oh well. Will try to download newer version and play with it a bit more, but problem in this thread was solved. Thank you everyone.

*************
Edit:
Fix that problem as well.

Could you tell us which problem was solved and how? So the post can be brought to a close. An possibly help someone else with the information from you for the solution.

Tux-Slack 08-10-2007 05:57 AM

The problem with the kernel-panic. Because I didn't compile ext3 support into the kernel, but I've compiled it as a module and didn't create a initrd.
But when I've fixed that my rt2500 Wireless driver wouldn't build, so I downloaded the newest daily-CVS package from http://rt2x00.serialmonkey.com and compiled it, installed it and now I'm loving it.

MannyNix 08-10-2007 06:29 PM

Well, since it seems op Tux-Slack solved his problem...

@onebuck:
Quote:

Originally Posted by onebuck
Hi, What about your BIOS? It sounds like a geometric problem. Is your BIOS current?

It was some years old! as a matter of fact, it had never been updated! I read some howtos in a hurry but all needed a floppy disk, which i don't have atm, so i had to use a cd that came with the mobo from (yuck) xp... The problem persisted after bios upgrade, but i'm glad i did it.
No more lba32 issues, but still the:
Code:

/proc/misc: No entry for device-mapper found
Is device-mapper driver missing from kernel?
Failure to communicate with kernel device-mapper driver.

It ended up being that i had compiled it as a module instead of being built in the kernel, so for anybody with the same issue:
Code:

Device Drivers -> Multi-device support (RAID and LVM) -> Device mapper support
Thank you :)

onebuck 08-11-2007 07:49 AM

Quote:

Originally Posted by mannyslack
Well, since it seems op Tux-Slack solved his problem...

@onebuck:

It was some years old! as a matter of fact, it had never been updated! I read some howtos in a hurry but all needed a floppy disk, which i don't have atm, so i had to use a cd that came with the mobo from (yuck) xp... The problem persisted after bios upgrade, but i'm glad i did it.
No more lba32 issues, but still the:
Code:

/proc/misc: No entry for device-mapper found
Is device-mapper driver missing from kernel?
Failure to communicate with kernel device-mapper driver.

It ended up being that i had compiled it as a module instead of being built in the kernel, so for anybody with the same issue:
Code:

Device Drivers -> Multi-device support (RAID and LVM) ->
Code:

Device mapper support
Thank you :)

Hi,

Glad too see you got it up and flying. I like to document everything that I do for any system that I work on. That way I have a trail to backtrack when needed. Unlike a computer that has a memory failure mine doesn't get replaced easily.

petcherd 08-15-2007 06:06 PM

more thread hijaaking
 
Slackware 12: I'm compiling a kernel with no support at all (intentionally) for RAID or LVM. I get this when I run lilo:
Code:

/proc/misc: No entry for device-mapper found
Is device-mapper driver missing from kernel?

but I don't get your "Failure to communicate with kernel device-mapper driver." error.

Should I do anything to remove this spurious warning?


All times are GMT -5. The time now is 11:00 PM.