LinuxQuestions.org
Help answer threads with 0 replies.
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 04-28-2003, 05:01 AM   #1
fishsponge
Member
 
Registered: Apr 2003
Location: Cambridge, UK
Distribution: Debian/Solaris
Posts: 147

Rep: Reputation: 15
Question HELP!! Kernel install gone wrong...


Hello,

I have a debian machine at home, that was running the 2.4.18-bf2.4 kernel about 20 minutes ago. I decided i needed to upgrade it to 2.4.20-1-686. Here's my processor, according to 'cpuid':
Code:
hobbs@turnip:~$ cpuid
 eax in    eax      ebx      ecx      edx
00000000 00000002 756e6547 6c65746e 49656e69
00000001 00000633 00000000 00000000 0080fbff
00000002 03020101 00000000 00000000 0c040843

Vendor ID: "GenuineIntel"; CPUID level 2

Intel-specific functions:
Version 00000633:
Type 0 - Original OEM
Family 6 - Pentium Pro
Model 3 - Pentium II Model 3
Stepping 3
Reserved 0
Have i chosen the right kernel? I just won't boot up again, and i currently am unable to get to the machine physically to check anything. i installed the "kernel-image-2.4.20-1-686" package through dselect (apt).

It did ask me a question that i wasn't sure about though... so this is where i think i went wrong:
Code:
You are attempting to install an initrd kernel image (version 2.4.20-1-686)
This will not work unless you have configured your boot loader to use
initrd. (An initrd image is a kernel image that expects to use an INITial 
Ram Disk to mount a minimal root file system into RAM and use that for
booting).
As a reminder, in order to configure lilo, you need to
add an 'initrd=/initrd.img' to the image=/vmlinuz
stanza of your /etc/lilo.conf
I repeat, You need to configure your boot loader. If you have already done
so, and you wish to get rid of this message, please put
  `do_initrd = Yes'
in /etc/kernel-img.conf. Note that this is optional, but if you do not, 
you'll contitnue to see this message whenever you install a kernel 
image using initrd.
Do you want to stop now? [Y/n]
I answered N to this (obviously) and it went through and installed everything. It then tested '/etc/lilo.conf' and said it was ok. I then typed "reboot" and waited.........

nothing. still unpingable 10 minutes later! i think it's broken

i added "initrd=/initrd.img" to lilo.conf as it told me to, before the reboot:
Code:
# Boot up Linux by default.
# 
default=Linux

image=/vmlinuz
        label=Linux
        read-only
#       restricted
#       alias=1
        initrd=/initrd.img

image=/vmlinuz.old
        label=LinuxOLD
        read-only
        optional
#       restricted
#       alias=2
i cannot figure out what's gone wrong here! Can someone help?? has anyone experienced this same problem before? What caused it? What do i need to do to fix it?

i will start investigating as soon as i can get to the machine physically, but i would like to have a clue about what's gone wrong before i start messing around.

Thanks in advance for any help... it's much appreciated.
 
Old 04-28-2003, 05:50 AM   #2
Mik
Senior Member
 
Registered: Dec 2001
Location: The Netherlands
Distribution: Ubuntu
Posts: 1,316

Rep: Reputation: 47
Well the initrd should be pointing to an initial ramdisk image. You don't really need it if you compiled all the necessary things needed for booting directly into the kernel (not as modules). You can disable it by turning off the option CONFIG_BLK_DEV_INITRD.

The easiest thing to do when compiling a new kernel is to copy the .config file from your old kernel and then run 'make oldconfig'
That way you keep at least all the old options of your previous kernel.
 
Old 04-28-2003, 05:51 AM   #3
whansard
Senior Member
 
Registered: Dec 2002
Location: Mosquitoville
Distribution: RH 6.2, Gen2, Knoppix,arch, bodhi, studio, suse, mint
Posts: 3,304

Rep: Reputation: 65
i think you installed the wrong kernel for what you want.
the initrd it is talking about is one it expects you already
made. not one that just happens to exist on systems.
 
Old 04-28-2003, 05:58 AM   #4
fishsponge
Member
 
Registered: Apr 2003
Location: Cambridge, UK
Distribution: Debian/Solaris
Posts: 147

Original Poster
Rep: Reputation: 15
Quote:
Originally posted by Mik
Well the initrd should be pointing to an initial ramdisk image. You don't really need it if you compiled all the necessary things needed for booting directly into the kernel (not as modules). You can disable it by turning off the option CONFIG_BLK_DEV_INITRD.

The easiest thing to do when compiling a new kernel is to copy the .config file from your old kernel and then run 'make oldconfig'
That way you keep at least all the old options of your previous kernel.
I didn't compile a new kernel... i just downloaded the kernel-image from apt. It's precompiled for 686 systems, which is what mine is apparently.

As you said i don't really need it, does that mean where it said to add that line to lilo.conf, i didn't really need to??

Quote:
Originally posted by whansard
i think you installed the wrong kernel for what you want.
the initrd it is talking about is one it expects you already
made. not one that just happens to exist on systems.
i see your point.... so which kernel do i want to install then?? i would like to upgrade to 2.4.20, and move away from the bf2.4 kernel.
 
Old 04-28-2003, 06:54 AM   #5
Mik
Senior Member
 
Registered: Dec 2001
Location: The Netherlands
Distribution: Ubuntu
Posts: 1,316

Rep: Reputation: 47
Well I don't use debian. But if they provide a precompiled kernel with initrd enabled they should also provide a initrd image file along with it. In that case you should make then entry in lilo.conf point to the file. Usually it would be in the /boot directory.
Or you should see if they have any kernels without it since your last kernel apparently was also without that option.

You could always install a 2.4.20 kernel which you compiled yourself. I don't know if debian contains source packages for their kernel but you might want to at least get a .config file to start with. After that you can always enable/disable things yourself. It's easier to base it off a config file you know that works and then go from there then going through each option and deciding whether you need it or not. Unless you know what you are doing.

PS: And are you running /sbin/lilo after changing lilo.conf. Because if lilo is at least a bit decent it should complain about not finding a /initrd.img file, unless it's really there (which IMO is kinda messy).

Last edited by Mik; 04-28-2003 at 06:57 AM.
 
Old 04-28-2003, 07:44 AM   #6
fishsponge
Member
 
Registered: Apr 2003
Location: Cambridge, UK
Distribution: Debian/Solaris
Posts: 147

Original Poster
Rep: Reputation: 15
debian do supply source packages, but i've never ever managed to compile a kernel myself *and* get it to boot, so i'm only gonna try that as a last resort.

i think i've figured out what's happened here.... previously, i was using "2.4.18-bf2.4", and i downloaded and installed "2.4.20-1-686". As we can see below, there a a load of kernels with "1" in them (e.g. kernel-image-2.4.20-1-686) and loads without (e.g. kernel-image-2.4.20-686).
Code:
kernel-image-2.4.20-1-386 - Linux kernel image for version 2.4.20 on 386.
kernel-image-2.4.20-1-586tsc - Linux kernel image for version 2.4.20 on Pentium-Classic.
kernel-image-2.4.20-1-686 - Linux kernel image for version 2.4.20 on PPro/Celeron/PII/PIII/PIV.
kernel-image-2.4.20-1-686-smp - Linux kernel image for version 2.4.20 on PPro/Celeron/PII/PIII/PIV SMP.
kernel-image-2.4.20-1-k6 - Linux kernel image for version 2.4.20 on AMD K6/K6-II/K6-III.
kernel-image-2.4.20-1-k7 - Linux kernel image for version 2.4.20 on AMD K7.
kernel-image-2.4.20-1-k7-smp - Linux kernel image for version 2.4.20 on AMD K7 SMP.
kernel-image-2.4.20-386 - Linux kernel image for version 2.4.20 on 386.
kernel-image-2.4.20-586tsc - Linux kernel image for version 2.4.20 on Pentium-Classic.
kernel-image-2.4.20-686 - Linux kernel image 2.4.20 on PPro/Celeron/PII/PIII/PIV.
kernel-image-2.4.20-686-smp - Linux kernel image 2.4.20 on PPro/Celeron/PII/PIII/PIV SMP.
kernel-image-2.4.20-bf2.4 - Linux kernel image for version 2.4.20 (bf2.4 variant)
kernel-image-2.4.20-k6 - Linux kernel image for version 2.4.20 on AMD K6/K6-II/K6-III.
kernel-image-2.4.20-k7 - Linux kernel image for version 2.4.20 on AMD K7.
kernel-image-2.4.20-k7-smp - Linux kernel image for version 2.4.20 on AMD K7 SMP.
For some strange reason unknown to me, i installed "kernel-image-2.4.20-1-686", but i think i should have installed "kernel-image-2.4.20-686". Does that seem like the solution??

Last edited by fishsponge; 04-28-2003 at 07:49 AM.
 
Old 04-28-2003, 07:51 AM   #7
fishsponge
Member
 
Registered: Apr 2003
Location: Cambridge, UK
Distribution: Debian/Solaris
Posts: 147

Original Poster
Rep: Reputation: 15
my friend just tried installing "kernel-image-2.4.20-686" to test this theory, but it asks for "inetrd" as well. He has now backed out of making the changes.
 
Old 04-28-2003, 08:12 AM   #8
crashmeister
Senior Member
 
Registered: Feb 2002
Distribution: t2 - trying to anyway
Posts: 2,541

Rep: Reputation: 47
I never apt-get'ed a kernel for Debian but my best guess is that it puts a initrd.img in the /boot directory.You should look in there and see if it is there and what it is actually called - probably something like initrd2.4.20.img.Then try to add initrd=/boot/initrd-whatever.img to lilio.
 
Old 04-28-2003, 08:33 AM   #9
fishsponge
Member
 
Registered: Apr 2003
Location: Cambridge, UK
Distribution: Debian/Solaris
Posts: 147

Original Poster
Rep: Reputation: 15
i'm going to try that as soon as i can physically get to the machine, and find a keyboard and monitor to plug into it! lol

i'm pretty sure i'm going to see a kernel panic when i get home, but i'm not sure yet.

What's the difference between the kernel-image-2.4.20-1-686 and the kernel-image-2.4.20-686 packages?? The '1' must mean something, but i don't know what...

why does neither my old kernel (2.4.18-bf2.4) or my friends kernel (2.4.18-grsec-1.9.4) require initrd, but the 2.4.20 kernel does? is it a module that i don't actually need? or is it just how the new kernel works?
 
Old 04-28-2003, 09:09 AM   #10
crashmeister
Senior Member
 
Registered: Feb 2002
Distribution: t2 - trying to anyway
Posts: 2,541

Rep: Reputation: 47
I usually don't use initrd.As far as I know it is mainly used to load drivers that you need for booting before the kernel is operational like scsi drivers.It's mainly useful for kernels from distros where the drivers for the hdd's are built as modules that need to be loaded in order to boot the system.If you make your own kernel and compile the drivers for in the kernel and not as modules you don't need it.
Something like that anyway.
 
Old 04-28-2003, 09:13 AM   #11
fishsponge
Member
 
Registered: Apr 2003
Location: Cambridge, UK
Distribution: Debian/Solaris
Posts: 147

Original Poster
Rep: Reputation: 15
ok, gotcha.... but i still don't know what the number 1 means in the kernel package name... any ideas anyone??

also, do you know which of these i need? i do not want to include initrd, as i do not need it:
Code:
kernel-image-2.4.20-1-386 - Linux kernel image for version 2.4.20 on 386.
kernel-image-2.4.20-1-586tsc - Linux kernel image for version 2.4.20 on Pentium-Classic.
kernel-image-2.4.20-1-686 - Linux kernel image for version 2.4.20 on PPro/Celeron/PII/PIII/PIV.
kernel-image-2.4.20-1-686-smp - Linux kernel image for version 2.4.20 on PPro/Celeron/PII/PIII/PIV SMP.
kernel-image-2.4.20-1-k6 - Linux kernel image for version 2.4.20 on AMD K6/K6-II/K6-III.
kernel-image-2.4.20-1-k7 - Linux kernel image for version 2.4.20 on AMD K7.
kernel-image-2.4.20-1-k7-smp - Linux kernel image for version 2.4.20 on AMD K7 SMP.
kernel-image-2.4.20-386 - Linux kernel image for version 2.4.20 on 386.
kernel-image-2.4.20-586tsc - Linux kernel image for version 2.4.20 on Pentium-Classic.
kernel-image-2.4.20-686 - Linux kernel image 2.4.20 on PPro/Celeron/PII/PIII/PIV.
kernel-image-2.4.20-686-smp - Linux kernel image 2.4.20 on PPro/Celeron/PII/PIII/PIV SMP.
kernel-image-2.4.20-bf2.4 - Linux kernel image for version 2.4.20 (bf2.4 variant)
kernel-image-2.4.20-k6 - Linux kernel image for version 2.4.20 on AMD K6/K6-II/K6-III.
kernel-image-2.4.20-k7 - Linux kernel image for version 2.4.20 on AMD K7.
kernel-image-2.4.20-k7-smp - Linux kernel image for version 2.4.20 on AMD K7 SMP.
As mentioned before, my CPU is here:
Code:
hobbs@turnip:~$ cpuid
 eax in    eax      ebx      ecx      edx
00000000 00000002 756e6547 6c65746e 49656e69
00000001 00000633 00000000 00000000 0080fbff
00000002 03020101 00000000 00000000 0c040843

Vendor ID: "GenuineIntel"; CPUID level 2

Intel-specific functions:
Version 00000633:
Type 0 - Original OEM
Family 6 - Pentium Pro
Model 3 - Pentium II Model 3
Stepping 3
Reserved 0

<<snip>>
thanks for all the quick replies on this
 
Old 05-02-2003, 06:32 AM   #12
fishsponge
Member
 
Registered: Apr 2003
Location: Cambridge, UK
Distribution: Debian/Solaris
Posts: 147

Original Poster
Rep: Reputation: 15
does anyone know the difference between:

- kernel-image-2.4.20-1-686

and

- kernel-image-2.4.20-686

??
 
  


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
wrong to install kernel-image, kde and gnome Mathsniper Linux - Newbie 2 02-22-2005 08:32 AM
Fresh Slack 10 install, nvidia wrong kernel problem. csDraco_ Slackware 7 11-30-2004 07:41 PM
I chose the wrong option for kernel. Do I need to re install? [Slack 10] madbrain Slackware - Installation 6 09-06-2004 02:41 PM
rpm -qa | grep kernel gives wrong kernel version markelo Red Hat 3 07-18-2004 09:35 AM
Recovery from a wrong kernel install... sylk Linux - Software 1 09-19-2003 11:47 AM

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

All times are GMT -5. The time now is 10:32 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