compile a new kernel in RHEL 5
Hi all,
I need some help in compiling a new kernel. I am using RHEL 5 with kernel version 2.6.18. I have downloaded a kernel from link [HTML]http://kernel.org/pub/linux/kernel/v2.6/linux-2.6.20.6.tar.bz2[/HTML] Code:
1. cd /usr/src I have completed these steps (till 10) with no errors, BUT when I am trying the 11 th step, no new kernel img file is found. It only has the old file i.e initrd-2.6.18.img. Also, few parameters in the make menuconfig are bit confusing, it would be really great if someone has any ebook regarding the parameters. Pls help !! Thanks in Adv. Vikas |
Well you been reading old information, the steps in order are;
make mrproper make oldconfig (this will get you very close to a working kernel as supplied by Red Hat) make menuconfig (or config or xconfig);this is where one can tweak the configuration make make modules_install make install Sorry, no ebook but one can download the 'Linux kernel in a netshell" here (direct link); http://www.kernel.org/pub/linux/kern...a_nutshell.pdf |
Hi Lenard,
THANKS A TON. your steps really helped me. Regards, Vikas |
Your welcome, glad to help.
FYI: they are not my steps they all come from reading "The Linux kernel in a nutshell" |
Problem building on amd64
I'm trying to build kernel 2.6.18-53.1.6.el5-x86_64
rhel5 on amd64. I get the following error from make mrproper: scripts/Makefile.clean:17: /usr/src/kernels/2.6.18-53.1.6.el5-x86_64/drivers/infiniband/hw/amso1100/Makefile: No such file or directory make[3]: *** No rule to make target `/usr/src/kernels/2.6.18-53.1.6.el5-x86_64/drivers/infiniband/hw/amso1100/Makefile'. Stop. make[2]: *** [drivers/infiniband/hw/amso1100] Error 2 make[1]: *** [drivers/infiniband] Error 2 make: *** [_clean_drivers] Error 2 I removed and reinstalled the kernel src and still get the same error. thanks for your sugestions, Andrew |
Why???? Are you sure you don't really just need to install the kernel-devel rpm package??
Maybe something like: yum install kernel-devel You do know that one needs to prep the kernel source when installed from the Red Hat supplied source rpm file?? From the /usr/src/redhat/SPECS directory: rpmbuild -bp --target=`uname -m` kernel-2.6.spec FYI: tagging on to a pretty much closed thread is considered rude by some, vikas027 did state that he/she was helped. |
Sorry for the lapse in etiquette.
I'll go read Linux kernel in a netshell, and post a new thread if need be. Andrew |
This is no biggie to me, I just letting you know for the future.
I asked why because in many cases one does not need to re-build or build the kernel from the src.rpm file as supplied from Red Hat. This may be of interest to you; http://wiki.centos.org/HowTos/I_need_the_Kernel_Source http://wiki.centos.org/HowTos/Custom_Kernel http://wiki.centos.org/HowTos/BuildingKernelModules |
These are my notes, may be it can help you out.
Quote:
http://voidmain.is-a-geek.net/redhat...nel_build.html http://www.howtoforge.com/kernel_compilation_suse http://www.digitalhermit.com/linux/K...FIGURATION-2-6 First install these two packages, I prefer yum Code:
yum install ncurses-devel Code:
1. cd /usr/src These steps worked fine for me. I am not an expert, but this brought two kernel options for me in the GRUB menu. May be you can get an idea from this. Regards, vIKAS |
Quote:
|
All times are GMT -5. The time now is 05:11 PM. |