As you can see, you can put load module commands in /etc/sysconfig/modules/*.modules or /etc/rc.modules.# Load other user-defined modules
for file in /etc/sysconfig/modules/*.modules ; do[ -x $file ] && $filedone# Load modules (for backward compatibility with VARs)if [ -f /etc/rc.modules ]; then/etc/rc.modulesfi
Putting in /etc/rc.local might not work, because rc.local is executed very late.
Understanding /etc/modprobe.conf#e.g loading dummy network module "dummy"
echo "modprobe dummy" >/etc/sysconfig/modules/my.modules
chmod +x /etc/sysconfig/modules/my.modules
/etc/modprobe.conf is the configration file for modprobe command, it DOESN'T load module itself.
#Increase dummy interfaces to 3 when "modprobe dummy" is called
#it is equivalent to specify the option in command line "modprobe dummy numdummies=3"
$cat /etc/modprobe.confoptions dummy numdummies=3##"install" command tells modprobe to run your command instead of inserting the module in the kernel as normal
##it can be used to disable particular module
##disable ipv6 module by changing normal install to a dummy command /bin/true
install ipv6 /bin/true
###NODE: If modprobe is invoked with "--ignore-install" option, the customized install command will be ignored
No comments:
Post a Comment
Note: Only a member of this blog may post a comment.