Q. How do I display list of loaded Linux Kernel modules or device drivers?
A. You need to use lsmod program which show the status of loaded modules in the Linux Kernel. Linux use term modules for hardware device drivers.
lsmod is a trivial program which nicely formats the contents of the /proc/modules, showing what kernel modules are currently loaded.
This is an important task. With lsmod you can verify that device driver is loaded for particular hardware. Any hardware device will only work if device driver is loaded.
Task: List or display loaded modules
$ less /proc/modules
$ lsmod
Output:
Module Size Used by snd_mixer_oss 20096 0 i830 78596 2 sg 39168 0 ppdev 9924 0 sr_mod 17316 0 vmnet 39032 12 vmmon 111788 0 ipv6 264772 12 ipt_LOG 6560 1 ipt_state 2080 1 ip_conntrack_ftp 72368 0 iptable_mangle 2880 0 iptable_nat 25156 0 ip_conntrack 35756 3 ipt_state,ip_conntrack_ftp,iptable_nat .... .. ....
First column is Module name and second column is size of modules i..e the output format is module name, size, use count, list of referring modules.
You should follow me on twitter here or grab rss feed to keep track of new changes.
Featured Articles:
- 30 Handy Bash Shell Aliases For Linux / Unix / Mac OS X
- Top 30 Nmap Command Examples For Sys/Network Admins
- 25 PHP Security Best Practices For Sys Admins
- 20 Linux System Monitoring Tools Every SysAdmin Should Know
- 20 Linux Server Hardening Security Tips
- Linux: 20 Iptables Examples For New SysAdmins
- Top 20 OpenSSH Server Best Security Practices
- Top 20 Nginx WebServer Best Security Practices
- 20 Examples: Make Sure Unix / Linux Configuration Files Are Free From Syntax Errors
- 15 Greatest Open Source Terminal Applications Of 2012

- My 10 UNIX Command Line Mistakes
- Top 10 Open Source Web-Based Project Management Software
- Top 5 Email Client For Linux, Mac OS X, and Windows Users
- The Novice Guide To Buying A Linux Laptop












{ 6 comments… read them below or add one }
Is there any way by which I can know for example “xyz” module is for “xyz” hardware?
Sorry for another comment…
Actually my objective is to find what device drivers(modules) are loaded for my hardware and is there any hardware which doesn’t have the right module installed for it.
Thanks
Harshal.
@Harshal
Hey!
Maybe it is a little bit late, but try out this command: “lspci -v”.
It’ll show a huge list of all PCI devices and all kind of information INCLUDING the current used module.
Hope, it helps.
Alex
helped me thanks.
what command would i use to output the above commands directly to a file?
thanks again
Use the directing “>” symbol.
E.g.
lspci -v > filename.txtAlex
Hi,
what about listing modules which are *NOT* loaded in the kernel?
I.E finding out what’s supported with your kernel?