LinuxQuestions.org
Help answer threads with 0 replies.
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-26-2003, 06:12 PM   #1
Bruce Hill
HCL Maintainer
 
Registered: Jun 2003
Location: McCalla, AL, USA
Distribution: Gentoo (all servers at work are openSUSE)
Posts: 6,938

Rep: Reputation: 128Reputation: 128
recompiled kernel and no vmlinuz.old or kernel module for Nvidia


I installed Slackware 9.1 a couple weeks ago and life's been grand...until yesterday when I compiled and installed a new kernel. I printed and followed DaOne's newbie install guide. I've recompiled kernel's in Debian before so I even had an old .config printed for referral.

I got two problems:

First->

When I did make I got an error ->
make: *** [vmilinux] Error 1
This followed some lines about undefined reference to `ip_conntrack_module'
Since I got no xserver in Slack right now I'm typing from digital photos and using Mozilla in W2K. Will post more of that if it's needed.
Even with that error I continued the kernel compile and install.

Now I got kernel 2.4.22 but no Slack.old, and even if I use the Slack boot floppy I created on the orginal install I only get this new kernel.

Second->

$ startx
returns this error
(EE) NVIDIA (0): Failed to initialize the NVIDIA kernel module!

My video card is Nvidia GeForce FX 5200. On the original install I followed the instructions from Nvidia (basically sh NVIDIA file) and everything worked okay. I tried that with this new kernel and I got several errors.

No precompiled kernel interface was found so it wanted to contact the Nvidia site, but couldn't because of a temporary DNS error. (With the kernel compile I installed support for both my nics, but I got a static IP address in my router, but don't know where to config. Debian was /etc/network/interfaces but no such file in Slack.) Since it couldn't reach Nvidia the installer tried to compile a kernel interface but couldn't because it says->
Unable to load the kernel module `nvidia.o' . This is most likely because the kernel module was built using the wrong kernel header files. etc...
I've downloaded kernel-source-2.4.22-noarch-3.tgz but don't know how to untar this and if this is what I need to do.

A push in the right direction would be appreciated. While I could have reinstalled Slackware quicker than taking these digital photos and posting through the other OS, I wouldn't learn how to fix what I messed up that way.

Last edited by Bruce Hill; 11-26-2003 at 06:31 PM.
 
Old 11-26-2003, 07:13 PM   #2
DaOne
Member
 
Registered: Jan 2003
Location: USA
Distribution: Slackware
Posts: 498

Rep: Reputation: 30
Just copy it to /usr/src and untar...tar xvf kernel-source-2.4.22-noarch-3.tgz

Then you can descend into the linux2.4.22 directory and compile from there. Or create a link as /usr/src/linux. Don't forget to edit the Makefile, edit Lilo, and copy your existing .config if you plan to use the config from the working kernel as a starting point.

You may then need to install the Nvidia stuff again...I know with my Radeon 9700 I have to.
 
Old 11-26-2003, 07:17 PM   #3
Azmeen
Senior Member
 
Registered: May 2003
Location: Malaysia
Distribution: Slackware, LFS, CentOS
Posts: 1,307

Rep: Reputation: 46
OK, first things first... Every time you recompile your kernel, and made the necessary adjustments in lilo.conf, don't forget to run /sbin/lilo. Most of the time, this is the culprit.

Another thing, DaOne recommends the make install option... well, I'm from the other school of thought which believes, "If possible, make sure you do everything yourself". No offense to DaOne, I'm just a little bit paranoid when it comes to my kernel . So just for the sake of it, copy your new kernel (/usr/src/linux/arch/i386/boot/bzImage) over to /boot manually... along with the System.map file.
 
Old 11-26-2003, 07:54 PM   #4
Bruce Hill
HCL Maintainer
 
Registered: Jun 2003
Location: McCalla, AL, USA
Distribution: Gentoo (all servers at work are openSUSE)
Posts: 6,938

