SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Hi,
I've upgraded SW with the latest security packages yesterday and now I get a kernel panic (installed the kernel sources too, otherwise couldn't reinstall the nvidia driver). I guess it has to do with the initrd.gz, right?
I'm using jfs on / (sda3) and /home (sda5).
So I thought I would have to create an initrd.gz, chrooted into /boot, but now what?
Code:
mkinitrd -c -k 2.6.27.31-smp -F
Is that correct?
And then change /etc/lilo.conf and add the line
for my system. Alien Bob proides a useful command generator available here to help. This is included with current.
I also note that you have
Quote:
image = /boot/vmlinuz
- it's as well to keep the huge kernel in case anything goes astray and point /boot/vmlinuz there (the default). So you would have a lilo stanza for the huge and one for the generic kernel with the initrd added.
Alien Bob put a nice script (/usr/share/mkinitrd/mkinitrd_command_generator.sh)
in Slackware to help facilitate the making of an initrd image. While it doesn't
guarantee to remove all possible errors from the process, it does a good job.
Just issue "sh /usr/share/mkinitrd/mkinitrd_command_generator.sh" and the script
will output a suggested command. If it looks good to you, run that and then
afterwards, run "lilo" to write the new bootloader.
OK, thanks, I downloaded the script and put it on a USB stick, mounted it and ran the script. Followed the advice and then ran lilo. Rebooted and get this error:
Code:
no kernel modules found for Linux 2.6.27.31
input: AT Translated Set 2 keyboard as /devices/platform/i8042/serio0/input/input1
mount: mounting /dev/sda3 on /mnt failed: no such device
ERROR: No /sbin/init found on rootdev (or not mounted). Trouble ahead.
You can try to fix it. Type 'exit' when things are done.
What is wrong?
The script adviced 2.6.27.7, shouldn't that be 2.6.27.31?
But I tried that too and it didn't work either.
Last edited by adriv; 08-20-2009 at 10:00 AM.
Reason: typo
I also note that you have - it's as well to keep the huge kernel in case anything goes astray and point /boot/vmlinuz there (the default). So you would have a lilo stanza for the huge and one for the generic kernel with the initrd added.
Can you elaborate on that?
You mean there has to be a new set of lines in lilo.conf, instead of using the old ones?
Distribution: slackware64 13.37 and -current, Dragonfly BSD
Posts: 1,810
Rep:
Quote:
Can you elaborate on that?
You mean there has to be a new set of lines in lilo.conf, instead of using the old ones?
Yes - so you have two stanzas in lilo.conf. One for the standard huge kernel and one for the new generic and initial ram disk. Like this from my setup:
This (amongst other stanzas) gives me an initial ram disk option and a huge kernel option at boot up. This way if there's a problem with my initrd.gz creation ,(as stupidly happens for me sometimes), then I can boot to the default huge kernel and investigate.
As to your problem now. Boot back to the system and make sure you're running kernel 2.6.27.31 with "uname -r". It looks like something has gone strangely wrong with your initrd creation. Did you supply the "-k" and "-m" parameters correctly to mkinitrd ?
You don't need to download the script, it's on your system:
Code:
/usr/share/mkinitrd/mkinitrd_command_generator.sh
You can run it with the "-i" switch, which stands for interactive:
Code:
sh /usr/share/mkinitrd/mkinitrd_command_generator.sh -i
so that you can tell it which kernel to select, and other things.
If you're not fixed up, perhaps post the output of "ls -l /boot/".
As for the "no kernel modules found for Linux 2.6.27.31" message,
it sounds as if the CD/DVD/USB whatever you installed with was not
using the latest kernel. Maybe you had a media that you made from
a local mirror or something before the last updates to -current?
Uname isn't going to help be because I boot from the SW DVD.
I'm pretty sure it was 2.6.27.7-smp.
But upgrading with these security patches, that should be 2.6.27.31, right?
I've booted Knoppix now (also got erors on /proc) and now I see that /proc is empty! That's not normal, is it.
You don't need to download the script, it's on your system:
Code:
/usr/share/mkinitrd/mkinitrd_command_generator.sh
You can run it with the "-i" switch, which stands for interactive:
Code:
sh /usr/share/mkinitrd/mkinitrd_command_generator.sh -i
so that you can tell it which kernel to select, and other things.
If you're not fixed up, perhaps post the output of "ls -l /boot/".
As for the "no kernel modules found for Linux 2.6.27.31" message,
it sounds as if the CD/DVD/USB whatever you installed with was not
using the latest kernel. Maybe you had a media that you made from
a local mirror or something before the last updates to -current?
I'm not running current, but 12.2, so that script isn't available by deafult. But I copied it to /boot the first time.
I'l start over from scratch.
boot SW 12.2 DVD
mkdir /mnt/slack
fsck.jfs /dev/sda3 (filesystem is clean)
mount /dev/sda3 /mnt/slack
chroot /mnt/slack
cd /boot
ls -l (ehmmm, that's an awful lot to type, but i'll give it a try)
To add a few things, I'm in /boot now as you could see and run the script:
sh mkinitrd_command_generator.sh
Code:
?ind: /sys/block: no such file or directory
cat: /proc/bus/input/devices: no such file or directory
cat: /proc/mdstat: no such file or directory
mkinitrd_command_generator.sh revision 1.40
This script will now etc, etc.
mkinitrd -c -k 2.6.27.7-smp -f jfs -r /dev/sda3 -o /boot/initrd.gz
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.