Operating System - Linux
1828488 Members
2277 Online
109978 Solutions
New Discussion

recompile redhat linux 7.3 kernel

 
trystan macdonald
Occasional Advisor

recompile redhat linux 7.3 kernel

Hi,
Does anyboduy know how to change kernel parameters and recompile redhat linux 7.3 kernel?
Thanks,
Trystan.
3 REPLIES 3
Vitaly Karasik_1
Honored Contributor

Re: recompile redhat linux 7.3 kernel

Hans van Zijst
Advisor

Re: recompile redhat linux 7.3 kernel

Trystan,

Compiling a kernel can be quite tricky. You build a new kernel from the ground up every time. You do this by configuring the source code (wich can be quite a lot of work the first time), compiling it and then installing the new kernel and modules.

Get yourself the source code (available almost everywhere, www.kernel.org might be a good start), unpack it and run "make config" (or, if you like a GUI, "make xconfig"). That's where the fun starts: you'll have to set all parameters by hand, so you'll have to know upfront exactly what kind of hardware you have and what your kernel should and shouldn't do.

After having configured the whole bunch, you do "make clean", followed by "make bzImage" and "make modules". If that's finished, enter "make modules_install" and your freshly compiled modules will be put in the right (?) place: /lib/modules/kernel_version. Now copy the new kernel (bzImage) to the place you want (in RedHat usually /boot), modify /etc/lilo.conf (unless you're not using LILO of course *grin*) and reboot.

Oh, be sure not to erase your original kernel from LILO unless you have tested your new one.

Good luck!

Hans
l'apprenti sorcier
Balaji N
Honored Contributor

Re: recompile redhat linux 7.3 kernel

in short,

1. #cd /usr/src/linux
2. #make mrproper
3. #make menuconfig
4. #make dep
5. #make clean
6. #make modules
7. #make install
8. #make modules_install
Change /etc/lilo.conf and than run lilo -v

for more detailed info, refer the kernel howto.
-balaji
Its Always Important To Know, What People Think Of You. Then, Of Course, You Surprise Them By Giving More.