Go Back   nV News Forums > Linux Support Forums > NVIDIA Linux

Newegg Daily Deals

Reply
 
Thread Tools
Old 09-25-03, 01:32 PM   #1
GeoffVT
Registered User
 
Join Date: Sep 2003
Posts: 5
Default Kernel source tree problem Red Hat

Well, I appear to be having the same problem that I a lot of people with kernel modversions are having, which is that the kernel source tree is no longer pointing to the right kernel headers. I went back through the fourm threads and found some very useful advice given by Zander in recompiling the kernel source tree:
make mrproper
cp configs/kernel-2.4.20-i686.config .config
make oldconfig depend clean

Where kernel-2.4.2-i686.config is my current kernel configuration file.

Previously the installer would not even compile the kernel module, but now it builds the module fine, it's just appearently building the module for the wrong kernel.
You all can see what I mean in the log file, but basically I'm running kernel 2.4.20-20.7, and it's building the module for 2.4.20-20.7custom. I do have a 2.4.20-20.7custom kernel installed, but I really don't use it, and it's unstable with all kinds of non-working scripts that I had tried to add months ago. Basically, I realized that perhaps I shouldn't go mucking too deep with stuff that I don't understand that well yet. Anyway here's the abridged version of my log file with the specific error:

-> Kernel module compilation complete.
ERROR: Unable to load the kernel module 'nvidia.o'. This is most likely
because the kernel module was built using the wrong kernel header files.
Please make sure you have installed the kernel header files for your
kernel; on Red Hat Linux systems, for example, be sure you have the
'kernel-source' rpm installed. If you know the correct kernel header
files are installed, you may specify the kernel include path with the
'--kernel-include-path' commandline option.
-> Kernel module load error: ./usr/src/nv/nvidia.o: kernel-module version
mismatch
./usr/src/nv/nvidia.o was compiled for kernel version 2.4.20-20.7custom
while this kernel is version 2.4.20-20.7.

I have also attached the entireity of my log file to this post if that helps.

I bet this has to be a fairly simple problem, and I'm just doing something really stupid. I've tried the --kernel-include-path /lib/modules/2.4.20-20.7/build/include option to the installer, but it returns the same error. Intutively, since that command points to the kernel header, I assume it has something to do with configuring my kernel header. But, honestly I'm just too new to this to figure it out by myself. So, I'm hoping someone here with a bit more experience configuring kernel files, or someone who has seen this error before can shed some light for me. Thank you all.
Attached Files
File Type: log nvidia-installer.log (6.2 KB, 200 views)
GeoffVT is offline   Reply With Quote
Old 09-27-03, 02:38 AM   #2
LordMorgul
Electrical Engineer
 
LordMorgul's Avatar
 
Join Date: Dec 2002
Location: San Luis Obispo, CA
Posts: 872
Default

If you're running a kernel that you compiled you need to make sure the kernel source tree is precisely configured to the kernel you're running, and this can be difficult to get right (I've muddled it up numerous times).

If that is a Redhat kernel exactly, then get ahold of the config for it as the instructions say. When the kernel gets configured if there is anything changed it will append the custom to the kernel source name because it is no longer exactly the RedHat configuration. I think this is the problem.

Once you get the kernel configured completely it may help to go ahead and recompile it on that config to make sure it works. That should show you the config is good anyway.
LordMorgul is offline   Reply With Quote
Old 09-28-03, 09:56 AM   #3
GeoffVT
Registered User
 
Join Date: Sep 2003
Posts: 5
Default

Thanks for the advice. I don't know if this is what you meant or not, but I figured the best way to make sure my kernel source tree matched the kernel exactly would be just to re-download the the source and kernel packages directly from Red Hat and reinstall them as a new kernel (both from RPM). Anyway in installing/configuring them I did something like:
$mrproper
$make oldconfig
$make dep
$make modules
$make modules_install
then copying my new kernel image to /boot/vmlinuz
and adding the kernel image to /ect/lilo.conf


it does the exact same thing. My guess is that old kernel headers are still being used, or I'm still using an old config, but truthfully I don't even really understand how all these things fit together. I imagine, I entirely missed the point of your reply, and am doing things that are counterproductive, or just plain wrong. I of course appreciate any help, but I guess I need it spelled out a little better, because I'm not a very technical person. If not, Red Hat is just kinda beginning to grate on me, and have considered switching over to Mandrake 9.2 when it is released. For the most part, I've heard fewer problems arising from them. Thanks everyone.
GeoffVT is offline   Reply With Quote
Old 09-29-03, 06:25 AM   #4
LordMorgul
Electrical Engineer
 
LordMorgul's Avatar
 
Join Date: Dec 2002
Location: San Luis Obispo, CA
Posts: 872
Default

If you download the kernel rpm and matching kernel-source rpm you do not need to further configure the kernel source tree.

You should install the rpms, boot the system on the new kernel and attempt the build and install. If this still fails with similar errors then other parts of the system (which headers are pointed to by /usr/src/linux-2.4) could have been effected by your previous builds. If you do need to specifically configure the kernel source tree, which I don't believe is necessary but might be, you should not use your oldconfig if trying to match the redhat kernel. In the installed kernel source tree (from the kernel-source rpm) there is a configs directory containing the proper config for your exact kernel. Place that config in the tree and use it for configuring.

I'm not a guru either and can't help too much beyond this suggestion. I would look carefully at the choice of going to mandrake, who seems to have more "issues" depends on how quickly one learns linux in general I think. Any system is going to have problems as you learn and break things... remember tho, this is fun!
LordMorgul is offline   Reply With Quote
Old 09-29-03, 06:31 AM   #5
LordMorgul
Electrical Engineer
 
LordMorgul's Avatar
 
Join Date: Dec 2002
Location: San Luis Obispo, CA
Posts: 872
Default

I realized that you're really intending to use custom kernels rather than redhat options, but if your hardware works on the redhat kernel at least a little, I would work on getting this done on that kernel first. Then go and install a new kernel and work with that one.

The main advantage of this is you get the glx component installed removing some of the potential problems from the custom kernel attempt.
LordMorgul is offline   Reply With Quote
Old 10-08-03, 11:52 AM   #6
johan_hammy
Registered User
 
Join Date: Oct 2003
Posts: 4
Default

Quote:
Originally posted by LordMorgul
You should install the rpms, boot the system on the new kernel and attempt the build and install.
I installed the RPMs, tried to build new drivers, no go. I attached my log. Maybe it's a totally different problem as I have been using Linux beyond a web server for about 3 days now.
Attached Files
File Type: log nvidia-installer.log (4.9 KB, 266 views)
johan_hammy is offline   Reply With Quote
Reply


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


Similar Threads
Thread Thread Starter Forum Replies Last Post
Corrupted display - 302.17 - Dell Precision T3500 (G98 [Quadro NVS 295]) gbailey NVIDIA Linux 1 06-27-12 10:24 AM
UEFI+Nvidia - NVRM: Your system is not currently configured to drive a VGA console... interzoneuk NVIDIA Linux 0 06-26-12 04:51 AM
xorg locks-up with newest nvidia drivers w/ vdpau. theroot NVIDIA Linux 1 06-24-12 11:04 AM
Red hat 7.3 kernel: 2.4.18-10 problems davidmah NVIDIA Linux 3 09-17-02 02:01 PM
Source RPMS for GCC3.2 - Red Hat 8.0? chrisw01 NVIDIA Linux 4 08-21-02 08:17 AM

All times are GMT -5. The time now is 07:25 PM.


Powered by vBulletin® Version 3.7.1
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Copyright 1998 - 2014, nV News.