Skip to content
Related Articles

Related Articles

rmmod command in Linux with Examples
  • Last Updated : 24 May, 2019
GeeksforGeeks - Summer Carnival Banner

rmmod command in Linux system is used to remove a module from the kernel. Most of the users still use modprobe with the -r option instead of using rmmod.

Syntax:

rmmod [-f] [-s] [-v] [modulename]

Example:

rmmod bluetooth

Options:



  • rmmod command with help option: It will print the general syntax of the rmmod along with the various options that can be used with the rmmod command as well as gives a brief description about each option.

  • rmmod -v: This option prints messages about what the program is being doing. Usually rmmod only prints messages only if something went wrong.

    Example:

    rmmod -v bluetooth

  • rmmod -f: This option can be extremely dangerous. It takes no effect unless CONFIG_MODULE_FORCE_UNLOAD is being set when the kernel was compiled. With this option, you can remove the specified modules which are being used, or which are not being designed to be removed or have been marked as not safe.

    Example:

    sudo rmmod -f bluetooth

  • rmmod -s : This option is going to send errors to syslog instead of standard error.

    Example:

    rmmod -s bluetooth

  • rmmod -V : This option will going to show version of program and then exit.
    rmmod -V

Attention reader! Don’t stop learning now. Get hold of all the important DSA concepts with the DSA Self Paced Course at a student-friendly price and become industry ready.

My Personal Notes arrow_drop_up
Recommended Articles
Page :