1

If I do:

sudo insmod module.ko 

I get:

insmod: error inserting 'module.ko': -1 Operation not permitted 

modinfo gives me:

filename: module.ko license: XXX Proprietary version: 210 author: XXX description: XXX Driver srcversion: XXX depends: vermagic: 2.6.32-33-generic-pae SMP mod_unload modversions 586TSC 

and uname -a gives:

2.6.32-35-generic-pae #78-Ubuntu SMP Tue Oct 11 17:01:12 UTC 2011 i686 GNU/Linux 

so I suspect that I need to install this specific kernel version:

2.6.32-33-generic-pae 

My question is how to manage to insert this module and if kernel version is the problem - how to install it on Ubuntu 10.04?

Just to mention, I had 2.6.32.33-generic kernel when I installed Ubuntu, but insmod failed. Then I did:

sudo aptitude install linux-generic-pae linux-headers-generic-pae 

and I selected new kernel on boot, but insmod failed again. What I noticed is that it was (I think 2.6.32.36-generic-pae and not 2.6.32.33-generic-pae, but I don't know how to install this specific version)

4
  • 2
    Not to ask the obvious question, but I assume you did: "sudo insmod module.ko"? Commented Nov 8, 2011 at 16:03
  • Copy your module to the module dir, do a depmod -a, then do modprobe module. Commented Nov 8, 2011 at 16:12
  • 1
    @Rilindo: Yes, I used sudo ;) Commented Nov 8, 2011 at 16:21
  • Thanks! You may want to update your post from "insmod module.ko" to "sudo insmod module.ko" to clarify things. Commented Nov 8, 2011 at 16:29

2 Answers 2

1

From The Linux Kernel Module Programming Guide, section 1.2.1.1:

A module compiled for one kernel won't load if you boot a different kernel unless you enable CONFIG_MODVERSIONS in the kernel.

So, building a kernel with CONFIG_MODVERSIONS enabled, probably will resolve your problem. Another solution would be to build and install Linux 2.6.32-33 with PAE support.

1

I found the solution - I just needed to install "linux-image-2.6.32-33-generic-pae" from synaptic package manager and reboot.

Now inserting module is passing, thanks.

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.