Welcome to Linux Forums! With a comprehensive Linux Forum, information on various types of Linux software and many Linux Reviews articles, we have all the knowledge you need a click away, or accessible via our knowledgeable members.
Find the answer to your Linux question:
New to Linux Forums? Register here for free!
    Linux Forums > GNU Linux Zone > The Linux Kernel > [help] try to build loadable .ko file for a specific kernel (2.6.24-1-486)

Forgot Password?
 The Linux Kernel   Compiling, theory, programming or other discussion about the linux kernel

Site Navigation
Linux Articles
Linux Forums
Linux Downloads
Linux Hosting
Free Magazines
Job Board
IRC Chat
RSS Feeds


Linux Forum Topics
Linux Forums
Your Distro
Linux Resources
GNU Linux Zone
The Community
Reply
 
Thread Tools Display Modes
Old 4 Weeks Ago   #1 (permalink)
Just Joined!
 
Join Date: Oct 2009
Posts: 1
Angry [help] try to build loadable .ko file for a specific kernel (2.6.24-1-486)

In my project, I am trying to build a loadable .ko file for a Linux box with specific linux kernel (uname -r result is 2.6.24-1-486) installed on it.
This Linux box contains no directory named /lib/modules/2.6.24-1-486/build; it contains no related kernel header files for its 2.6.24-1-486 kernel. The remaining docs of it say that some test/unstable Debian release with 2.6.24 kernel may be OK to produce loadable .ko kernel modules for it.
I tried several 2.6.24 kernels, and just got the version verifying failure info below:
# insmod my_kernel_mod.ko
insmod: error inserting 'my_kernel_mod.ko': -1 Invalid module format
# dmesg|tail
my_kernel_mod: disagrees about version of symbol struct_module
my_kernel_mod: disagrees about version of symbol struct_module

Thus, I think I do need the Linux kernel source files (or just header files) with specific kernel version: 2.6.24-1-486. But, I cannot find this kind of 2.6.24-1-486 stuffs...

Does any know how to download the Linux kernel source files (or just header files) with specific kernel version 2.6.24-1-486??

Thanks a lot in advance.
dumbcoder is offline  


Reply With Quote
Old 3 Weeks Ago   #2 (permalink)
Trusted Penguin
 
waterhead's Avatar
 
Join Date: Jul 2004
Location: Franklin, Wisconsin
Posts: 3,957
Your using Debian? Try using apt to install those. You first need to gain root privileges, using sudo or su.

For the kernel source:
Code:
sudo apt-get install linux-source
For the headers, try using the uname -r , surrounded by backticks.
Code:
sudo apt-get install kernel-headers-`uname -r`
The purpose of that is to install the headers for the currently running kernel. If you run the uname -r command in a terminal (without the backticks), it will give you the currently running kernel. It is a method of running a command within another command.

That being said, it will not always work, and you may have to specify the exact header version to install. Open the Synaptic Package Manager, and look to see what is available to install.
__________________
Paul

Please do not PM me with requests for help. I will not reply.
waterhead is offline   Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

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
Trackbacks are Off
Pingbacks are Off
Refbacks are Off

Free Magazines
Run Your Own Web Server Using Linux & Apache - Free 191 Page Preview
Learn about everything you'll need to build and maintain your Linux servers, and to deploy Web applications to them.
subscribe
Open Source Security Myths Dispelled
Dispel the five major myths surrounding Open Source Security and gain the tools necessary to make a truly informed decision for your IT organization
subscribe
InformationWeek
InformationWeek is the only newsweekly you'll need to stay on top of the latest developments in information technology.
subscribe



All times are GMT. The time now is 04:33 AM.






© 2000 - 2009 - All Rights Reserved - Property of  MAS Media

Content Relevant URLs by vBSEO 3.3.0 RC2