• 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 not found

by admin

The modprobe command is used to add or remove modules from a kernel. This command is capable of loading all the dependent modules before inserting the specified module. It is therefore preferred over using the insmod and rmmod commands.

To add modules using modprobe, use the -a option and specify the modules you want to add. To unload a module, use the -r option and specify the modules you want to remove.

The syntax of the modprobe command is:

# modprobe [options] [module names]

In addition to options for adding and removing modules, the modprobe command has more options.

Option Description
-f Force the module to be inserted or removed.
-n Conduct a dry run, i.e., output results without actually executing operations.
-s Print errors to the system log (syslog) rather than stderr.
-v Enable verbose mode.

If you encounter the below error while running the modprobe command:

modprobe: command not found

you may try installing the below package as per your choice of distribution:

OS Distribution Command
Debian apt-get install kmod
Ubuntu apt-get install kmod
Alpine apk add kmod
Arch Linux pacman -S kmod
Kali Linux apt-get install kmod
CentOS yum install kmod
Fedora dnf install kmod
Raspbian apt-get install kmod

modprobe Command Examples

1. Pretend to load a module into the kernel, but don’t actually do it:

# modprobe --dry-run module_name

2. Load a module into the kernel:

# modprobe module_name

3. Remove a module from the kernel:

# modprobe --remove module_name

4. Remove a module and those that depend on it from the kernel:

# modprobe --remove-dependencies module_name

5. Show a kernel module’s dependencies:

# modprobe --show-depends module_name

Filed Under: Linux

Some more articles you might also be interested in …

  1. How to Add Network Printer via Command Line in CentOS/RHEL
  2. lastcomm: command not found
  3. ln: command not found
  4. cpulimit: command not found
  5. hardinfo: command not found
  6. i3 Command Examples in Linux
  7. betterdiscordctl Command Examples in Linux
  8. a2ensite Command Examples in Linux
  9. How to find the inode size of an ext2/ext3/ext4 filesystem?
  10. dos2unix: command not found

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