lsmod command in Linux with Examples

lsmod command is used to display the status of modules in the Linux kernel. It results in a list of loaded modules. lsmod is a trivial program which nicely formats the contents of the /proc/modules, showing what kernel modules are currently loaded.

Syntax:

lsmod

Example: Run lsmod at the command line to list all active kernel modules.



lsmod

Output:

Output Format: There are three columns in output.

  • First, column is used for ‘Name‘ of the module file. Or you can say
    Name = Module file name  -  Module file extension(eg .o or .ko)  
    
  • Second, column is used for ‘size‘ of the module in Bytes.
  • The third column in output is for ‘used by‘. It is basically used to display the number of instances of the module which are used.


My Personal Notes arrow_drop_up

Check out this Author's contributed articles.

If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to contribute@geeksforgeeks.org. See your article appearing on the GeeksforGeeks main page and help other Geeks.

Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.