Original Poster
Rep: Reputation: 128Reputation: 128
Thanks for the help.

I did /sbin/lilo but it didn't do the vmlinuz.old for some reason. My original Slack kernel was vmlinuz-ide-2.4.22 or something like that. Now I got only one kernel and that's the new one.

I can copy the bzImage and System.map if that's necessary. If I do that do I omit the make install step?

When I compile the kernel, do I put the vesa framebuffer?

And with the bare.i install it detected my secondary Realtek 8139 but when I compiled that and the onboard Tigon3 into the new kernel, now I got that DNS error so I assume neither nic is properly setup.

It also has a list of modules that it doesn't install as it boots, which I think is all the modules I added.

Perhaps I can get back in and edit the /etc/rc.d/rc.modules file again. Once I'm able to check a couple more things against your posts, I'll try to post back something more intelligent.
 
Old 11-26-2003, 09:14 PM   #5
Bruce Hill
HCL Maintainer
 
Registered: Jun 2003
Location: McCalla, AL, USA
Distribution: Gentoo (all servers at work are openSUSE)
Posts: 6,938

Original Poster
Rep: Reputation: 128Reputation: 128
Quote:
Originally posted by DaOne
Just copy it to /usr/src and untar...tar xvf kernel-source-2.4.22-noarch-3.tgz

Then you can descend into the linux2.4.22 directory and compile from there. Or create a link as /usr/src/linux. Don't forget to edit the Makefile, edit Lilo, and copy your existing .config if you plan to use the config from the working kernel as a starting point.

You may then need to install the Nvidia stuff again...I know with my Radeon 9700 I have to.
I'm not totally sure I understand. Are you saying to redo the kernel compile again? And I did edit both the Makefile and lilo.conf before I started. I'll post 3 files and maybe someone can tell what I messed up.


Code:
root@paul:/usr/src# ls -aFlc
total 8
drwxr-xr-x    5 root     root          192 Nov 20 16:28 ./
drwxr-xr-x   20 root     root          704 Nov 23 08:05 ../
-rw-r--r--    1 root     root          567 Nov 20 16:28 2.4.22.nat.diff
lrwxrwxrwx    1 root     root           12 Nov 20 16:28 linux -> linux-2.4.22/
drwxr-xr-x   15 root     root          688 Nov 26 07:32 linux-2.4.22/
drwxr-xr-x    7 root     root          168 Nov 20 16:27 rpm/
drwxr-xr-x    2 root     root          432 Nov 20 16:28 xfs-2.4.22/

root@paul:/boot# ls -aFlc
total 1871
drwxr-xr-x    3 root     root          304 Nov 26 07:33 ./
drwxr-xr-x   20 root     root          456 Nov 27 09:36 ../
lrwxrwxrwx    1 root     root           21 Nov 20 16:26 System.map -> System.map-ide-2.4.22
-rw-r--r--    1 root     root       609166 Nov 20 16:26 System.map-ide-2.4.22
-rw-r--r--    1 root     root          512 Nov 20 16:51 boot.0300
lrwxrwxrwx    1 root     root           17 Nov 20 16:26 config -> config-ide-2.4.22
-rw-r--r--    1 root     root        38645 Nov 20 16:26 config-ide-2.4.22
-rw-------    1 root     root        28672 Nov 20 16:51 map
lrwxrwxrwx    1 root     root           18 Nov 20 16:26 vmlinuz -> vmlinuz-ide-2.4.22
-rw-r--r--    1 root     root      1226706 Nov 20 16:26 vmlinuz-ide-2.4.22

root@paul:/boot# pico /etc/lilo.conf
(only the applicable portion)
# Linux bootable partition config begins
image = /boot/vmlinuz
  root = /dev/hda8
  label = Slack
  read-only # Non-UMSDOS filesystems should be mounted read-only for checking
image = /boot/vmlinuz.old
  root = /dev/hda8
  label = Slack.old
  read-only # Non-UMSDOS filesystems should be mounted read-only for checking
