The Linux kernel is modular. Instead of building every driver into one huge image, most drivers and features ship as loadable kernel modules, files ending in .ko (sometimes compressed, such as .ko.xz) stored under /lib/modules/$(uname -r)/. The kernel, helped by udev, loads a module automatically when matching hardware appears, and an administrator can load, unload, inspect and configure modules without rebooting. This keeps the kernel small and lets one kernel image run on very different hardware. lsmod lists the modules currently loaded, with their size and a 'Used by' column showing how many users each has and which other modules depend on it. It simply formats the contents of /proc/modules. modinfo name shows details about a module file: its path, description, license, author, dependencies and, importantly, the parameters it accepts. That parameter list is how you learn which options you can set. Once a module is loaded, its current parameter values usually appear under /sys/module/name/parameters/.
Keep reading for free
Create a free StudyToCert account to read the rest of this lesson: 7 more sections, 6 key terms, a real-world example, an exam tip and self-check questions. Every lesson, lab and practice test is free with an account.