LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   modprobe and lsscsi commands are not working (https://www.linuxquestions.org/questions/linux-newbie-8/modprobe-and-lsscsi-commands-are-not-working-814027/)

LinuxPro 06-14-2010 05:25 AM

modprobe and lsscsi commands are not working
 
Hello,

I have Fedora 2.6.29. When Im trying to laod a kernel module by using modprobe, its throwing an error message 'Module not found'.
Also, when I use 'lssci' command to see the list of SCSI devices, this also doesn't work, and throws an error 'Command not found'.

However, I have used insmod to load my module and I am able to see its entry in /proc/scsi/scsi file, but why 'modprobe' and 'lssci' are not working. Is there any way to resolve this problem?

Many Thanks.

onebuck 06-14-2010 07:18 AM

Hi,

How are you implementing the commands? As root?
:hattip:

LinuxPro 06-14-2010 07:38 AM

Yes, Im running them as root only.

Thanks

knudfl 06-14-2010 07:49 AM

When you do 'su' , the commands are :

/sbin/lspci
/sbin/modprobe

To have lspci , modprobe in your path, 'su -' is required.
.....

LinuxPro 06-15-2010 03:17 AM

I have tried using /sbin/modprobe and /sbin/lsscsi also , but they are still not working.
Is there any package which I can install, if there is any, how I can install that. When I do 'rpm -q modutils', it says 'modutils is not installed'.

knudfl 06-15-2010 10:45 AM

The package : 'module-init-tools' provides /sbin/modprobe

'pciutils' will provide /sbin/lspci

..

student04 06-15-2010 11:51 AM

For modprobe to work, your module needs to be in this directory or a subdirectory therein:

Code:

/lib/modules/$(uname -r)
If that is true, then you need to execute

Code:

# depmod -a
which builds a list of modules that modprobe uses to find by name. Then try modprobe again.

-AM

rfernandez 06-15-2010 11:56 AM

Could you type, as root, on your terminal the fallowing lines:

Code:

# whereis modprobe
# whereis lsscsi

And give us the output? Also, which Fedora you're using? 13? 12? ...?

knudfl 06-15-2010 12:10 PM

Post # 1 :
Quote:

I have Fedora 2.6.29
That is Fedora 11.
But there are no differences between versions,
for 'module-init-tools' + 'pciutils', so far concerns
the commands, they provide.
The two packages are also usualy installed by default.
..

rfernandez 06-15-2010 06:24 PM

But, is lsscsi a part of lspci? I don't know for Fedora, but for Slackware is in a separate package.

knudfl 06-16-2010 12:58 AM

Sorry , I misread the lsscsi part.

# yum install lsscsi
.. will install the package.

..

LinuxPro 06-16-2010 09:28 AM

Hello,

Thanks to everyone for helping me till this time. I have installed the packages for lsscsi and module-init-tools. I am able to use lsscsi successfully now but still facing some issue with modprobe. When I use modprobe <module name>, its gives an error, <module name> doesn't exist.
I have tried this with and without root, and with and without /sbin path, but still its not working. However, I could install my module properly and able to see it in 'lsscsi' output,and also in /proc/modules file. I have tried evrything what all is suggested here in above comments, but something is still missing!!

Thanks.

rfernandez 06-17-2010 04:13 PM

If it is a 3rd part module you should tell us how you installed it so we can point out what's missing. Generally, for a 3rd part module, you should build and install it. Afterwards, you should issue a "depmod -a" and then try to use "modprobe <module name>".

LinuxPro 06-18-2010 09:11 AM

I have installed the package 'yum install module-init-tools' for modprobe and when I do 'whereis modprobe', I am able to find it in /sbin/... path. But, still I am not able to load my module using 'modprobe <module name>.It's giving the same error '<module-name> not found'.
I have tried 'depmod-a' command also, but still its not getting through.

Thanks.

onebuck 06-18-2010 01:36 PM

Hi,

Just curious, show us the complete 'modprobe' line that you are entering. What is the module you are attempting to load?

Quote:

Usage: modprobe [-v] [-V] [-C config-file] [-d <dirname> ] [-n] [-i] [-q] [-b] [-o <modname>] [ --dump-modversions ] <modname> [parameters...]
modprobe -r [-n] [-i] [-v] <modulename> ...
modprobe -l -t <dirname> [ -a <modulename> ...]

If you 'man modprobe' then all the information is there.


All times are GMT -5. The time now is 11:17 PM.