Home
Main website
Display Sidebar
Hide Ads
Recent Changes
View Source:
modprobe(8)
Edit
PageHistory
Diff
Info
LikePages
MODPROBE !!!MODPROBE NAME SYNOPSIS OPTIONS DESCRIPTION CONFIGURATION STRATEGY EXAMPLES FILES SEE ALSO SAFE MODE LOGGING COMMANDS REQUIRED UTILITIES NOTES BUGS AUTHOR ---- !!NAME modprobe - high level handling of loadable modules !!SYNOPSIS __modprobe__ [[-adnqv] [[-C ''config''] module [[symbol=value ...]__ modprobe__ [[-adnqv] [[-C ''config''] [[-t ''type''] pattern__ modprobe__ -l [[-C ''config''] [[-t ''type''] pattern__ modprobe__ -c [[-C ''config'']__ modprobe__ -r [[-dnv] [[-C ''config''] [[module ...]__ modprobe__ -Vh !!OPTIONS __-a__, __--all__ Load __all__ matching modules instead of stopping after the first successful loading. __-c__, __--showconfig__ Show the currently used configuration. __-C__, __--config__ ''config'' Use the file ''config'' instead of (the optional) ''/etc/modules.conf'' to specify the configuration. The environment variable __MODULECONF__ can also be used to select (and override) a different configuration file from the default /etc/modules.conf (or ''/etc/conf.modules'' (deprecated)). __-d__, __--debug__ Show information about the internal representation of the stack of modules. __-h__, __--help__ Display a summary of options and immediately exit. __-k__, __--autoclean__ Set 'autoclean' on loaded modules. Used by the kernel when it calls on __modprobe__ to satisfy a missing feature (supplied as a module). The __-q__ option is implied by __-k__. These options will automatically be sent to __insmod__. __-l__, __--list__ List matching modules. __-n__, __--show__ Don't actually perform the action, just show what would be done. __-q__, __--quiet__ Do not complain about __insmod__ failing to install a module. Continue as normal, but silently, with other possibilities for modprobe to test. This option will automatically be sent to __insmod__. __-r__, __--remove__ Remove module (stacks) or do autoclean, depending on whether there are any modules mentioned on the command line. __-s__, __--syslog__ Report via syslog instead of stderr. This options will automatically be sent to __insmod__. __-t__ ''moduletype''; __--type__ ''moduletype'' Only consider modules of this type. modprobe will only look at modules whose directory path includes exactly /moduletype/''''moduletype'' can include more than one directory name, e.g. ''-t__ ''drivers/net'' ''xxx/drivers/net/'' and its subdirectories. __-v__, __--verbose__ Print all commands as they are executed. __-V, --version__ Display the version of __modprobe__. __Note:__ Module names must not contain paths (no '/'), nor may they contain the trailing '.o'. For example, slip is a valid module name for __modprobe__, /lib/modules/2.2.19/net/slip and slip.o are invalid. This applies to the command line and to entries in the config. !!DESCRIPTION The __modprobe__ and __depmod__ utilities are intended to make a Linux modular kernel more manageable for all users, administrators and distribution maintainers. __Modprobe__ uses a __depmod__, to automatically load the relevant module(s) from the set of modules available in predefined directory trees. __Modprobe__ is used to load a single module, a stack of dependent modules, or all modules that are marked with a specified tag. __Modprobe__ will automatically load all base modules needed in a module stack, as described by the dependency file ''modules.dep''. If the loading of one of these modules fails, the whole current stack of modules loaded in the current session will be unloaded automatically. __Modprobe__ has two ways of loading modules. One way (the probe mode) will try to load a module out of a list (defined by ''pattern''). __Modprobe__ stops loading as soon as one module loads successfully. This could be used to autoload one Ethernet driver out of a list. The other way __modprobe__ can be used is to load __all__ modules from a list. See __EXAMPLES__, below. With the option __-r__, modprobe will automatically unload a stack of modules, similar to the way __rmmod -r____modprobe -r__ __/etc/modules.conf''. The combining the options __-l__ and __-t__ lists all available modules of a certain type. Option __-c__ will print the currently used configuration (default + configuration file). !!CONFIGURATION The behavior of __modprobe__ (and __depmod__) can be modified by the (optional) configuration file ''/etc/modules.conf''. For a more detailed description of what this file can contain, as well as the default configuration used by __depmod__ and __modprobe__, see modules.conf(5). Note that the pre- and post-remove commands will __not__ be executed if a module is __ If you want to use the pre- and post-install features, you will have to turn off autoclean for kerneld and instead put something like the following line in your __crontab__ (this is used for kmod systems as well) to do autoclean every 2 minutes: */2 * * * * test -f /proc/modules !!STRATEGY The idea is that __modprobe__ will look first in the directory containing modules compiled for the current release of the kernel. If the module is not found there, __modprobe__ will look in the directory common to the kernel version (e.g. 2.0, 2.2). If the module is still found, __modprobe__ will look in the directory containing modules for a default release, and so on. When you install a new linux, the modules should be moved to a directory related to the release (and version) of the kernel you are installing. Then you should do a symlink from this directory to the Each time you compile a new kernel, the command make modules_install__ __ When you get a module unrelated to the kernel distribution you should place it in one of the version-independent directories under ''/lib/modules''. This is the default strategy, which can be overridden in ''/etc/modules.conf''. !!EXAMPLES __modprobe -t net__ Load one of the modules that are stored in the directory tagged __modprobe -a -t boot__ All modules that are stored in directories tagged __modprobe slip__ This will attempt to load the module slhc.o if it was not previously loaded, since the slip module needs the functionality in the slhc module. This dependency will be described in the file ''modules.dep'' that was created automatically by __depmod__. __modprobe -r slip__ This will unload the slip module. It will also unload the slhc module automatically, unless it is used by some other module as well (e.g. ppp). !!FILES ''/etc/modules.conf'' (alternatively but deprecated ''/etc/conf.modules'') ''/lib/modules/*/modules.dep'', ''/lib/modules/* '' !!SEE ALSO depmod(8), lsmod(8), kerneld(8), ksyms(8), rmmod(8). !!SAFE MODE If the effective uid is not equal to the real uid then __modprobe__ treats its input with extreme suspicion. The last parameter is always treated as a module name, even if it starts with '-'. There can only be one module name and options of the form __ euid may not be equal to uid when modprobe is invoked from the kernel, this is true for kernels modprobe__ could trust the kernel to only pass valid parameters to modprobe. However at least one local root exploit has occurred because high level kernel code passed unverified parameters direct from the user to modprobe. So modprobe no longer trusts kernel input. __modprobe__ automatically sets safe mode when the environment consists only of these strings HOME=/ TERM=linux PATH=/sbin:/usr/sbin:/bin:/usr/bin This detects modprobe execution from the kernel on kernels 2.2 though 2.4.0-test11, even if uid == euid, which it does on the earlier kernels. !!LOGGING COMMANDS If directory ''/var/log/ksymoops'' exists and __modprobe__ is run with an option that could load or a delete a module then modprobe will log its command and return status in ''/var/log/ksymoops/`date +%Y%m%d.log`''. There is no switch to disable this automatic logging, if you do not want it to occur, do not create ''/var/log/ksymoops''. If that directory exists, it should be owned by root and be mode 644 or 600 and you should run script __insmod_ksymoops_clean__ every day or so. !!REQUIRED UTILITIES depmod(8), insmod(8). !!NOTES Patterns supplied to __modprobe__ will often need to be escaped to ensure that it is evaluated in the proper context. !!BUGS __modprobe__ [[ __-V__ | __--version__ ] should exit immediately. Instead, it prints the version information and behaves as if no options were given. !!AUTHOR Jacques Gelinas (jack@solucorp.qc.ca) Bjorn Ekwall (bj0rn@blox.se) ----
15 pages link to
modprobe(8)
:
update-modules(8)
modprobe.conf(5)
rmmod(8)
Man8m
depmod(8)
genksyms(8)
insmod(8)
ksyms(8)
lsmod(8)
modinfo(8)
modules.conf(5)
ModuleNotes
modules.dep(5)
KernelSpace
AlsaNotes
This page is a man page (or other imported legacy content). We are unable to automatically determine the license status of this page.