modprobe: Can't locate module ocfs
phanyJan 12 2006 — edited May 9 2007Hello All,
For the benefit of my fellow novices, I want to post the problem I encountered while installing OCFS this week and the solution that worked for me. Knowledge is power, etc, etc.
The DBA who installed and configured our 2 node Oracle 10g RAC database is long gone and I inherited his responsibilities. This week I was asked to add a new node to the cluster.
The new server is:
* a Dell PowerEdge 1850 blade
* with one 3.20 Ghz Processor
* 2GB of RAM
* FibreChannel connection to our SAN
* OS: Red Hat Enterprise Linux ES release 3 (Taroon Update 3)
* Kernel: 2.4.21-20.ELsmp
I took a few days to read Oracles RAC Install Guide and Admin Guide. After installing RHEL3, my next task was to install OCFS. I read the OCFS User Guide from http://oss.oracle.com and took a stab at it.
It took two attempts. The first attempt was a miserable failure when after installing the OCFS rpm packages and then rebooting, GRUB wouldnt work anymore. Why, Ill never know. I tried to reinstall GRUB, but still had a multitude of problems, so I just started from scratch and reinstalled RHEL3.
The second attempt went a little smoother. I installed the OCFS packages:
******************************************
# rpm -Uvh ocfs*.rpm
Preparing... ####################################### [100%]
1:ocfs-support ###################################### [ 33%]
2:ocfs-2.4.21-EL-smp ################################### [ 67%]
Linking OCFS module into the module path [ OK ]
3:ocfs-tools ###################################### [100%]
******************************************
Then I did the chkconfig command like the OCFS User Guide said:
******************************************
# chkconfig --list | grep ocfs
ocfs 0:off 1:off 2:on 3:on 4:on 5:on 6:off
******************************************
Looks good.
Then I created my config file using the ocfstool
Good.
Then I tried to load the OCFS Module by executing /sbin/load_ocfs
And I got this error message:
******************************************
# /sbin/load_ocfs
/sbin/modprobe ocfs node_name=rac4 ip_address=192.168.4.2 cs=1810 guid=1466BD5C0F2E1C047B9B001143D8B757 ip_port=7000 comm_voting=1
modprobe: Can't locate module ocfs
load_ocfs: insmod failed
******************************************
At this time, if I tried to mount the OCFS filesystem this is what happened:
******************************************
# mount -t ocfs /dev/sda1 /u01
mount: fs type ocfs not supported by kernel
******************************************
So the solution for me was this command:
******************************************
# /sbin/depmod a
******************************************
So what the heck is depmod!?
For those of us who know nothing or little about Kernel Modules... here is some introductory information:
My ocfs.o file located here:
/lib/modules/2.4.21-EL-smp-ABI/ocfs/
that came from the rpm I installed
is known as a Kernel Module and when I call the /sbin/load_ocfs shell script it calls /sbin/modprobe to load this Kernel Module.
I found this statement from redhat.com:
If the response to the modprobe command displays a message about being unable to find a module, (ie: modprobe: Can't locate module ocfs) then run the depmod -a command and try loading the module again.
There are a bunch of commands for Kernel Modules, here are some:
Command Description
--------------------------------------------
lsmod --------------->List the modules currently loaded in the Kernel
insmod-------------->Install a KLM (load a module)
modprobe ---------->Manage KLMs
rmmod -------------->Remove KLMs from the kernel
depmod ---------->Handle module dependancies
ksyms ---------->Display kernel symbols and which modules they belong to
modinfo ---------->Display information about a kernel module
(Note: KLM is an acronym for Kernel Load Module)
More helpful information available at:
http://www.redhat.com/docs/manuals/enterprise/RHEL-3-Manual/sysadmin-guide/ch-kernel-modules.html
See man pages too.
After the depmod a command I tried /sbin/load_ocfs again, this time it worked and I was able to mount my filesystem. See below. (Note: I read somewhere the two warnings (below) can safely be ignored!)
******************************************
# /sbin/load_ocfs
/sbin/modprobe ocfs node_name=rac4 ip_address=192.168.4.2 cs=1810 guid=1466BD5C0F2E1C047B9B001143D8B757 ip_port=7000 comm_voting=1
Warning: kernel-module version mismatch
/lib/modules/2.4.21-EL-smp-ABI/ocfs/ocfs.o was compiled for kernel version 2.4.21-4.ELsmp while this kernel is version 2.4.21-20.ELsmp
Warning: loading /lib/modules/2.4.21-EL-smp-ABI/ocfs/ocfs.o will taint the kernel: forced load
See http://www.tux.org/lkml/#export-tainted for information about tainted modules
Module ocfs loaded, with warnings
# mount -t ocfs /dev/sda1 /u01
# ls -alp /u01
total 65797
drwxr-xr-x 1 root root 131072 Jan 11 18:19 ./
drwxr-xr-x 21 root root 4096 Jan 11 17:58 ../
drwxr-xr-x 1 oracle oinstall 131072 Apr 1 2005 crs/
drwxr-xr-x 1 oracle dba 131072 Apr 5 2005 oradata/
#
******************************************
I hope posting this info is helpful to someone else who is sweating over this lovely error message: modprobe: Can't locate module ocfs
Learn something new EVERYDAY.