Besides the core kernel of your Linux distribution there are a number of modules that are loaded along with the kernel. Modules are used to provide extra functionality. /proc/modules file on your system lists the modules loaded on your system and you can also issue lsmod command to view them.

Time and often you don’t need all the modules to be loaded and you may disable them to avoid unnecessary memory consumption.Today we’ll see how we can disable the loading of these unnecessary modules.

So issue lsmod command to view the list of modules.Now watch the values under Used by column of respective modules. A value of 0 indicates that this module is not in use by any application or process.So you can disable it.To disable it follow these instructions-

  • Open /etc/modprobe.d/blacklist file.
  • Now write down the name of module to be unloaded like blacklist ipv6 or blacklist rfcomm.
  • Now next time you reboot that module won’t be loaded.

Unload Unnecessary Modules In RHEL