Forum Home
Press F1
 
Thread ID: 46865 2004-07-08 04:31:00 Upgrading Linux Kernel on Xandros Guide. Ashley Matthews (550) Press F1
Post ID Timestamp Content User
250659 2004-07-08 04:31:00 Hi.

Can anyone point me to a tutorial in which I could find a tutorial that gives a full newbie introduction on how to upgrade the kernel to a newer version (particularly 2.6). I've been trying to do it with several guides that I found for Debian (which I gather Xandros is based upon) and a generic one that I found here (www.osnews.com).

When I tried with those instructions it worked ok when booting as in it loaded the kernel, but freezes on the initializing kernel section.

Any help, guidance or links appreciated
Ashley Matthews (550)
250660 2004-07-08 05:05:00 Well....

Its not really that hard. I dont know of any "How to make a 2.6 kernel" How-To's, but I'll give you a quick rundown:

Download the sources from kernel.org
cd /usr/src
tar xvjf (if you got the tar.bz2) kernel-2.6.7.tar.bz2
rm linux
ln -s linux-2.6.7 linux (This sets up the symlink /usr/src/linux to the current kernel which is a MUST)
Next, cd /usr/src/linux
make menuconfig
Go through EVERYTHING. Start at the top and work your way down. It'll take a good hour the first time if you do it properly, but believe me its worth the satisfaction! You'll want the depreciated devfs, set to automount at boot at least.
Everything else just try and use your initiative.
When you're done, select exit and save your .config
Now, type:
make
It'll finish making the kernel, then type:
make modules_install
This will make and install all the kernel modules.
Now you want to make sure /boot is mounted, then
cp arch/i386/boot/bzImage /boot/kernel-2.6.7-build1
cp System.map /boot

Next, edit your lilo config (Im not sure how to do this, but I know you can from kcontrol).

This is a real quick rundown, but hopefully it'll put you down the right path.

Hope this helps

Cheers


Chill.
Chilling_Silence (9)
250661 2004-07-08 05:09:00 I just realised I left out three things:

1. There is no 100% guide that says "You will need this and wont need this". If you find a guide that claims to know all you want then it lies. It may give you a rough idea, but just follow your initiative. If you dont understand an option, goto Help, or post back here.

2. You probably will do more than one kernel build before you get it right. Dont let it put you off, keep at it. I did 5 minor changes before I got my kernel "right", and then more with the change of hardware, optimisation/trimming down etc.

3. IRC is your friend. Expecially the people in irc.freenode.net. If you get stuck, a good place to try is there, in #xandros, #gentoo, or if you still dont get help you could always try #love-sources. I think there's even a #kernel room....

Hope this helps,
Good luck - Its worth it!


Chill.
Chilling_Silence (9)
250662 2004-07-09 03:22:00 After making the .config, edit the Makefile. About the third line allows you to give your own suffix (e.g."-01AM"). Change it each time you compile.

Copy the System.map to a new name, with your suffix. Follow the style of the original files in /boot . Copy the bzImage to a new filename too, like "vmlinuz-2.x.y-01AM". You might have to make an initial ramdisk boot image --- this is a cutdown version containing any essential modules for booting. (I tend to remove the need for this by compiling internal support for the disks etc. )

When changing lilo.conf, just follow the form of one of the original entries. DON'T just overwrite the working one. ;-) Remember to run lilo after changing the .conf file. Make sure you have a working boot floppy before you do any of this.:D

It takes a bit of playing around, but it'sworth it. You'll get a faster boot.
Graham L (2)
1