T H E P L E A S U R E O F C O M P I L I N G Y O U R O W N K E R N E L --------------------------------------------------------------------------------- (c) by CreepyNodque aka NoVa aka M,r;D ____________________________________ Whatīs this tutorial intended to be? ____________________________________ It will guide you threw the process of installing the (new) 2.6.6 kernel or newer versions! -- _________________________ What da hell is a Kernel? _________________________ No idea, lets ask Google: define:Kernel "The choicest or most essential or most vital part of some idea or experience; "the gist of the prosecutor's argument"; "the heart and soul of the Republican Party"; "the nub of the story" Would be some options, or "The inner and usually edible part of a seed or grain or nut or fruit stone" I hope now you know what a Kernel is- lets get into some serious stuff! -- _____________________________________________________________ Is also a newbie able to do this without crashing the system? _____________________________________________________________ Don`t worry about that, we wonīt delete the "old" kernel until the new one runs perfectly! _____________________________________________________ What about the adage "Never change a running system?" _____________________________________________________ Thats crap! -> Without fixing no funning........!?!? -- ______________________________ Do I have to prepare anything? ______________________________ Well, the proggies you are going to use are available in every common distro. But keep in mind that the versions are also very important! ********************************************* A geeks`s grocery list for a kernel v.2.6.6:* ********************************************* Gnu C-Compiler v. 2.95.3 Gnu make v.3.78 Gnu Binutils v.2.12 Util-Linux v.2.100 Module-Init-Tools v.0.9.10 Those versions [and higher] are recommended, and it might be possible that different ones also work, but donīt dare to blame me if it doesn`t work! You can find these tools on the FTP-server of your distributor or somewhere else like www.rpmfind.com ! -- ________________________________________ Where can I get the kernel sources from? ________________________________________ There are different ways! You can suck it directly from kernel.org or get it from my site: www.creepyproducts.tk. -- 1st Part: _______________________________ T h e B o r i n g S t u f f _______________________________ Make sure you are root! Download the sources. Check if /usr/src/linux already exists [often in older Linux-Versions]. If so, then run #mv linux linux_old and delete it later if it isn`t longer nessecary. Unpack the sources with #tar xjvf linux-2.6.6.tar.bz2 -C /usr/src Now we need a symbolic link to the folder linux ,we modified: #ln -s linux-2.6.6 linux Use #cd linux to change directory. Now we prepared nearly everything, but we still need some hardware info for configuring the kernel. Type #lspci for a list of the PCI-Stuff and #lsmod for a list of all loaded modules and #cat /proc/cpuinfo for the processor-info. Okay, lets take a quick overview over what we have done: The kernel is unpacked in /usr/src/linux and all nessecary programs are installed. But before we compile the kernel we have to configure its components. Type #make mrproper to delete all previous configurations. There are different ways to configure the shit: Type #make menuconfig for a console-based configuration #make gconfig for a configuration based on the Gtk-Libs #make xconfig for a config based on the Qt-Libs. The X-Config proggys got a documentation, so its very easy also for "newbies" to handle with those two. Okay. We finish the configuration and save our changes. 2nd Part: ________________________________ C o m p i l i n g I s F u n ________________________________ Here we go: Type: #make bzImage #make modules #make modules_install These commands are pretty selfexplaining...nomen est omen... This gonna take a while, so get some coffee! Ps:If you type "#make bzdisk" instead of bzImage you can save the kernel to a floppy-this gives you the possibility to boot the new kernel without editing the config-file of your bootloader! After it compiled the new kernel is in ./i386/boot - this is obviously not the correct directory for the kernel: Type: #cp ./i368/boot/bzImage /boot/bzImage-new To copy the kernel in /boot. Now we need a entry in the bootloader: I take GRUB as an example- #title Linux (2.6.6) # root (hd1,0) # kernel /boot/bzImage-new ro This is the new entry in /boot/grub/grub.conf for our new kernel - but donīt edit any other entries! -The entry looks pretty similar for lilo (/etc/lilo.conf)! --Now reboot! Select "Linux 2.6.6" in the bootloader to start our new kernel! Congratulations-You compiled your own kernel! BIG HIM UP!! Donīt worry if there are error messages and a kernel crash, you got your second, your old kernel! C o n t a c t: www.CreepyProducts.Tk nova [at] aon.at ICQ:288078542 AIM:CreepyNodque IRC:irc.anomalous-security.org - #CreepyProducts #noVa #HackerLounge N o t e: Donīt dublicate,donīt edit and donīt take credit for what you didn't do. If you would like to host it on your server please give me full credit and include a link with my e-mail! Ps: Boycott Micro$oft, SCO and Nazism. -M,r;D