LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
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 11-22-2006, 10:12 PM   #1
JAKK
Member
 
Registered: Jun 2006
Distribution: Slackware 11
Posts: 92

Rep: Reputation: 15
After kernel compile,I don't think the modules are loading


Hi. I just compiled a custom 2.4.33.4 kernel for my laptop. I followed the guide at digital hermit to the letter. Everything went fine,and my new kernel boots up fineand works like the old one did. However,when I do a lsmod,noting shows up. This is confirmed by my my sound not working,when I try to do a modprobe,it says it can't find the module. All modules load on the original kernel. I'm hoping I just made a stupid easy to fix error. I noticed when it modprobes rc.modules,it is
rc.modules-->rc.modules-2.4.33.3.
 
Old 11-22-2006, 10:14 PM   #2
masonm
Senior Member
 
Registered: Mar 2003
Location: Following the white rabbit
Distribution: Slackware64 -current
Posts: 2,299

Rep: Reputation: 89
When you compiled the kernel did you do a "make modules" and a "make modules_install" ?
 
Old 11-22-2006, 10:20 PM   #3
JAKK
Member
 
Registered: Jun 2006
Distribution: Slackware 11
Posts: 92

Original Poster
Rep: Reputation: 15
Hi. Yes I did,I followed the instructions on the digital hermit site to the letter. However,I did delete the files in /usr/src after I booted into the new kernel to free up space.
 
Old 11-22-2006, 10:29 PM   #4
Spinlock
Member
 
Registered: Jan 2006
Location: Missouri
Distribution: Slackware -current, Slackware64 -current, Slackware 12.2
Posts: 150

Rep: Reputation: 24
What does ls /lib/modules show?
 
Old 11-22-2006, 10:42 PM   #5
JAKK
Member
 
Registered: Jun 2006
Distribution: Slackware 11
Posts: 92

Original Poster
Rep: Reputation: 15
ls /lib/modules shows 2.4.33.3 and 2.4.33.4.
 
Old 11-22-2006, 10:55 PM   #6
masonm
Senior Member
 
Registered: Mar 2003
Location: Following the white rabbit
Distribution: Slackware64 -current
Posts: 2,299

Rep: Reputation: 89
Change the symlink /etc/rc.d/rc.modules from the old kernel version to the new one.
 
Old 11-22-2006, 11:10 PM   #7
JAKK
Member
 
Registered: Jun 2006
Distribution: Slackware 11
Posts: 92

Original Poster
Rep: Reputation: 15
Do you mean
Code:
ln -s rc.modules rc.modules-2.4.33.4
? There is no rc.modules-2.4.33.4 in /etc/rc.d.
 
Old 11-22-2006, 11:16 PM   #8
masonm
Senior Member
 
Registered: Mar 2003
Location: Following the white rabbit
Distribution: Slackware64 -current
Posts: 2,299

Rep: Reputation: 89
Quote:
Originally Posted by JAKK
Do you mean
Code:
ln -s rc.modules rc.modules-2.4.33.4
? There is no rc.modules-2.4.33.4 in /etc/rc.d.
Well there's a problem. I'm not familiar with the instructions you followed. When you compiled the kernel did you do a "make install" at the end? It normally creates all of the needed files.
 
Old 11-22-2006, 11:22 PM   #9
JAKK
Member
 
Registered: Jun 2006
Distribution: Slackware 11
Posts: 92

Original Poster
Rep: Reputation: 15
Hi. No,I did not do a make install. The instructions I followed were here.Are those accurate?

Last edited by JAKK; 11-22-2006 at 11:39 PM.
 
Old 11-22-2006, 11:48 PM   #10
masonm
Senior Member
 
Registered: Mar 2003
Location: Following the white rabbit
Distribution: Slackware64 -current
Posts: 2,299

Rep: Reputation: 89
Quote:
Originally Posted by JAKK
Hi. No,I did not do a make install. The instructions I followed were here.Are those accurate?
Well, there are as many opinions on compiling kernels as there are cats in a fish house dumpster, but that's not the way I do it and I've never had a problem compiling a kernel on Slack.

The first thing I do is rename my /boot/vmlinuz to something like /boot/vmlinuz-old. Then edit lilo to reflect the change. this ensures having a menu option to boot the old kernel if the new one is borked.

Then, after doing the make menuconfig I do a "make && make modules && make modules_install"

Once the compiling is finished I do a "make install". This installs the kernel image and all other needed files for Slack and runs lilo for you. Just double check the lilo.conf to make sure it has menu entries for both the new and old kernels.

I've never had one fail on me yet.


edit:

I forgot to mention this. you shouldn't delete your kernel source files. There are some things that require them to compile properly.

Last edited by masonm; 11-22-2006 at 11:55 PM.
 
