LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 05-15-2008, 07:11 PM   #1
okos
Member
 
Registered: May 2007
Location: California
Distribution: Slackware/Ubuntu
Posts: 609

Rep: Reputation: 38
New kernel using old modules???????


Hi
I built a new kernel 2.6.25.3-dell
However at boot one of the messages I get is:
Quote:
running modules /etc/rc.d/rc.modules > rc.modules-2.6.24.5-smp
I did make modules_install

I do have the modules
Quote:
ls /lib/modules
512 2.6.24.5 512 2.6.24.5-smp 512 2.6.25.3-dell
In /etc/rc.d there is no rc.modules-2.6.25.5-dell

After compiling and installing the new kernel, what should I do to get the computer to boot with the new modules?
 
Old 05-15-2008, 07:28 PM   #2
MS3FGX
LQ Guru
 
Registered: Jan 2004
Location: NJ, USA
Distribution: Slackware, Debian
Posts: 5,852

Rep: Reputation: 361Reputation: 361Reputation: 361Reputation: 361
If you are actually running the new kernel (use uname -r) then the system is using the modules that correspond to that kernel. Modules from one kernel can't be loaded into another kernel, the boot messages are really inconsequential here; it is referring to the fact that the list of modules to manually load is from the original Slackware kernel, but the kernel is going to load the modules required regardless in most situations, so it is meaningless.
 
Old 05-15-2008, 07:29 PM   #3
T3slider
Senior Member
 
Registered: Jul 2007
Distribution: Slackware64-14.1
Posts: 2,367

Rep: Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843
/etc/rc.d/rc.S loads the first rc.modules file it finds, looking in the following order:
rc.modules.local
rc.modules-$(uname -r)
rc.modules

You could just create an rc.modules.local file that you could keep consistent across kernel compiles (assuming you don't change any kernel options that affect the extra modules you're trying to load), or you could create (or modify) /etc/rc.d/rc.modules-$(uname -r) (in your case, /etc/rc.d/rc.modules-2.6.25.3-dell). Right now, there is no rc.modules.local, and there is no /etc/rc.d/rc.modules-2.6.25.3-dell, so it is running /etc/rc.d/rc.modules, which is a symlink to rc.modules-2.6.24.5-smp in a default Slackware 12.0 setup. You should copy the /etc/rc.d/rc.modules-2.6.24.5-smp file to /etc/rc.d/rc.modules-2.6.25.3-dell and edit the resulting file, removing modules that are compiled into the kernel by default (or that you just don't need) and adding any modules that you do need loaded. The default rc.modules file is actually quite small (type `grep -v \# /etc/rc.d/rc.modules | uniq -u | less` to see the whole file without comments -- it really is small). You probably won't have to change much either -- but make sure you look through it and change anything that stands out. If you get any errors during bootup about module loading, it probably has to do with this file.

Reboot your PC after creating rc.modules-2.6.25.3-dell and make sure that the correct file is being used (it should say "Running rc.modules-2.6.25.3-dell" during bootup -- but the message won't be present in any logs).

[edit]Although MS3FGX is correct that the correct kernel modules are being used (ie the kernel modules that you compiled with your kernel), and the message is basically inconsequential, there may be other errors involving trying to load a module that is already loaded (because it is compiled into your kernel instead of as a module) depending on your kernel options. You really should update rc.modules for EACH kernel that you compile, especially when you're changing from the default kernel -- I would still recommend creating either rc.modules-2.6.25.3-dell or rc.modules.local. rc.modules.local would survive even if you compiled a newer kernel version, while rc.modules-2.6.25.3-dell would have to be copied/renamed to update a newer kernel version -- it should be rc.modules-$(uname -r). Either way, if you compile a new kernel version, make sure that there are no conflicting modules being loaded compared to what is compiled into the kernel. If you don't change much between kernel builds, a consistent rc.modules.local should do fine except in rare cases.[/edit]

Last edited by T3slider; 05-15-2008 at 07:35 PM.
 
Old 05-15-2008, 09:35 PM   #4
okos
Member
 
Registered: May 2007
Location: California
Distribution: Slackware/Ubuntu
Posts: 609

Original Poster
Rep: Reputation: 38
WOW that was alot of info! I guess I still have alot of work to do.
Thanks for the response.

I still consider myself a noobie.

I believe in the kiss method.

So I guess this what I should do? Please correct me if Im wrong.
1. cp rc.modules-2.6.24.5-smp rc.modules.local
2. edit rc.modules.local according to my system.
3. ln -s rc.modules rc.modules.local

One more question:

I installed madwifi driver for athuros chipsets. After compiling, I had to modprob ath_pci. From what I understand, that command is telling the kernel that there is a new module.

So after compiling a new kernel, I guess madwifi would not work until I modprob the new kernel. Is that correct?
 
Old 05-15-2008, 10:33 PM   #5
T3slider
Senior Member
 
Registered: Jul 2007
Distribution: Slackware64-14.1
Posts: 2,367

Rep: Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843
Quote:
Originally Posted by okos
So I guess this what I should do? Please correct me if Im wrong.
1. cp rc.modules-2.6.24.5-smp rc.modules.local
2. edit rc.modules.local according to my system.
3. ln -s rc.modules rc.modules.local
Sounds good. Symlinking rc.modules to rc.modules.local isn't necessary (since rc.modules.local is checked before it), but it doesn't hurt and it'll at least remind you that your modules are loaded from rc.modules.local and not some other rc.modules file.

Quote:
Originally Posted by okos
I installed madwifi driver for athuros chipsets. After compiling, I had to modprob ath_pci. From what I understand, that command is telling the kernel that there is a new module.

So after compiling a new kernel, I guess madwifi would not work until I modprob the new kernel. Is that correct?
`modprobe` loads a kernel module into the running system (and it's dependencies), providing a driver to interface with the hardware. If the correct module is not loaded, your system won't be able to recognize the hardware and you won't be able to use it. In order to get your WiFi connection started, the ath_pci module must be loaded. udev might actually load the driver upon a reboot without you needing to manually `modprobe` it -- after your next reboot, check the output of `lsmod | grep ath`. If it returns the ath_pci module, then it's already running and your wireless connection should work without you having to load the module manually. If it doesn't, however, you should add the following line to /etc/rc.d/rc.modules.local:
Code:
/sbin/modprobe ath_pci
See here for more detailed information on using madwifi in Slackware: http://alien.slackbook.org/dokuwiki/...ckware:madwifi

[edit]It should also be noted that you may have to recompile the madwifi driver for each new kernel that you compile (usually modules will only work with the kernel version they are compiled for). Instructions for doing that are also provided at the above link.[/edit]

Last edited by T3slider; 05-15-2008 at 10:37 PM.
 
Old 05-15-2008, 11:59 PM   #6
okos
Member
 
Registered: May 2007
Location: California
Distribution: Slackware/Ubuntu
Posts: 609

Original Poster
Rep: Reputation: 38
Thank you for all of your help!
It is greatly appreciated.
okos
 
  


Reply



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
/lib/modules/2.4.33.3/kernel/sound folder is missing after compiling kernel Paulo Góes Slackware - Installation 2 04-15-2007 08:42 PM
Kernel Modules in /lib/modules kaplan71 Linux - General 1 04-02-2007 11:00 AM
Kernel Modules and modules.conf init Linux - General 0 02-20-2004 06:51 PM
new kernel (2.4.22 up from 2.4.20-6) - missing modules - use old modules? Simon Bridge Linux - Software 1 02-04-2004 05:52 AM
Kernel modules: why are some kernel modules zipped? hampel Slackware 3 06-30-2003 06:33 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 08:09 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