SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
The NVIDIA drivers are complaining when I try to install them on Slack 11 with the 2.6 SMP kernel. I backed up everything on my box to a server, re-formatted the hard drive, and did a clean install of Slack 11. I then installed the smp kernel, smp modules, and smp headers from /extra on disk 2. It boots fine, sound and networking work fine (so I know modules work) but the NVIDIA drivers build and then say that they can't install because the gcc version that the kernel was compiled with is different from the gcc version I use to compile the NVIDIA drivers.
Now the strange part:
gcc -v gives gcc version 3.4.6, the default version for Slackware 11.
dmesg gives gcc 3.4.6 as well, at the top as the version that the kernel was built with.
Further, when I go to /var/log/nvidia-installer.log, at the end it doesn't say anything about compiler versions, it says that the nvidia so does not contain a recognizable kernel module. (I am currently away from my desktop, when I get back to my dorm I'll post the exact error messages and command output.)
I'm rather at a loss as to why the nvidia driver is having problems loading into my kernel. The gcc versions are definately the same, and the .config for the SMP kernel has module loading supported (of course).
Am I the only one having this issue?
Thanks everyone. More information when I get back to my computer.
It may be the kernel-headers issue. Some of the more knowledgeable slackers would give you more insight on this. But as far as I know, you should not install kernel-headers for 2.6 kernel series. I also remember reading in -current changelogs about glibc being compiled against both 2.4 headers and 2.6 headers for Slack 11, which would make is absolutely okay (IMO) to install either of the kernel-headers package. May be I'm wrong...
I did a clean install yesterday and used huge26.s (not smp). I later recompiled my kernel for smp support. I then install NVIDIA driver (version 8774) and it gave me no problems.
nvidia: version magic '2.6.17.13 mod_unload 486 gcc-3.4' should be
'2.6.17.13-smp SMP mod_unload 686 gcc-3.4'
This is the (I believe) relevant section of the /var/log/nvidia-installer. Apparently while my gcc version is 3.4, it is set to optimize for 486. How do I set my gcc to optomize for 686/SMP, like the "version magic" says it should?
nvidia: version magic '2.6.17.13 mod_unload 486 gcc-3.4' should be
'2.6.17.13-smp SMP mod_unload 686 gcc-3.4'
This isn't a gcc problem, it's a version.h problem. The NVidia driver gets its module version string from /usr/src/linux/include/linux/version.h, not from the headers in /usr/include/linux. Even after following Pat's instructions, the version.h in the 2.6.17.13 sources still doesn't have the "-smp" tagged onto its version string. This causes the module version mismatch in the NVidia driver.
EDIT: A clean solution is given about three posts down.
Originally posted by mogunus
nvidia: version magic '2.6.17.13 mod_unload 486 gcc-3.4' should be
'2.6.17.13-smp SMP mod_unload 686 gcc-3.4'
This is the (I believe) relevant section of the /var/log/nvidia-installer. Apparently while my gcc version is 3.4, it is set to optimize for 486. How do I set my gcc to optomize for 686/SMP, like the "version magic" says it should?
Are you trying to use the 64-bit version of the nVidia driver? For Slackware 11.0 you should be using the IA32 nVidia driver (the version is now at 1.0-8774).
And you should only have the kernel 2.4 headers installed. See the warning file with the 2.6 kernel headers on the CD for more details.
That warning file is older. I have both headers installed and I've had no problems. Basically, you need to have the 2.4 headers and the 2.6 headers are optional but they have to be the ones that glibc were complied against.
I found an even easier way to fix the NVidia problem, no headers or searching through tarballs involved:
I will assume that you have the 2.6.17.13-smp kernel and modules installed.
Boot into your 2.6.17.13-smp system.
Log in as root, and install the 2.6.17.13 source package from /extra.
Following Pat's instructions from the README, copy the SMP config file: cd /usr/src/linux-2.6.17.13 cp /boot/config-generic-smp-2.6.17.13 ./.config
Again following Pat's instructions, re-configure the source for SMP: make oldconfig
Now, just for laughs, take a look at include/linux/version.h: cat include/linux/version.h
Notice the first line:
#define UTS_RELEASE "2.6.17.13"
That's wrong - it needs updating: make include/linux/version.h
The output of that last command should be:
CHK include/linux/version.h
UPD include/linux/version.h
Look what happened: cat include/linux/version.h
Notice the first line:
#define UTS_RELEASE "2.6.17.13-smp"
Now that the release version string is correct, the nvidia installer will work. Your module actually compiled OK, it just wouldn't load because of the errant UTS_RELEASE string.
EDIT: You don't need the 2.6.17.13 headers installed. The headers are irrelevant, as the NVidia installer doesn't use them - since it's building a kernel module, it uses the kernel's source code directly. As others here have mentioned, it's a very good idea to keep the 2.4.33 headers in place unless you really know what you're doing.
Thanks agx, that worked perfectly for me & saved me time. I'm now happily running the Slack-provided SMP kernel, managed to get through the 'initrd' thing to get it to load the reiserfs too & I had fluffed a few kernel compiles already, so thanks! So I've got into X, now to check what works & what doesn't yet...
Thanks agx, I was having the same exact problem. Oddly enough, installation of the Nvidia driver went fine with the 2.6.18 kernel originally, but after downgrading to the 2.6.17-smp kernel I started having that problem.
I found an even easier way to fix the NVidia problem, no headers or searching through tarballs involved:
I will assume that you have the 2.6.17.13-smp kernel and modules installed.
Boot into your 2.6.17.13-smp system.
Log in as root, and install the 2.6.17.13 source package from /extra.
Following Pat's instructions from the README, copy the SMP config file: cd /usr/src/linux-2.6.17.13 cp /boot/config-generic-smp-2.6.17.13 ./.config
Again following Pat's instructions, re-configure the source for SMP: make oldconfig
Now, just for laughs, take a look at include/linux/version.h: cat include/linux/version.h
Notice the first line:
#define UTS_RELEASE "2.6.17.13"
That's wrong - it needs updating: make include/linux/version.h
The output of that last command should be:
CHK include/linux/version.h
UPD include/linux/version.h
Look what happened: cat include/linux/version.h
Notice the first line:
#define UTS_RELEASE "2.6.17.13-smp"
Now that the release version string is correct, the nvidia installer will work. Your module actually compiled OK, it just wouldn't load because of the errant UTS_RELEASE string.
EDIT: You don't need the 2.6.17.13 headers installed. The headers are irrelevant, as the NVidia installer doesn't use them - since it's building a kernel module, it uses the kernel's source code directly. As others here have mentioned, it's a very good idea to keep the 2.4.33 headers in place unless you really know what you're doing.
I'll add this do my DRI mega-thread, if that's OK with you, agx
welcome mogunus to lq slack forum.
i am using nvidia, i got some strange problems ergarding the kernel version name.
the soln by agx is interesting. i will check this.
make sure taht the /usr/src/linux points to teh actual smp kernel source,
otherwise u have to give full path like this
#sh NVIDIA-Linux-x86-1.0-8776-pkg1.run --kernel-source-path=/pathto/linux-source
also download the newest driver from nvidia
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.