# Linux bootable partition config ends
# DOS bootable partition config begins
other = /dev/hda1
  label = Windoze
  table = /dev/hda
# DOS bootable partition config ends
 
Old 11-27-2003, 12:10 AM   #6
Azmeen
Senior Member
 
Registered: May 2003
Location: Malaysia
Distribution: Slackware, LFS, CentOS
Posts: 1,307

Rep: Reputation: 46
From your listing it seems that your make install didn't work... Did you uncomment this line in your Makefile (as instructed by DaOne):
Code:
#export INSTALL_PATH=/boot
Anyway, I'd say you'll be OK if you just do these few steps:
1) cp /usr/src/linux/arch/i386/boot/bzImage /boot/vmlinuz-new-2.4.22
2) rm /boot/System.map && cp /usr/src/linux/System.map /boot
3) Change your lilo.conf from:
Code:
image = /boot/vmlinuz.old
  root = /dev/hda8
  label = Slack.old
to:
Code:
image = /boot/vmlinuz-new-2.4.22
  root = /dev/hda8
  label = Slack.New
4) Run /sbin/lilo
5) Say prayers and reboot into new kernel at Slack.New



As for the nvidia drivers, you have to run the bin file every time you recompile your kernel.
 
Old 11-27-2003, 10:12 AM   #7
DaOne
Member
 
Registered: Jan 2003
Location: USA
Distribution: Slackware
Posts: 498

Rep: Reputation: 30
I think Azmeen hit the nail on the head. If you did edit Makefile correctly, and for some reason make install doesn't work, then the above instructions will be a complete substitute for make install, and should fix the issue. Good luck.
 
Old 11-28-2003, 08:45 AM   #8
Bruce Hill
HCL Maintainer
 
Registered: Jun 2003
Location: McCalla, AL, USA
Distribution: Gentoo (all servers at work are openSUSE)
Posts: 6,938

Original Poster
Rep: Reputation: 128Reputation: 128
Just wanted to thank you guys for the help. I've had a visitor from America, and had about 5 other computers to build/repair, plus a sick daughter; so I haven't had time to look at my Slack system again. I'll do it in the morning.

Three questions, though ->

First, before I compile again, should I remove the kernel I just compiled?

Second, could I rename vmlinuz-ide-2.4.22 as Slack.old? That was the original kernel from the Slack 9.1 bare.i installation.

Third, where do I config my two nics? I went to /etc/rc.d/rc.inet1 and /etc/rc.d/rc.netdevices but for some reason I get the error I posted before about it not being able to reach the Nvidia site that's in my first post. I don't think the new kernel is detecting either of my nics, but I don't know where to change the settings? I have a router and an ADSL modem, and I use static IP addresses through my router. My ISP assigns a dynamic address.


Sorry for the ignorance. I haven't had any time to read and won't for at least 3 more days. You don't have to do research for me, but if you remember where or how to config net devices in Slack I'd appreciate it. For some reason I believe that I've got the kernel header files, because they were apparently there in the bare.i install, and I was able to install the Nvidia drivers before with no problem. I think if I can get this new kernel on the net that Nvidia site will take care of the problem with the Nvidia kernel module.


NB: DaOne, your sig is so true!
 
Old 12-10-2003, 08:51 PM   #9
Scruff
Member
 
Registered: Oct 2002
Location: Stoughton, MA
Distribution: Gentoo x86_64 & PPC
Posts: 949

Rep: Reputation: 30
The command 'netconfig' is used to configure your connection (static IP and NIC-->ethX). Do 'lsmod' to see if you have the necessary drivers loaded for your NIC's, then if you want to specify which one to use, edit modules.conf and add an alias like "alias eth0 drivername" w/out the quotes
Otherwise, I think Slack will call whichever module appears first in lsmod, eth0.
 
Old 12-10-2003, 10:31 PM   #10
Bruce Hill
HCL Maintainer
 
