Logo
  • Ubuntu
  • CentOS
  • Debian
  • Fedora
  • RedHat

Lsmod Command in Linux (List Kernel Modules) - DesignLinux

May 31 2020
designlinux 0 Comments
lsmod command in linux

lsmod command is used to display the information of loaded modules in the Linux kernel. Linux kernel modules are system-level software that can be used directly by operating system kernel.

Kernel modules#

The Linux kernel is the core component of Linux operating systems. It manages the system’s resources, and communication between your computer’s hardware and software.

lsmod Command#

lsmod is a simple utility and has no options. It formats the contents of the file /proc/modules, which contains information about the status of all currently-loaded LKMs.

Run lsmod at the command line to find out what kernel modules are currently loaded:

lsmod

The command outputs information for each loaded kernel module on a new line:

Module Size Used by
cmac 16384 0
rfcomm 81920 4
...
ahci 40960 1
intel_lpss_pci 20480 0
i2c_i801 32768 0
libahci 32768 1 ahci
intel_lpss 16384 1 intel_lpss_pci
...

There are three columns in each row:

  • Module – It displays the name of the module.
  • Size – The second column shows the size of the module in bytes.
  • Used by – This column shows a number that indicates how many instances of the module are currently used. Zero value means module is not used.

You can filter the output using grep, to find out a specific module is loaded or not. For example to find whether the kvm module is loaded you would run:

lsmod | grep kvm
kvm_intel             217088  0
kvm                   610304  1 kvm_intel
irqbypass              16384  1 kvm

You can get the more information about a module, issue the modinfo command.

Conclusion#

The lsmod command displays a list of the currently loaded kernel modules.

Feel free to leave a comment if you have any questions.

Related

Tags: kernel, lsmod, terminal

How to Install R on Ubuntu 20.04

Prev Post

Bash printf Command

Next Post
Archives
  • January 2023
  • December 2022
  • November 2022
  • October 2022
  • September 2022
  • July 2022
  • June 2022
  • April 2022
  • March 2022
  • February 2022
  • January 2022
  • December 2021
  • November 2021
  • October 2021
  • September 2021
  • August 2021
  • July 2021
  • June 2021
  • May 2021
  • April 2021
  • March 2021
  • February 2021
  • January 2021
  • December 2020
  • November 2020
  • October 2020
  • September 2020
  • August 2020
  • July 2020
  • June 2020
  • May 2020
Categories
  • AlmaLinux
  • Android
  • Ansible
  • Apache
  • Arch Linux
  • AWS
  • Backups
  • Bash Shell
  • Bodhi Linux
  • CentOS
  • CentOS Stream
  • Chef
  • Cloud Software
  • CMS
  • Commandline Tools
  • Control Panels
  • CouchDB
  • Data Recovery Tools
  • Databases
  • Debian
  • Deepin Linux
  • Desktops
  • Development Tools
  • Docker
  • Download Managers
  • Drupal
  • Editors
  • Elementary OS
  • Encryption Tools
  • Fedora
  • Firewalls
  • FreeBSD
  • FTP
  • GIMP
  • Git
  • Hadoop
  • HAProxy
  • Java
  • Jenkins
  • Joomla
  • Kali Linux
  • KDE
  • Kubernetes
  • KVM
  • Laravel
  • Let's Encrypt
  • LFCA
  • Linux Certifications
  • Linux Commands
  • Linux Desktop
  • Linux Distros
  • Linux IDE
  • Linux Mint
  • Linux Talks
  • Lubuntu
  • LXC
  • Mail Server
  • Manjaro
  • MariaDB
  • MongoDB
  • Monitoring Tools
  • MySQL
  • Network
  • Networking Commands
  • NFS
  • Nginx
  • Nodejs
  • NTP
  • Open Source
  • OpenSUSE
  • Oracle Linux
  • Package Managers
  • Pentoo
  • PHP
  • Podman
  • Postfix Mail Server
  • PostgreSQL
  • Python
  • Questions
  • RedHat
  • Redis Server
  • Rocky Linux
  • Security
  • Shell Scripting
  • SQLite
  • SSH
  • Storage
  • Suse
  • Terminals
  • Text Editors
  • Top Tools
  • Torrent Clients
  • Tutorial
  • Ubuntu
  • Udemy Courses
  • Uncategorized
  • VirtualBox
  • Virtualization
  • VMware
  • VPN
  • VSCode Editor
  • Web Browsers
  • Web Design
  • Web Hosting
  • Web Servers
  • Webmin
  • Windows
  • Windows Subsystem
  • WordPress
  • Zabbix
  • Zentyal
  • Zorin OS
Visits
  • 0
  • 510
  • 1,055,282

DesignLinux.com © All rights reserved

Go to mobile version