LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 01-08-2004, 01:45 PM   #1
baldy3105
Member
 
Registered: Jan 2003
Location: Cambridgeshire, UK
Distribution: Mint (Desktop), Debian (Server)
Posts: 877

Rep: Reputation: 184Reputation: 184
Kernal doesn't match sources, I think??


Hi chaps,

I'm running SuSe 8.1 as a bog standard install straight off the CD. I have downloaded the nForce drivers and drivers for my GF 4400. These both seem to require the kernal sources to be present when you install them using a "make install" command.

Neither of these drivers work, I'm getting unresolved symbols when I try to load the modules using "lsmod".

The instructions say this is due to your kernal sources not matching your running kernal.

So I did a bit of reading and used the following commands -

linux:/home/everyone # uname -r
2.4.19-4GB
linux:/home/everyone # rpm -qa | grep kernal
linux:/home/everyone # rpm -qa | grep kernel
NVIDIA_kernel-1.0-5328
kernel-source-2.4.19.SuSE-49
linux:/home/everyone #

No to me this looks like my sources and my running kernal are different, yet it is a fresh install and the sources are from the same CD set. The only conclusion I can come to is that Suse have given me sources that don't match the kernal it installs, but I don't quite believe myself! Can someone confirm this for me?

I've looked on the Suse website for the matching sources but can't seem to locate them. If I use a kernal built from the new sources (I'm nothing if not willing to have a go!!) will this not trash all of the programs that suse installed for me? Don't I have to recompile just about everything?

Any help here would be appreciated

Cheers

Pete
 
Old 01-08-2004, 01:56 PM   #2
thebell
LQ Newbie
 
Registered: Dec 2003
Distribution: Gentoo
Posts: 25

Rep: Reputation: 15
What's in /usr/src? The source for the kernel you're running will probably be in /usr/src/linux-2.4.19-[something], if it's installed. Try installing that kernel-source-2.4.19.SuSE-49 RPM, and see if that helps. If that doesn't work, you could try getting a vanilla 2.4 kernel from kernel.org and installing that...
 
Old 01-08-2004, 02:22 PM   #3
baldy3105
Member
 
Registered: Jan 2003
Location: Cambridgeshire, UK
Distribution: Mint (Desktop), Debian (Server)
Posts: 877

Original Poster
Rep: Reputation: 184Reputation: 184
The directory under /usr/src says linux-2.4.19.SuSE, so that doesn't help much. I'm willing to have a go at building a new kernal but I want to know what the consequences will be before I do.
 
Old 01-08-2004, 02:59 PM   #4
h/w
Senior Member
 
Registered: Mar 2003
Location: New York, NY
Distribution: Debian Testing
Posts: 1,286

Rep: Reputation: 46
during first install, suse (or any distro) used a particular kernel.
then you went and said that you wanted a kernel source, so it went and got you some kernel source, which you will ideally see under /usr/src

did you build THAT kernel source? if not, how can you expect the running kernel and the kernel source you downloaded to match? i think it's a misnomer to say "install kernel source", as what they do is simply place the kernel src tree under /usr/src, and nothing more. the installation is upto you. it does nothing more than untar the kernel src in that dir.

so, you will have to build your kernel from the source sitting in /usr/src.
 
Old 01-09-2004, 03:52 PM   #5
baldy3105
Member
 
Registered: Jan 2003
Location: Cambridgeshire, UK
Distribution: Mint (Desktop), Debian (Server)
Posts: 877

Original Poster
Rep: Reputation: 184Reputation: 184
Hold on..... I buy a distribution and I need to install drivers cos the distro doesn't support my hardware. The drivers require kernal sources for my running kernal . I install the sources from the *same discs* that I used to install the distro and they are not the sources for the kernal that the distro installed? What sort of joke is that? Someone is definitely taking the wee-wee. I didn't want a new kernel, the driver didn't want a new kernal, just the sources for the kernel I've allready got.

I mean if its not enough for a noob like me to be ( quite gamely I might add) compiling drivers they go and stick a gotcha! like that in there. I'm all for learning new things but I don't need someone kicking me in the nuts while I'm doing it!

Can anyone answer my original question please? What are the effects on all of my programs which came with the distro if I go mucking about with the kernel, will they all still work?

Thanks

Pete

Last edited by baldy3105; 01-09-2004 at 03:55 PM.
 
Old 01-09-2004, 04:14 PM   #6
h/w
Senior Member
 
Registered: Mar 2003
Location: New York, NY
Distribution: Debian Testing
Posts: 1,286

Rep: Reputation: 46
you cant "muck" around with the kernel that was installed, as its a binary. you can, however, muck around with the source.
it's akin to this:
"This driver will work with windows XP. however, you have win95 installed. pls upgrade".
so, although you have windows, and you even have the winxp cd in ur cdrom, you cant install the driver, because it needs to see what it's asking for.

for that, you have to install.
 
Old 01-13-2004, 10:40 AM   #7
baldy3105
Member
 
Registered: Jan 2003
Location: Cambridgeshire, UK
Distribution: Mint (Desktop), Debian (Server)
Posts: 877

Original Poster
Rep: Reputation: 184Reputation: 184
Sorry I thought this was a simple question, let me restate it -

The drivers I need to compile expect to have kernal sources, which must match my running kernel. I don't have sources that match and can't seem to get hold of them.

I use the sources I can get which are a slightly different version forcing me to compile and install a new kernel just so that I can get matching kernel and kernel sources.

I'm with that so far, my driver will now compile and install and hopefully work, BUT I now have a different kernel to the one I started with.

So heres the key question - Do all my existing programs which worked with the original kernal still work with my new kernel? Doesn't the act of replacing the kernel with a slightly later version cause my entire body of existing software to stop working?

Guru point to anyone who can answer this as its obviously more complicated than I first thought.

Cheers all

Pete
 
Old 01-13-2004, 10:51 AM   #8
Chris H
Member
 
Registered: Aug 2003
Location: Farnborough, UK
Distribution: Zenwalk
Posts: 288

Rep: Reputation: 30
I've a copy of Debian woody which I installed. When I went to install my nvidia drivers I got exactly the same error as Pete.

The kernel sources supplied did not match the running kernel. uname -r gave me 2-4-20 and I only had up to 2-4-19 (or 18?)available on the install disk.

Never had the problem with any other distro. I assume, and also in this case, that someone's made a balls-up when the distros been put on disk.

Twas bloody annoying at the time. If I was a noob to linux I probably would've dropped the penguin as a lost cause.
 
Old 01-13-2004, 11:45 AM   #9
guygriffiths
Member
 
Registered: Jun 2003
Location: Reading, UK
Distribution: Debian 3.0, LFS
Posts: 524

Rep: Reputation: 36
Pete,
You are running a 2.4.19-4GB kernel i.e. version 2.4.19, with large memory support. Now your kernel sources are apparantly also version 2.4.19, but they are 2.4.19-SuSE-49 possibly because SuSE have made some changes to them, so although the source and runing version are very similar, they are not identical, which is what causes your problem (possibly).

HOWEVER, the answer to the question that you really want to know is this:
You can build a new kernel and eveything will be fine. You install it alongside the one old, in case a few things don't work, then you can always switch back to the old one. BUT YOU DON'T NEED TO RECOMPILE ANY OF YOUR PROGRAMS, THEY'LL ALL WORK. Sorry about the capitals, but someone had to shout it since you've been asking every post in this thread, and no-one answered you.

Also, if this is your first kernel compile, most likely nothing will work because you'll miss some vital bit out, but don't worry, just be sure to keep your old kernel in the bootloader, and you can always go back and recompile (and recompile, and recompile...)
Hope this helps
Guy
 
Old 01-14-2004, 11:34 AM   #10
baldy3105
Member
 
Registered: Jan 2003
Location: Cambridgeshire, UK
Distribution: Mint (Desktop), Debian (Server)
Posts: 877

Original Poster
Rep: Reputation: 184Reputation: 184
Thanks Guy! If thats the case I'll give it shot and see what happens.

Here we go again, happy as can be.........
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
kernal source and c headers don't match shelbydz Linux - Software 2 10-04-2006 06:45 PM
Ubuntu Sources List! I need some great sources lists! Jengo Linux - Newbie 1 06-24-2005 05:50 PM
kernal sources and headers BACTRATE Mandriva 2 04-18-2005 03:20 PM
Install Kernal-Sources Packages..? Mr.Moony Linux - Newbie 5 01-24-2004 11:50 AM
Software Sources Manager, how to add installation cd sources after deletion Lakota Mandriva 1 10-23-2003 01:39 AM


All times are GMT -5. The time now is 06:45 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration