The system loads most modules automatically at boot time. If necessary, you can specify an additional module that should be loaded.
To specify a module to be loaded at boot time:
Create a file in the
/etc/sysconfig/modules
directory. The file name must have the extension.modules
, for examplefoo.modules
.Edit the file to create the script that loads the module.
The script to load a module can be a simple modprobe call, for example:
#!/bin/sh modprobe foo
or more complex to include error handling:
#!/bin/sh if [ ! -c /dev/foo ] ; then exec /sbin/modprobe foo > /dev/null 2>&1 fi
Use the following command to make the script executable:
#
chmod 755 /etc/sysconfig/modules/foo.modules