Results 1 to 4 of 4
Hi All,
I got "Invalid Module format" error while using insmod command. Later i understand that the file is compiled in previous version of Linux. But, currently i don't have ...
- 12-20-2010 #1Just Joined!
- Join Date
- Dec 2010
- Posts
- 2
Error while using insmod
Hi All,
I got "Invalid Module format" error while using insmod command. Later i understand that the file is compiled in previous version of Linux. But, currently i don't have the source files to recompile in new version of Linux. I have tried with -f option. Still, It is not working. Is there any other way to solve this problem.
Thanks in advance.
barati
- 12-20-2010 #2
When you say you don't have the source files, do you mean that you don't have the kernel source files?
If you have source code for this particular module, you can compile it without having to recompile the whole kernel. You just need the correct kernel headers. You don't say what distribution you are using but most distros have a separate kernel headers package, which can be installed to take care of situations like this.
If you don't have - and can't get hold of - the module source code, your best option is to install the matching kernel as an alternative boot option to the one you are using."I'm just a little old lady; don't try to dazzle me with jargon!"
- 12-21-2010 #3Just Joined!
- Join Date
- Dec 2010
- Posts
- 2
Hi,
Thanks for reply. I don't have the module source files. According to your suggestion, i have to install the previous matching kernel.
In the case, Whether i have to compile the other modules also in previous kernel. Am i right?
barati
- 12-21-2010 #4
No. You do not need kernel sources to compile an individual kernel module. You only need the source code of the module and the kernel headers. Install the headers that correspond to the kernel you are using. Then compile your module and install it in the appropriate place in the /lib/modules/(version) tree. The rest of the kernel does not need to be rebuilt; that's the whole point of having a modular kernel.
Reverting to an older kernel is only necessary if you don't have the source code for the module and therefore can't recompile it. I take it we are talking about a driver here. Some manufacturers only supply precompiled drivers and you may well find that there isn't one for your current kernel. But if it's mainly source code with a precompiled "binary blob" included, then you can compile it for any kernel as long as you have the correct headers installed."I'm just a little old lady; don't try to dazzle me with jargon!"


Reply With Quote
