LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 11-13-2008, 10:32 AM   #1
arbis
LQ Newbie
 
Registered: Oct 2008
Posts: 2

Rep: Reputation: 0
How to build kernel module


I was looking for some help/instructions on how to build a kernel module from source. I am running RHEL-5.1 kernel 2.6.18-53.el5 x86_64 and trying to build the xfs module. I tried finding the xfs module but am having trouble. Building it from source appears to be my only other option.
 
Old 11-13-2008, 11:18 AM   #2
rylan76
Senior Member
 
Registered: Apr 2004
Location: Potchefstroom, South Africa
Distribution: Fedora 17 - 3.3.4-5.fc17.x86_64
Posts: 1,552

Rep: Reputation: 103Reputation: 103
Well a first step would be to ensure that you have the kernel source for the kernel you are currently running available. Then, depending on what the module source you have specifies in its howto / building documentation you'll need to untar / unbzip the source in a directory, then go into that directory in a terminal and do something similar to this:

./configure --with-kernel-source=/usr/src/linux (or wherever your kernel sources are located)

make

make install

Then you might additionally need to do something like

modprobe <modulename>

to actually load the module once it has been compiled.
 
Old 11-13-2008, 12:28 PM   #3
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,520

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
"Compiling a module separately without compiling entire kernel"

see #4
http://www.linuxquestions.org/questi...5/#post3237765
 
  


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
Build 2.4 kernel module under 2.6 Ryanitus Linux - Software 1 09-15-2008 02:37 PM
[Error] Kernel Module : No kernel module build environment saman007uk Debian 7 09-09-2006 06:34 PM
LXer: Howto: build Linux kernel module against installed kernel w/o full kernel source tree LXer Syndicated Linux News 0 09-03-2006 08:21 PM
how to know whether a driver or other module build-in kernel ? jiawj Slackware 1 04-10-2005 02:21 AM
Unable to build NVIDIA kernel module / determin kernel version Night Ink Fedora 2 05-31-2004 04:54 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 04:22 AM.

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
Open Source Consulting | Domain Registration