Linux - GeneralThis Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I am currently running Mandriva 2005 LE. I want to recompile my kernel (2.6.11-6mdk) as I believe this will speed up my system (please correct me if I am wrong).
Could someone please provide me with the steps needed to recompile my kernel. Here is what I think I need to do:
cd /usr/src/linux
su - (password)
make mrproper
make clean
make xconfig
make dep
make bzImage
After this, what do I do?
When I run the make xconfig, does a dot next to the item (as opposed to a check) mean that it's selected or not? Also, I don't want to mess anything up. I unchecked obvious things (ISA support, Bluetooth support, etc). Is there anything I can change (check/uncheck) to help out?
if your using grub or lilo edit the config to correspond to your kernel, (prob best to make 2 entries and keep your old kernel in there incase the new kernel fails.)
EDIT: I have never done make bzimage before, with gentoo I just do make && make modules_install and then I cp my bzImage to /boot
Last edited by GUIPenguin; 10-08-2005 at 01:45 PM.
You'll probably want to do make dep && make modules_install. You also get a System.map file that you need to copy to /boot. It appears in the directory where you execute make xconfig from, not where the new kernel is.
I agree with GUIPenguin's suggestion to keep your old kernel in the bootloader in case the new one doesn't work quite right.
If you just want to fine tune your kernel for performance it helps to know a lot about your hardware, especially specific chipsets. For example, not just what type of soundcard you have, but the type of chip that controls it. And if you have USBv1.1 or 2.0. 1.1 uses the ohci driver while 2.0 uses ehci so you only need one or the other. Try not to include everything builtin, only the most important things, and make the rest modules. This will keep your kernel smaller so it'll load faster. If you use lilo as the bootloader you can include compact and lba32 options to load the kernel faster also. I don't know if grub has equivalents.
Here's how I compile my kernel recently due to an update in the patchset I use that I wanted.
Code:
cd /usr/src
tar -xvjf linux-2.6.13.tar.bz2
cd linux-2.6.13
bunzip2 patch-2.6.13-archck7.bz2
patch -Np1 -i patch-2.6.13-archck7
make menuconfig
make
make modules_install
cp arch/i386/boot/bzImage /boot/kernel-2.6.13-archck7
cp .config /boot/config-2.6.13-archck7
You don't need to worry about the patch stuff, once you've done that you'll need to edit /boot/grub/menu.lst.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.