Registered: Jun 2003
Location: McCalla, AL, USA
Distribution: Gentoo (all servers at work are openSUSE)
Posts: 6,938

Original Poster
Rep: Reputation: 128Reputation: 128
Quote:
Originally posted by Scruff
The command 'netconfig' is used to configure your connection (static IP and NIC-->ethX). Do 'lsmod' to see if you have the necessary drivers loaded for your NIC's, then if you want to specify which one to use, edit modules.conf and add an alias like "alias eth0 drivername" w/out the quotes
Otherwise, I think Slack will call whichever module appears first in lsmod, eth0.
Thanks, Scruff - and Happy Birthday! I was trying to do too many things at once and couldn't remember 'netconfig'. I ran it the next day after that post and all is well

I've got my new kernel compiled - finally. Here's what I did ->

First, the make install step in DaOne's newbie install guide didn't work for me - on two attempts. So I used the method Azmeen suggested, of omitting make install and copying the bzImage and editing LILO by hand. This works great. Here is what my /boot looks like ->
Code:
mingdao@paul:~$ ls -aFlc /boot
total 4251
drwxr-xr-x    3 root     root          384 Dec  7 18:25 ./
drwxr-xr-x   20 root     root          456 Dec 11 07:09 ../
lrwxrwxrwx    1 root     root           21 Dec  2 02:43 System.map -> System.map-ide-2.4.22
-rw-r--r--    1 root     root       609166 Dec  2 02:43 System.map-ide-2.4.22
-rw-r--r--    1 root     root       697857 Dec  7 18:23 System.map-new-2.4.23
-rw-r--r--    1 root     root          512 Dec  2 06:05 boot.0300
lrwxrwxrwx    1 root     root           17 Dec  2 02:43 config -> config-ide-2.4.22
-rw-r--r--    1 root     root        38645 Dec  2 02:43 config-ide-2.4.22
-rw-------    1 root     root        47104 Dec  7 18:25 map
lrwxrwxrwx    1 root     root           18 Dec  2 02:43 vmlinuz -> vmlinuz-ide-2.4.22
-rw-r--r--    1 root     root      1226706 Dec  2 02:43 vmlinuz-ide-2.4.22
-rw-r--r--    1 root     root      1715369 Dec  7 18:19 vmlinuz-new-2.4.23
And I didn't have to omit my old kernel, either, I just put an entry for each one in /etc/lilo.conf like this ->
Code:
# Linux bootable partition config begins
image = /boot/vmlinuz-new-2.4.23
  root = /dev/hda8
  label = Slack-2.4.23
  read-only # Non-UMSDOS filesystems should be mounted read-only for checking

image = /boot/vmlinuz-ide-2.4.22
  root = /dev/hda8
  label = Slack-2.4.22
  read-only

# Linux bootable partition config ends
The command tar xvf as suggested in another post (Just copy it to /usr/src and untar...tar xvf kernel-source-2.4.22-noarch-3.tgz) does not work. You must do installpkg <filename> with .tgz files.

I tried to build the kernel using installpkg with kernel-source-2.4.23-noarch-2.tgz (and omitted make install) but when I finished and wanted to copy the bzImage file to /boot it wasn't in /usr/src/linux/arch/i386/boot. Instead, there was a file (vmlinux-2.4.23*) in /usr/src/linux - with that asterisk beside it. I tried to copy that to /boot but it wouldn't work. When I ran lilo it said the image was too large. Maybe that's how you have to get the make install step to work properly - using the .tgz kernel and installpkg? I don't know.

Can someone tell me if I should use the kernel-source .tgz file with that compile guide, or a .bz2 file? And has anyone tried compiling a kernel in Slack 9.1 with those instructions? Just curious. I've put Knoppix on my wife and daughter's comp temporarily, but will install Slack when I get the time. I'll try that guide again, maybe this time using installpkg with the .tgz file, and see how it works.

I'm new and still reading and learning.

