• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer navigation

The Geek Diary

  • OS
    • Linux
    • CentOS/RHEL
    • Solaris
    • Oracle Linux
    • VCS
  • Interview Questions
  • Database
    • oracle
    • oracle 12c
    • ASM
    • mysql
    • MariaDB
  • DevOps
    • Docker
    • Shell Scripting
  • Big Data
    • Hadoop
    • Cloudera
    • Hortonworks HDP

modprobe Command Options

by admin

The modprobe command is used to add and remove modules from the currently running kernel. Note that it also attempts to load module dependencies.

Syntax:

# modprobe [options] [module_name]

Key Options for the modprobe Command:

  • -c displays the current modprobe configuration.
  • -q runs in quiet mode.
  • -R displays all modules that match an alias to assist you in debugging issues.
  • -r removes the specified module from memory.
  • -v displays verbose messages; this is useful for determining how modprobe is performing a task.

modprobe Command Options

Option Description
-a,–all Insert all module names on the command line.
-b,–use-blacklist This option causesmodprobeto apply theblacklistcommands in the configuration files (if any) to module names as well.
-C,–config This option overrides the default configuration directory (/etc/modprobe.d). This option is passed through install or remove commands to other modprobe commands in the MODPROBE_OPTIONS environment variable.
-c,–showconfig Dump out the effective configuration from the config directory and exit.
–dump-modversions Print out a list of module versioning information required by a module. This option is commonly used by distributions in order to package up a Linux kernel module using module versioning deps.
-d,–dirname Root directory for modules, / by default.
–first-time this option makes modprobe fail in the case that it actually didn’t do anything.
–force-vermagic If a module fails to load and the kernel complains that the “version magic” doesn’t match, you can use this option to remove it.
–force-modversion If a module fails to load and the kernel complains that the module disagrees about a version of some interface, you can use “–force-modversion” to remove the version information altogether.
-f,–force Try to strip any versioning information from the module which might otherwise stop it from loading: this is the same as using both –force-vermagic and –force-modversion.
-i,–ignore-install,–ignore-remove This option causes modprobe to ignore install and remove commands in the configuration file (if any) for the module specified on the command line (any dependent modules are still subject to commands set for them in the configuration file).
-n,–dry-run,–show This option does everything but actually insert or delete the modules (or run the install or remove commands).
-q,–quiet With this flag,modprobewon’t print an error message if you try to remove or insert a module it can’t find (and isn’t an alias orinstall/removecommand).
-R,–resolve-alias Print all module names matching an alias. This can be useful for debugging module alias problems.
-r,–remove This option causesmodprobeto remove rather than insert a module.
-S,–set-version Set the kernel version, rather than using uname(2) to decide on the kernel version (which dictates where to find the modules).
–show-depends List the dependencies of a module (or alias), including the module itself.
-s,–syslog This option causes any error messages to go through the syslog mechanism (as LOG_DAEMON with level LOG_NOTICE) rather than to standard error.
-V,–version Show version of program and exit.
-v,–verbose Print messages about what the program is doing.

Filed Under: Linux

Some more articles you might also be interested in …

  1. How to enable IPv6 on CentOS / RHEL 7
  2. When to use rescan-scsi-bus.sh -i (LIP flag) in CentOS/RHEL
  3. RPM : package installation Error : cpio: read failed
  4. sar: command not found
  5. jpegtran Command Examples in Linux
  6. How to Change the default kernel (boot from old kernel) in CentOS/RHEL 8
  7. conky Command Examples in Linux
  8. CentOS / RHEL : How to add a new Physical Volume to an existing Volume Group
  9. How to run a cron job on specific days of the week
  10. CentOS / RHEL : How to find if a network port is open or not?

You May Also Like

Primary Sidebar

Recent Posts

  • protonvpn-cli Command Examples in Linux
  • protonvpn-cli connect Command Examples
  • procs Command Examples in Linux
  • prlimit: command not found

© 2023 · The Geek Diary

  • Archives
  • Contact Us
  • Copyright