Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Installing 2.6.8, kernel panic [SOLVED]
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
wmclaffe
n00b
n00b


Joined: 17 Sep 2004
Posts: 17

PostPosted: Sat May 07, 2005 11:58 am    Post subject: Installing 2.6.8, kernel panic [SOLVED] Reply with quote

I'm trying to install the 2.6.8.1 kernel for my OS class. I currently run the 2.6.10 kernel, and I'd like to have both installed at once. I'm following my TA's instructions, but I'm running into problems. The instructions are as follows:

Quote:

Pre-Build steps
----
Download, unpack the kernel source tarball
Copy over the config file from /boot/config-$configversion to /usr/src/linux-$version/.config
Edit the Makefile to change the “EXTRAVERSION” to a name that is specific to your team.
The kernel is built with only two commands
# make clean (if you want to clean the code)
# make oldconfig
# make


Installing the kernel
----
DO NOT, DO NOT overwrite the existing kernel in /boot.
You will not be able to boot the machine up if you overwrite it with your kernel and your kernel has an error in it.
On a successful build, the kernel image can be found as the file
/usr/src/linux-$version/arch/i386/boot/bzImage.
Copy the kernel image into /boot and name it vmlinuz-$yourversion
run $make modules_install in /usr/src/linux-$version.
Create the ramdisk image using the mkinitrd command ( for more info. man mkinitrd)
$mkinitrd /boot/initrd-$yourversion /lib/modules/$kernel-version
Edit grub.conf to add your kernel to the list so that you will see it as an option when booting up.


These instructions were written for someone working on Fedora, so there are some errors; for example, there is no config file in /boot. I think I managed to get around the errors in the instructions (though if you have a better set of steps to follow, they'd definitely be welcome), but I'm still getting errors.

Currently, when I try to boot the new kernel, I get a 'kernel panic: attempted to kill init' error, and I have no idea what's causing it.

Here's my grub.conf:
Code:

# which listing to boot as default, 0 is first, 1 is second
default 0
# how many seconds to wait before default listing is booted
timeout 30
# splash image
splashimage(hd0,2)/grub/splash.xpm.gz

title=Gentoo Linux 2.6.10-r4
# partition where kernel image (or OS) is located
root (hd0,5)
kernel /kernel-2.6.10-gentoo-r4 root=/dev/ram0 init=/linuxrc ramdisk=8192 real_root=/dev/hdc6
initrd /initrd-2.6.10-gentoo-r4

# for windows
title=Windows XP
root (hd0,1)
makeactive
chainloader +1

# for cs111
title=Kernel 2.6.8 - CS111
root (hd0,2)
kernel /boot/vmlinux-cs111 root=/dev/hdc6 init=/linuxrc
initrd /boot/initrd-cs111
makeactive
chainloader+1


EDIT: Ok, solved it myself. After trying a couple different things, I manually wrote down a couple of the error messages and googled them. The one that did the trick was 'pivotroot: pivot_root(/sysroot, /sysroot/initrd) failed: 2'. Apparently all I had to do was 'mkdir /initrd', and now it boots perfectly. I love those nice, clear errors messages. :roll:
Back to top
View user's profile Send private message
jourbans
n00b
n00b


Joined: 16 Jan 2004
Posts: 34
Location: Chicago, IL, USA

PostPosted: Tue May 31, 2005 8:17 pm    Post subject: Reply with quote

Simply a thanks for the post. Just ran into the same error and thought it'd take me all day to sort it out. Cheers!
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum