Skip to contentSkip to conversation

Why cannot I do "insmod nfsd.ko" directly?

DISCUSSION Xin Zhao 3 participants 4 messages Jul 5, 2005

lore
Share & tools
lore

Xin Zhao

author
#0 lore raw

I tried to do "insmod nfsd.ko", but always got the error message "insmod: error inserting 'nfsd.ko': -1 Unknown symbol in module"

Why?

The kernel is 2.6.11.10
The command I used is:
1. insmod lockd.ko ---succeed
2. exportfs -r ---succeed
3. insmod nfsd.ko --- failed

Moreover, I noticed that if I do the following commands, nfsd.ko can be inserted:

1. rpc.mountd
2. exportfs -r
3. rpc.nfsd 1

Can someone explain what trick rpc.mountd and rpc.nfsd do to make nfsd.ko insertable?

Thanks in advance for your kind help!

-x

#1 lore raw

On Tue, 5 Jul 2005 14:23:39 -0400 Xin Zhao wrote:

| I tried to do "insmod nfsd.ko", but always got the error message | "insmod: error inserting 'nfsd.ko': -1 Unknown symbol in module"

The kernel message log would at least tell you what symbol is missing and then you/we can determnine why and where that symbol is located. Maybe there's just another module that needs to be loaded before nfsd.ko. And try using modprobe instead of insmod since modprobe will look for module dependencies.

| Why?
| 
| The kernel is 2.6.11.10
| The command I used is:
| 1. insmod lockd.ko  ---succeed
| 2. exportfs -r   ---succeed
| 3. insmod nfsd.ko --- failed 
| 
| 
| Moreover, I noticed that if I do the following commands, nfsd.ko can
| be inserted:
| 
| 1. rpc.mountd
| 2. exportfs -r
| 3. rpc.nfsd 1
| 
| Can someone explain what trick rpc.mountd and rpc.nfsd do to make
| nfsd.ko insertable?
| 
| Thanks in advance for your kind help!

---
~Randy

#2 lore raw
In reply to Xin Zhao
Quoted 2 lines · Xin Zhao

I tried to do "insmod nfsd.ko", but always got the error message "insmod: error inserting 'nfsd.ko': -1 Unknown symbol in module"

Use modprobe(8), it knows about module dependencies and what to load.

Signature · 4 lines
Dr. Horst H. von Brand                   User #22616 counter.li.org
Departamento de Informatica                     Fono: +56 32 654431
Universidad Tecnica Federico Santa Maria              +56 32 654239
Casilla 110-V, Valparaiso, Chile                Fax:  +56 32 797513
author
#3 lore raw

I just found the problem. I have to insmod exportfs.ko first.

I can certainly use modprobe, but what I really want to do is to use my own nfsd.ko instead of the default one. But my nfsd.ko is not in the default /lib/module/... directory. So if I use modprobe, it will complaint cannot find nfsd.ko.

How to do this? Thanks!

-x

Quoted 11 lines · Horst von Brand
Quoted 2 lines · Xin Zhao

I tried to do "insmod nfsd.ko", but always got the error message "insmod: error inserting 'nfsd.ko': -1 Unknown symbol in module"

Use modprobe(8), it knows about module dependencies and what to load. --
Dr. Horst H. von Brand User #22616 counter.li.org
Departamento de Informatica Fono: +56 32 654431
Universidad Tecnica Federico Santa Maria +56 32 654239
Casilla 110-V, Valparaiso, Chile Fax: +56 32 797513