nV News Forums

 
 

nV News Forums (http://www.nvnews.net/vbulletin/index.php)
-   NVIDIA Linux (http://www.nvnews.net/vbulletin/forumdisplay.php?f=14)
-   -   Unable to load the kernel module 'nvidia.ko' (http://www.nvnews.net/vbulletin/showthread.php?t=49951)

bladela 05-01-05 03:49 PM

Unable to load the kernel module 'nvidia.ko'
 
i've succesfully compiled and installed the kernel (i've simply ignored the two or three seg fault raised...) and tested it...WORKS


i've tryed to install the nvidia driver, specified the kernel source path with the "--kernel-source-path" option, but i've found a new error

Code:

-> Kernel module compilation complete.
ERROR: Unable to load the kernel module 'nvidia.ko'.  This is most likely
      because the kernel module was built using the wrong kernel source files.
      Please make sure you have installed the kernel source files for your
      kernel; on Red Hat Linux systems, for example, be sure you have the
      'kernel-source' rpm installed.  If you know the correct kernel source
      files are installed, you may specify the kernel source path with the
      '--kernel-source-path' commandline option.
-> Kernel module load error: insmod: error inserting './usr/src/nv/nvidia.ko':
  -1 Invalid module format
-> Kernel messages:
  ip_tables: (C) 2000-2002 Netfilter core team
  ip_conntrack version 2.1 (2047 buckets, 16376 max) - 300 bytes per conntrack
  parport_pc: Ignoring new-style parameters in presence of obsolete ones
  parport_pc: VIA 686A/8231 detected
  parport_pc: probing current configuration
  parport_pc: Current parallel port base: 0x378
  parport0: PC-style at 0x378 (0x778), irq 7 [PCSPP,TRISTATE]
  parport_pc: VIA parallel port: io=0x378, irq=7
  lp0: using parport0 (interrupt-driven).
  lp0: console ready
  NET: Registered protocol family 10
  Disabled Privacy Extensions on device c03dbfc0(lo)
  IPv6 over IPv4 tunneling driver
  divert: not allocating divert_blk for non-ethernet device sit0
  nvidia: version magic '2.6.10 preempt K7 REGPARM gcc-3.4' should be '2.6.10
  preempt K7 REGPARM gcc-3.3'
ERROR: Installation has failed.  Please see the file
      '/var/log/nvidia-installer.log' for details.  You may find suggestions
      on fixing installation problems in the README available on the Linux
      driver download page at www.nvidia.com.


so the module's compilation was succesfully, but it says that it isn't the correct kernel source...

BUT I'VE COMPILED THAT SOURCE!!!!!!!!

any idea?

HI
BLADELA

Lithorus 05-01-05 04:34 PM

Re: Unable to load the kernel module 'nvidia.ko'
 
Seems the kernel was compiled with gcc 3.3 but the nvidia module was compiled with 3.4(or the other way around)

jong0357 05-01-05 08:23 PM

Re: Unable to load the kernel module 'nvidia.ko'
 
sh NVIDIA-blahblah -k $(uname -r)


That should do it...

bladela 05-08-05 12:51 PM

Re: Unable to load the kernel module 'nvidia.ko'
 
Quote:

Originally Posted by Lithorus
Seems the kernel was compiled with gcc 3.3 but the nvidia module was compiled with 3.4(or the other way around)


thank you very much

now it works perfectly :D

hi
BLADELA

gijoner 06-04-05 05:56 PM

Re: Unable to load the kernel module 'nvidia.ko'
 
Hi!
At last I found people having the same problem as mine. As I am an absolute beginner in Linux, the perfect solution given by Lithorus doesn't mean anything to me :confused:
I would be most grateful if someone told me what to do with that gcc 3.4 and as a consequence how to solve the problem.
I have Mandriva 2005 LE, kernel linux-2.6.11-6mdk (that's the subdir from /usr/src)

Thank you in advance! :p

Jaggana 10-11-05 04:11 PM

Re: Unable to load the kernel module 'nvidia.ko'
 
I had the same problem, but gcc-3.4.1-4mdk is already installed -_-

Lithorus 10-11-05 04:48 PM

Re: Unable to load the kernel module 'nvidia.ko'
 
Quote:

Originally Posted by gijoner
Hi!
At last I found people having the same problem as mine. As I am an absolute beginner in Linux, the perfect solution given by Lithorus doesn't mean anything to me :confused:
I would be most grateful if someone told me what to do with that gcc 3.4 and as a consequence how to solve the problem.
I have Mandriva 2005 LE, kernel linux-2.6.11-6mdk (that's the subdir from /usr/src)

Thank you in advance! :p

I'm not particularly familiar with Mandrake.

1. What does a "ls -la /lib/modules/`uname -r`/build" (without the ") produce?

2. If the above works what does "cat /lib/modules/`uname -r`/build/include/linux/compile.h" produce?

3. What does a gcc -v say?

Jaggana 10-11-05 11:50 PM

Re: Unable to load the kernel module 'nvidia.ko'
 
Quote:

Originally Posted by Lithorus
1. What does a "ls -la /lib/modules/`uname -r`/build" (without the ") produce?

Code:

ls: /lib/modules/2.6.8.1-12mdk/build: No such file or directory
Code:

[jaggana@localhost jaggana]$ /lib/modules/2.6.8.1-12mdk/kernel/
3rdparty  arch      crypto    drivers  fs        lib      net      security  sound

Code:

[jaggana@localhost jaggana]$ /lib/modules/2.6.8.1-12mdk/kernel/drivers/
acpi      block      char      ide        isdn      message    net        pcmcia    telephony  w1
atm        bluetooth  cpufreq    ieee1394  md        misc      parport    scsi      usb
base      cdrom      i2c        input      media      mtd        pci        serial    video

Code:

[jaggana@localhost jaggana]$ /lib/modules/2.6.8.1-12mdk/kernel/drivers/video/
aty      console  i810    kyro    matrox  riva    sis

but i hade this:
Code:

[jaggana@localhost jaggana]$ /usr/src/linux-2.6.8.1-25mdk/include/linux/
byteorder        isdn              netfilter_arp    netfilter_ipv6    sunrpc
dvb              lockd            netfilter_bridge  nfsd
hdlc              mtd              netfilter_ipv4    raid

Quote:

Originally Posted by Lithorus
2. If the above works what does "cat /lib/modules/`uname -r`/build/include/linux/compile.h" produce?

Code:

[jaggana@localhost jaggana]$ cat /lib/modules/`uname -r`/build/include/linux/compile.h
cat: /lib/modules/2.6.8.1-12mdk/build/include/linux/compile.h: No such file or directory

Quote:

Originally Posted by Lithorus
3. What does a gcc -v say?

Code:

[jaggana@localhost jaggana]$ gcc -v
Reading specs from /usr/lib/gcc/i586-mandrake-linux-gnu/3.4.1/specs
Configured with: ../configure --prefix=/usr --libdir=/usr/lib --with-slibdir=/lib --mandir=/usr/share/man --infodir=/usr/share/info --enable-shared --enable-threads=posix --disable-checking --enable-long-long --enable-__cxa_atexit --enable-clocale=gnu --disable-libunwind-exceptions --enable-languages=c,c++,ada,f77,objc,java --host=i586-mandrake-linux-gnu --with-system-zlib
Thread model: posix
gcc version 3.4.1 (Mandrakelinux 10.1 3.4.1-4mdk)


Lithorus 10-12-05 04:01 AM

Re: Unable to load the kernel module 'nvidia.ko'
 
The path /lib/modules/2.6.8.1-12mdk/build HAS to be there. This is where the nvidia installer looks for the kernel headers. So you need to first install the correct headers.

lorry_driver 10-12-05 08:19 AM

Re: Unable to load the kernel module 'nvidia.ko'
 
1 Attachment(s)
I also faced the same problem, although I have no idea what was wrong with it. Downloaded the correct source and the linkage seems to be fine.

BTW, I'm still a noob at linux. Be gentle. :)

Lithorus 10-12-05 01:35 PM

Re: Unable to load the kernel module 'nvidia.ko'
 
Quote:

Originally Posted by lorry_driver
I also faced the same problem, although I have no idea what was wrong with it. Downloaded the correct source and the linkage seems to be fine.

BTW, I'm still a noob at linux. Be gentle. :)

Please post the bug-report instead (eg. it doesn't say what your `uname -r` is). But it seems that you did NOT install the excact same kernel source. If you have installed the correct kernel headers it should not be even be necessary to specifiy where it is located since it's should be in /lib/modules/`uname -r`/build. If the installer cannot find the kernel headers/sources it's a VERY good indication that the correct ones aren't installed.

kiajin 10-15-05 01:44 PM

Re: Unable to load the kernel module 'nvidia.ko'
 
Quote:

Originally Posted by jong0357
sh NVIDIA-blahblah -k $(uname -r)


That should do it...

This worked for me, I'm curious what -k $(uname -r) did exactly though since I thought I had already tried something similiar.


All times are GMT -5. The time now is 08:30 PM.

Powered by vBulletin® Version 3.7.1
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Copyright 1998 - 2014, nV News.