Kernel upgrade error - Redhat enterprise 5.3
I am very new to forum posting and also to Linux. I am currently trying to upgrade my kernel. I have followed following procedure. I am using RedHat
a. Downloaded latest kernel from kernel.org (22.214.171.124).
b. Copied and extracted at /usr/src/linux-126.96.36.199/My kernel is - Linux 2.6.18-8.el5
c. Created .config using make gconfig
Till this it works fine. Problem starts now and I am searching the solution from last 2 days.
When I move forward to next step ‘make’ the output is as follow.
[root@localhost linux-188.8.131.52]# make
SYMLINK include/asm -> include/asm-x86
In file included from include/linux/compiler-gcc.h:86,
include/linux/compiler-gcc4.h:8:4: error: #error Your version of gcc miscompiles the __weak directive
make: *** [kernel/bounds.s] Error 1
make: *** [prepare0] Error 2
To solve this I have Tried following:
a) I have tried to upgrade gcc by using CentOS distribution. I have installed following package to upgrade gcc
The error remain same. No change.
b) Searched the new kernel rpm for redhat but they are 2.6.18 only… am I missing any concept ?
O Linux Gurus Please take me out of this.
Hi, Welcome to LQ!
LQ has a fantastic search function that may save you time waiting for an answer to a popular question.
With over 3 million posts to search it's possible the answer has been given. :)
Please type in a cli (shell) gcc -v
This wil give the installed version of gcc. If no responce try gcc -V (upper-case)
also check the version of glibc, this lib plays an important part of the system recompilation. Glenn.
Just a comment, going from 2.6.18.x to 2.6.32.x is a big jump/leap forward.
It will probably work, but I would do make oldconfig before making anything else.
That way the new kernel is configured to the installed kernel before you begin configuring the new sources.
Generaly, I make a static link to the kernel sources with...
This you can script/macro, as once the link is made the commands are usually the same.
Oh, I forgot, I'm using kernel....
The latest kernel version for RH EL 5 is :
.. which is what you get by an online update.
And has some backported features from later kernels incuded.
If you change it to 184.108.40.206 , you no longer have
Redhat Enterprise ( 5.3 ).
I would not expect the 220.127.116.11 to compile on RH EL 5.
A "latest" OS can do it, e.g. Fedora 12, if you want to
experiment. Result : a '18.104.22.168' for Fedora 12 only.
Using kernels other then official ones for CentOS/RHEL is totally stupid thing to do, since you lose ALL of the advantages of CentOS/RHEL, mostly stability. That is why (almost) nobody does it, and you will have REALLY BIG trouble to find someone to help you with that.
I , personaly, think it as a blasphemy. Just use some newer distro, do not taint CentOS/RHEL.
Will try another way - another doubts.
Thank You all,
As per GlennsPref, I have gone through the README with the kernel source. The minimum requirement of GCC is 3.2 and I have gcc version 4.1.1 20070105. Look the following output
I have run ‘make oldconfig’. It asked me a lots and lots of questions regarding the various kernel features. I have given default answers to those (taken around 1.5 hour).
But at ‘make’ command the error is as it was, error is not solved.
As per the suggestions from knudfl and DrLove73, I will try to upgrade kernel-2.6.18-164.2.1.el5 today and post the result here. First I will try SRPM from redhat.
But I have search and gone through following links to understand backporting.
It has confused me more.
If I want to get all the drivers and security protection that is provided with latest kernel, what should I do?
Is there any way to my current kernel version with the kernel from kernel.org or any other standards?
I am a student and doing experiments to make my understanding strong. Guide If I am in wrong direction. Thanks a lot again.
Hi, as you may be aware, I am not using CentOs. But....
Linux is Linux and you should be able to hack it to some degree.
I use Mandriva for this reason.
Kwan has a kernel build tute here, I used to use it when starting out as a newb. No offence!
Here it is, on part of the page that lists the programs you need to successfully configure and compile a kernel. It's the 2.6 section, not the older 2.4 part. ;-)
I mention this because of your error.
Another thing I thought may help, is to run all the commands as root, Just for the kernel compile "make" commands. As I have found recently, I need root access to configure a kernel, where previously I could do it as a ordinary user.
While searching for suitable guides, I also came across this web-site, dated 2006,
May still reveal some centos secrets. so don't tell anyone, just kidding!
There is a logical reason for your error, so far we haven't found it.
You should be able to compile and install any kernel you want, but it may not boot.
see how you go, I have not read the centos pages listed above, but if you have any questions, just ask here.
Also found right here at LQ, same error!
says to upgrade gcc to ver 4.3
also mentioned here....
Could I remind you, LQ has a fantastic search function that may save you time waiting for an answer to a popular question. :)
# 8 , @ GlennsPref
Like in most other Linux's, you have the choice
of having multible compilers installed.
( Mandriva(2010) : 4 different.)
The gcc43* packages can be found in an archive. ( el 5.3 ).
Todays gcc4* is : gcc44 , gcc44-c++ , providing 4.4.0 .
# yum search gcc4
.. will show, what's available.
Thanks for the response, it looks like that is the solution.
would you agree?
It does not address the conflicts that may occur once booted, but as the OP said, this is an experiment.
and yes, I do remember Mandy has various versions, I have a few installed, but did not know enough about it to assume it was not only Mandriva. :)
If you need all modules and drivers enabled in CentOS kernel, then use kernels from centosplus repository.
CentOS kernels from base/os and updates repositories kernels are binary compatible with Red Hat compiled kernels since all kernel patches, bugfixes and any other changes are done in upstream (Red Hat) repositories, and only suggested by CentOS development team.
Centosplus repository is different story. All modules/drivers are enabled, and certain bugfixes and patches are introduced into the build. In last 3 years of use of centosplus kernels, I haven't found problems that are not found in upstream kernel so I consider them very safe. Definitely more safe then the kernel you can build by your self.
|All times are GMT -5. The time now is 12:12 PM.|