-   Linux - Newbie (
-   -   custom kernels... Why so hard? (

mm0204 06-08-2005 04:26 AM

custom kernels... Why so hard?
Hello LQ!

i am so glad i found this site. I have slackware 10 installed and running usefully on my pII 400 named Strider.... yes, it's a LOtR reference.... Hobbits Rock!

I love it. I down loaded the disc 1 and 2 iso's and i was off.

now, however, I amd noticing some slowdown and i want to compile a custom kernel. Coming from FreeBSD, i figured it would be no sweat... in FBSD you edit a plain text config file, commenting out what you dont need, compile, install, reboot and ur done... everything i've seen on the subject in the linux world is about writing makefiles and "tweaking the source"... i'm a geek but i'm not a programer....

would someone please help me out?


Q :scratch:

reddazz 06-08-2005 05:08 AM

Nah its neither too difficult nor complicated. Take a look at this article at kerneltrap. Its meant for those upgrading to the 2.6 kernel but I used it when I compiled my first kernel a while ago.

zord 06-08-2005 05:09 AM

It's even easier than editing a textfile, try 'make menuconfig' in the directory, and you'll get a menu, where you can edit each setting.

This is, how I would do it (for a kernel):
unpack the new kernel to /usr/src/linux-
rm /usr/src/linux
ln -s /usr/src/linux- /usr/src/linux
cd /usr/src/linux

copy your old config in the directory, so you can use it as a base for the new kernel: cp /boot/config /usr/src/linux/.config
make menuconfig
make && make modules_install

Now the new kernel is compiled, you'll have to copy it to your boot dir:
cp /usr/src/linux/arch/i386/boot/bzImage /boot/kernel-
cp /usr/src/linux/.config /boot/config-
cp /usr/src/linux/ /boot/

Now edit your /etc/lilo.conf, add an entry like this above the existing image entry (make sure to change the root disk to the appropriate one):
image = /boot/kernel-
root = /dev/sda3
label = slack-2.6.11

This way you can still boot your old kernel, in case something went wrong.
Run lilo as root, and all should be done.

Reboot and pray :P

Hope this helps, don't give up, if it doesn't work the first few times ;)

Good luck

All times are GMT -5. The time now is 04:14 PM.