LinuxQuestions.org
Review your favorite Linux distribution.
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 10-14-2005, 08:09 AM   #1
Zandu
LQ Newbie
 
Registered: Oct 2005
Posts: 3

Rep: Reputation: 0
Kernel module


hi all,
I just built my own kernel module(simple hello world) in Red hat 7.1 with kernel 2.4.7-10.
i complied that module so that it was listed in /proc/modules or sam by lsmod coomand.
But i am not geeting how to make that module to run during boot up?Where i have to made changes?
I tried by putting insmod mymodulename in /etc/rc.d/rc.local but it doesnt work

Help me frnds

Thanks in advance.

regards

Zandu
 
Old 10-15-2005, 02:49 AM   #2
s_deepak_123
Member
 
Registered: Oct 2004
Location: Mysore, India
Distribution: Fedora Core 1, Xandros desktop OS 2
Posts: 54

Rep: Reputation: 15
you can add it in /etc/rc.d/rc.modules

If insmod doesn't work, try /sbin/modprobe
 
Old 10-17-2005, 04:39 AM   #3
Zandu
LQ Newbie
 
Registered: Oct 2005
Posts: 3

Original Poster
Rep: Reputation: 0
hi ,
Thanks for reply that means after complining my module i add the line "insmod mymodule.o" in "/etc/rc.d/rc.modules"
and if it doesnt work i give command /sbin/modprobe by the way tell wat will be path from where modprobe take modules..
 
Old 10-17-2005, 11:55 PM   #4
s_deepak_123
Member
 
Registered: Oct 2004
Location: Mysore, India
Distribution: Fedora Core 1, Xandros desktop OS 2
Posts: 54

Rep: Reputation: 15
modprobe looks in /lib/modules/<kernel-version>/
Ex:
if the kernel version is 2.4.29 then, the path will be
/lib/modules/2.4.29/
 
Old 10-19-2005, 06:26 AM   #5
Zandu
LQ Newbie
 
Registered: Oct 2005
Posts: 3

Original Poster
Rep: Reputation: 0
hi,
That means I should place my module in /lib/modules/2.4.29/
 
Old 10-19-2005, 06:35 AM   #6
s_deepak_123
Member
 
Registered: Oct 2004
Location: Mysore, India
Distribution: Fedora Core 1, Xandros desktop OS 2
Posts: 54

Rep: Reputation: 15
yes.
create a directory in that path and place that module in it.
Ex: mkdir /lib/modules/2.4.29/misc
cp /myhome/mymodule /lib/modules/2.4.29/misc/
 
  


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
Can a kernel module call the function of another kernel module sceadu Programming 3 05-02-2011 02:22 AM
[Error] Kernel Module : No kernel module build environment saman007uk Debian 7 09-09-2006 06:34 PM
Building kernel module from multiple source file in 2.6 kernel yogeshwar_s Programming 1 12-20-2004 09:31 AM
Unable to build NVIDIA kernel module / determin kernel version Night Ink Fedora 2 05-31-2004 04:54 PM
kernel module ignorant newbie looking for any one with kernel module knowledge cpoet Slackware 4 11-24-2003 09:37 PM

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

All times are GMT -5. The time now is 07:56 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
Open Source Consulting | Domain Registration