There's only so many hours in a day, and sometimes I have to "use my computer to do work" rather than "work on my computer to use it" so I have to boot into Windoze and get the job done.
 
Old 12-10-2003, 10:40 PM   #11
Scruff
Member
 
Registered: Oct 2002
Location: Stoughton, MA
Distribution: Gentoo x86_64 & PPC
Posts: 949

Rep: Reputation: 30
Quote:
Originally posted by Chinaman
Thanks, Scruff - and Happy Birthday! I was trying to do too many things at once and couldn't remember 'netconfig'. I ran it the next day after that post and all is well
Thanks

As for installing that kernel.tgz, what happens is: when you did installpkg kernel.tgz, it simply installed the source in the /usr/src directory. I think it still needs to be compiled after that to create the bzImage. That's how I did it anyway, when I used Slack 9.0 (with 2.4.20) and installed the .tgz for 2.4.22.. I couldn't get UDMA to work properly with 2.4.20 on my hardware.

Thats weird though that DaOne's guide didn't work out for you. I still refer to it and it's worked for me every time (though I have taken to manually copying the new image lately).

Thanks for that guide by the way, DaOne
 
Old 12-11-2003, 12:02 AM   #12
Scruff
Member
 
Registered: Oct 2002
Location: Stoughton, MA
Distribution: Gentoo x86_64 & PPC
Posts: 949

Rep: Reputation: 30
Check this out: http://linuxtoday.com/security/2003120203026SCKNSL
Looks like you can upgrade your kernel to 2.4.23 by using 'upgradepkg kernelname.tgz' then upgrading the necessary packages along with it. I learn something new about pkgtool all the time! It's quite a bit more useful than I initially thought. I assume this could also be accomplised a bit more 'automatic' by just using Swaret to update.
 
Old 12-11-2003, 02:24 AM   #13
Azmeen
Senior Member
 
Registered: May 2003
Location: Malaysia
Distribution: Slackware, LFS, CentOS
Posts: 1,307

Rep: Reputation: 46
Quote:
Originally posted by Scruff
Check this out: http://linuxtoday.com/security/2003120203026SCKNSL
Looks like you can upgrade your kernel to 2.4.23 by using 'upgradepkg kernelname.tgz' then upgrading the necessary packages along with it. I learn something new about pkgtool all the time! It's quite a bit more useful than I initially thought. I assume this could also be accomplised a bit more 'automatic' by just using Swaret to update.
Yep, this would be the easiest way if you use the "stock" kernel supplied by Slack.

And remember to run lilo after upgradepkg'ing
 
Old 12-11-2003, 02:36 AM   #14
Bruce Hill
HCL Maintainer
 
Registered: Jun 2003
Location: McCalla, AL, USA
Distribution: Gentoo (all servers at work are openSUSE)
Posts: 6,938

Original Poster
Rep: Reputation: 128Reputation: 128
I must read about Swaret and pkgtool. I'm itching to install Slack on the wife and daughter's comp, but I really need to get mine fully functional as a "work"station first. I will try that method.

Thanks for all of your help. I still want to know what went wrong with following the compile guide that DaOne has posted. It seems to have worked for so many people, so I must have done something wrong.

Has anyone used this verbatim with Slack 9.1?
 
  


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
(EE) NVIDIA(0): Failed to initialize the nvidia kernel module necbrownie Slackware 18 06-16-2006 03:20 AM
Kernel 2.6.7 recompiled / Nvidia broken khermans Linux - General 14 08-10-2004 12:07 PM
Unable to build NVIDIA kernel module / determin kernel version Night Ink Fedora 2 05-31-2004 05:54 PM
(EE) NVIDIA(0): Failed to initialize the NVIDIA kernel module! Stan the caddy Linux - Hardware 8 01-18-2004 05:21 PM
recompiled kernel again get this error when NVIDIA build.. purpleburple Linux - General 4 03-19-2003 09:39 PM

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

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