Old 11-23-2006, 12:21 AM   #11
JAKK
Member
 
Registered: Jun 2006
Distribution: Slackware 11
Posts: 92

Original Poster
Rep: Reputation: 15
If there is no way for me to fix this,will compiling the kernel again write over the old stuff,or do I need to delete something?

Last edited by JAKK; 11-23-2006 at 03:37 AM.
 
Old 11-23-2006, 08:36 AM   #12
masonm
Senior Member
 
Registered: Mar 2003
Location: Following the white rabbit
Distribution: Slackware64 -current
Posts: 2,299

Rep: Reputation: 89
Quote:
Originally Posted by JAKK
If there is no way for me to fix this,will compiling the kernel again write over the old stuff,or do I need to delete something?
You can recompile the kernel and it will write what it needs to write if done correctly. No need to delete anything.

Just be sure to compile in your file systems and ensure that lilo updates correctly. Even though make install runs lilo, I always check the lilo.conf and run lilo again ( a little anal maybe but ensures no problems).
 
Old 11-23-2006, 03:06 PM   #13
JAKK
Member
 
Registered: Jun 2006
Distribution: Slackware 11
Posts: 92

Original Poster
Rep: Reputation: 15
Hi. I followed your advice,but something still isn't right. I reinstalled the kernel source,patched it,and then ran mrproper to clean everything up. One thing I should note is that when I patch the kernel,it says a hunk failed patching the makefile.

When I look at the Makefile.rej,the only difference is that the version number was supposed to be changed to .4,which I did. Next,I ran xconfig,and after I finished it,it told me to run make dep,which I did along with make clean after it.


Next,I ran the command you gave me to make the modules,which worked fine and took some time like it should. After that, I ran make install,which seemed to run okay. However,at the end when it ran lilo,it just said added *linuxold which was what I renamed my current kernel. When I went to /boot,the only new image was bzImage-2.4.33.4 which I believe is the old one I crated. There were no new entries in lilo.conf,and I added one pointing to the bzImage,but lilo doesn't show it because I think it is just the name left over. So to make things clear,the only thing in /boot that works is vmlinuzold which is my original kernel.

EDIT: When I patch it,there are a bunch of messages saying previously applied or reversed patches detected,and they ask me if I want to assume -R. I say yes to these files,and then they patch. If I say no,they fail. Could this be causing the problem?

Last edited by JAKK; 11-23-2006 at 03:32 PM.
 
Old 11-23-2006, 03:39 PM   #14
Alien Bob
Slackware Contributor
 
Registered: Sep 2005
Location: Eindhoven, The Netherlands
Distribution: Slackware
Posts: 7,727

Rep: Reputation: 6295Reputation: 6295Reputation: 6295Reputation: 6295Reputation: 6295Reputation: 6295Reputation: 6295Reputation: 6295Reputation: 6295Reputation: 6295Reputation: 6295
Quote:
Originally Posted by JAKK
After that, I ran make install,which seemed to run okay.
So, following the Digital Hermit's instructions or not, makes no difference? There could be another snag in the succession of steps you took. I'd try again using the digitalhermit instructions, they're safe and should work.
Maybe you can get some more inspiration from my Wiki page.

After re-reading your post, is there really no physical file /etc/rc.d/rc.modules? Just a symlink pointing to /etc/rc.d/rc.modules-2.4.33.3 ?
Installing a kernel from source won't fix that link, only a Slackware package would do that. This, you have to do yourself:
Code:
rm /etc/rc.d/rc.modules
cp -a /etc/rc.d/rc.modules-2.4.33.3 /etc/rc.d/rc.modules
and then try reboot. The rc.modules does not need to be a symlink - it will work if it is a real file.

Eric
 
Old 11-23-2006, 03:58 PM   #15
masonm
Senior Member
 
Registered: Mar 2003
Location: Following the white rabbit
Distribution: Slackware64 -current
Posts: 2,299

Rep: Reputation: 89
When you ran make install it should have created a new kernel image called /boot/vmlinuz. Are you saying that it didn't?

If this is the case I have to assume that something, somewhere in your initial install got borked if make install didn't put a new vmlinuz in your /boot directory.

What patch were you applying to the kernel? It's normal to see some error messages when applying a patch and in most cases that's nothing to be concerned about.
 
  


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
Loading Kernel Modules superdude_876 Linux - Software 1 10-29-2005 12:46 AM
Loading modules in Debian 3.1(kernel 2.6) swmok Debian 8 06-23-2005 01:16 PM
Loading modules error after loading compiled kernel td0l2 Linux - Newbie 12 07-28-2004 12:10 PM
Loading Correct Kernel Modules rridler Linux - Newbie 4 04-15-2004 05:37 PM
Modules not loading in New kernel palanisaravanan Linux - General 1 11-22-2003 07:31 AM

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

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