insert module failure
I recently upgraded Kernel to 2.6.8.1 from 2.4.x
I am now trying to insert module as shown below: insmod ./sgi_hostid.ko I get: Error inserting 'sgi_hostid.ko': Invalid module format! Could this be because insmod expects sgi_hostid.o instead? I understand that modules will now be in the .ko format for 2.6 kernels. What do I do? help!? |
Firstly, you don't have to specify the ./ or the .o or extension in the name..
Either an: insmod sgi_hostid or modprobe sgi_hostid And that all depends on if its compiled with support in your current kernel.. |
Now it just says:
insmod: Can't read 'sgi_hostid': NO SUCH FILE OR DIRECTORY. I'm not sure why. I can see the files in /root and /root is in my path Any ideas? |
Quote:
Have you tried using modprobe instead? Is the support compiled into your kernel? |
The module wouldn't be in /root
Have you tried using modprobe instead? Is the support compiled into your kernel? **************************************************************************************************** ****** it is in /root. I downloaded this Makefile and sgi_hostid.c file to the /root dr. I tried modprobe but it gave me a similar error: FATAL: module sgi_hostid not found Is the support compiled into your kernel? Support fo what? Sorry, I have only been using linux for 4 weeks now. Whatever your answer will be can I find out if the support for whatever your answer will be in my .config file? Thanks again Trickykid... |
Let's backup a minute. What execatly are you trying to accomplish? In most cases, a kernel module is not something that you can download; it must be compiled with (or at least into) the kernel.
Also, as a general rule of thumb, downloading untrusted code and attempting to compile it into the kernel is a *really* bad idea. |
Quote:
|
I got the following files sent to me with instructions as shown below:
Makefile sgi_hostid.c license.lic ************************************************************ Below are the instructions I recieved with it: Only written for 2.6.x linux kernel and will not work on any other kernel version written by examples from http://www.diku.dk/hjemmesider/stud...html/node3.html make with: make -C /usr/src/linux-'uname -r` SUBDIRS=`pwd` modules mimics SGI's hostid proc file entry /proc/sgi_sn/licenseID ` After compiling: insmod ./sgi_hostid.ko echo HOSTID >/proc/sgi_sn/licenseID Where HOSTID is the host id defined in the flex license file. BTW, I need to do this so I can run this license server on my box. |
That link gives a "File Not Found" and those are some very crappy instructions without any details. Perhaps you need to submit them to the author for help since their apparent instructions are not working.
|
You will get a "file not found" because you don't have it!
I was provided those files via a .tgz sent to me via email once uncompressed, I was left with: Makefile sgi_hostid.c and these instructions. Should I just move the sgi_hostid.ko mod to the modules directory myself and then try insmod again? I just assumed that make would have placed files in the locaiton insmod expects to find them. Perhaps that explains the error message "Error inserting 'sgi_hostid.ko': Invalid module format!?? Your thoughts? BTW, thanks for working on this with me! |
Quote:
|
All times are GMT -5. The time now is 09:02 AM. |