-   Linux - General (
-   -   Kernel Upgrade - HOWTO needed (

AMMullan 01-08-2004 12:45 PM

Kernel Upgrade - HOWTO needed
Hey all :-)

Kinda feelin like a newbie again as I am stuck on this on (hehe probably just more impatient than stuck)...

Does anyone know where any good HOWTO's are for upgrading the kernel (upgrading from 2.4.20-8 to 2.6). Reading the README just didn't help - plus this could be useful for others that wanna do the same thing.

Thanks in advance

rberry88 01-08-2004 01:27 PM

1) download kernel
2) cp kernel.tar.gz /usr/src/
3) tar -xzvf <kernel>
4) make menuconfig
5) make dep <-- in Gentoo I use 'make all
6) make bzImage
7) make modules
8) make modules_install
9) cp /usr/src/<kernel>/arch/i386/boot/bzImage /boot/bzImage (rename bzImage if desired when copying to boot)
10) edit grub/lilo
11) reboot & cross fingers


AMMullan 01-08-2004 01:54 PM

Thanks :)

I'll give it a shot and post results tonight...

vincebs 01-08-2004 02:07 PM

I need something like that too. Most guides nowadays are just long verbose versions of rberry88's post with no troubleshooting information.

A good kernel compiling guide should deal with:
a.) Using src rpm vs. the tar.gz version
b.) What to do to configure both grub AND lilo after configuration
c.) Difference between make mrproper and make clean
d.) What should be compiled as a module and what should be built into the kernel
e.) What features most people need and which ones most people don't but are still selected by default in the config file. For example, I am puzzled on whether I should include various networking options I have no clue about whether I need, same with SCSI, I have no SCSI hardware, should I not select anything? How about framebuffer devices? The help text says I can "play around with it" but don't really need it. Really?
f.) When you shouldn't use make oldconfig
g.) What to do when rpm breaks after you upgrade to 2.6
h.) How to solve the various kernel panic messages
j.) What to do when modules fail to load after startup
k.) What to do with unresolved symbol errors
l.) Whether warnings during kernel compilation are due to your own mistakes, your compiler being too old, or the kernel developers being too lazy. For example:

drivers/net/bonding/bond_alb.c: In function `bond_alb_xmit': drivers/net/bonding/bond_alb.c:1340: warning: comparison is always true due to limited range of data type
m.) What to do if you screw up your bootloader

AMMullan 01-08-2004 02:22 PM

Yeah thats very true but the HOWTO's won't get any better until someone has done the upgrade and documented it - and then you actually have to experience all the problems to be able to document them all :P

I know theres a few new ways to setup the kernel, theres make xconfig (this is what I started to play with before I had to go to work) SO all those would have to be documented aswell.

The documentation on the net regarding a few subjects for linux/applications are quite contradicting - take the Samba HOWTO for example - I read this and couldn't get one part of it - did a google search and found a few documents about it but most had different info lol... Eventually found a good one that worked :)

All in all I've found that 95% of Linux stuff is documented pretty well tho... And there's so much fun to be had hehe

DrOzz 01-08-2004 02:40 PM

you can check out the one i put together
located here
people seem to have no problems with it, so i'll share it with you ;-)

AMMullan 01-08-2004 02:52 PM

Very kewl HOWTO :)

DrOzz 01-08-2004 03:25 PM

thanks d00d, hope you succeed if you decide to use it ;-)

DrOzz 01-08-2004 03:30 PM

actually i should also point out, that compiling the 2.6 kernel is one step easier, and you no longer have to do make dep, and you can start at make bzImage ...

and thinking of this, i am going to go update the HOWTO :D

AMMullan 01-08-2004 04:03 PM

For real? Kewl as :-)

I'll definately use this HOWTO - it's very detailed... :)

DrOzz 01-08-2004 04:20 PM

yes it is very detailed, and my objective and goal when doing this, was to explain every step that the end-user was to do, and in some cases why they are to do it... because i know when i was learning, and for that case, learning anything, you always see a command that you have to type, but it may either make no sense, or you don't know why you did it, or what it does, but you know that it must be typed because the howto or the person helping you tells you that its the command you need, and i didn't want that to be the case when i wrote this....
and since this is such a common task and something that people wanna try/learn just for the hell of it, i thought that this would be a good idea to dumb down something like kernel compiling....and since you always hear people pissing and complaining that the kernel howto on or whereever else makes no sense, that also made it a good idea to slap this together..

Nukem 01-08-2004 04:20 PM

I have already bookmarked DrOzz's guide and I'll print it out soon. This weekend if I get time, I will try this out myself. I have two things to ask.

1. How long does the whole process will take in a P4 2.40 GHz processer with 512MB Ram?

2. Any last minute advices?

DrOzz 01-08-2004 04:26 PM

1) well i am not sure how long it will take, but i assume things will speed up cause they made it easier to do this in 2.6, by cutting out steps....but just to give a ballpark figure, that is nothing more but an approximation, i will say if everything goes smooth for ya, that it will take about 35 - 60 mins ...

2) backup ;-)

h/w 01-08-2004 05:01 PM

configuring the first time takes a lot of time, simply cos you might not know whats needed and whats not, and dont know if you're machine would work or blow up if you left or included anything. lol. sorry, didnt mean to scare ya, but thats how i felt when i first saw Xconfig. i only use menuconfig now as i feel thats better/more convenient.

the kernel compile itself takes about 20 mins (maybe less).

SILVERPENGUIN 01-09-2004 09:53 AM

DrOzz, Help! I got to the /sbin/mkinitrd /boot/initrd-2.6.0.img 2.6.0 and got this error:

linux:/usr/src/linux # /sbin/mkinitrd /boot/initrd-2.6.0.img 2.6.0
/boot/initrd-2.6.0.img/var/tmp is not a directory

What did I do wrong??

All times are GMT -5. The time now is 03:15 AM.