# modprobe can't find my module [SOLVED]

## punter

Hi,

does someone know why modprobe would say this?

```
slimbox ~ # modprobe sony_acpi

FATAL: Module sony_acpi not found.

```

Instead, I have to do this manually, and it works!

```
insmod /lib/modules/2.6.19-suspend2-r1/kernel/drivers/acpi/sony_acpi.ko
```

My /usr/src/linux points to /usr/src/linux-2.6.19-suspend2-r1

and the loaded kernel is the same

```

slimbox ~ # uname -a

Linux slimbox 2.6.19-suspend2-r1 #1 Tue Apr 17 16:41:54 BST 2007 i686 Intel(R) Pentium(R) M processor 1.73GHz GenuineIntel GNU/Linux

```

I've ran "update-modules" a couple of times as well.... can't think of anything else!

suggestions are appreciated.

ShaneLast edited by punter on Sun Apr 22, 2007 8:06 pm; edited 1 time in total

----------

## NeddySeagoon

punter,

Does it appear in 

```
modprobe -l | grep sony
```

----------

## punter

good suggestion, i hadn't checked that one.

but the answer is no.

many modules under the /lib/modules/2.6.19-suspend2-r1/ directory appear in the list, but not sony_acpi.ko   :Sad: 

----------

## NeddySeagoon

punter,

That explains why modprobe can't find it, it really isn't there but not why you can load it manually.

Can you find it in /lib/modules/...   anywhere ?

----------

## punter

well, that's exactly my problem.

it is under /lib/modules/.... and i can find it too, but modprobe can't find it !!!!

```
slimbox ~ # ls -al /lib/modules/2.6.19-suspend2-r1/kernel/drivers/acpi/sony_acpi.ko 

-rw-r--r-- 1 root root 7428 Apr 20 13:46 /lib/modules/2.6.19-suspend2-r1/kernel/drivers/acpi/sony_acpi.ko

```

----------

## wynn

Can you run

```
grep sony_acpi /lib/modules/2.6.19-suspend2-r1/modules.dep
```

I believe that modprobe looks in this file to find things.

If it isn't there, can you run 

```
depmod -a
```

 and check again?

----------

## punter

oh yes.

it didn't exist, so i ran "depmod -a" and it's now included.....

I'm surprised, I thought "update-modules" (or even "emerge sonyacpi") would have done that. but I guess that's not the case.

thanks alot, my problem's fixed.

----------

## wynn

 *punter wrote:*   

> it didn't exist, so i ran "depmod -a" and it's now included.....
> 
> I'm surprised, I thought "update-modules" (or even "emerge sonyacpi") would have done that. but I guess that's not the case.

 There's a problem with "update-modules", it doesn't run "depmod -a" if it can't find the running kernel's System.map.

[Bug 165134] /sbin/modules-update fails when /etc/init.d/modules starts and /usr/src is on a separate partition than /

----------

## monkeynuthead

 *wynn wrote:*   

> 
> 
> ...There's a problem with "update-modules", it doesn't run "depmod -a" if it can't find the running kernel's System.map...
> 
> 

 

wynn

I've just read the bug report.  What are the implications (if any) of having /usr on a different partition from /etc (and /boot) at start up?  I've been noticing a message on boot about not being able to find System.map but have just ignored it as it doesn't seem to prevent anything working, I think the error messages says something about using /etc/modules.autoload.d/kernel-2.x instead.  Am I right to be ignoring it?

Thanks - mnh.

----------

## NeddySeagoon

monkeynuthead,

You must have /etc/ on the root file system as it contains /etc/fstab which tells were everything else is to be mounted.

/usr and /boot can and often are, separate partitions. Imagine the breakage with /etc elsewhere.

System.map is used only for verbose kernel messages when you get an oops or a panic. It should be copied to /boot if you want to use it. If you don't do kernel debug, its not required. Its a list of kernel symbol names and their addresses.

That bug also explains an irritation I've been having.

----------

## monkeynuthead

 *NeddySeagoon wrote:*   

> 
> 
> System.map is used only for verbose kernel messages when you get an oops or a panic. It should be copied to /boot if you want to use it. If you don't do kernel debug, its not required. Its a list of kernel symbol names and their addresses.

 

Ok, thanks NeddySeagoon.

If it's only used for debug, and as I'm not getting any oopses or panics, I'll worry no more.  

Yes, I can see that /etc/fstab on a separate partition would be less than good  :Smile: .

mnh

----------

## wynn

monkeynuthead: NeddySeagoon has answered your question so this is just a footnote.

In the latest update-modules (sys-apps/module-init-tools-3.2.2-r3) depmod is always called whether System.map can be found or not.

It goes to impressive lengths to find it   :Shocked:  looking in /lib/modules/${KV}/build, /usr/src/linux-${KV}, /lib/modules/${KV},

/boot and /usr/src/linux ($KV is the kernel release, passed on the command line or, more usually, got from "uname -r") and for each of the above paths, trying System.map alone and then with -genkernel-{${arch},'*'}-${KV} or just -${KV} appended to it.

----------

