Module location
Kernel modules are located in /lib/modules/$(uname -r) and can be compiled for specific kernel versions.
Module Utilities
There are a number of utility programs that are used with kernel modules:
- lsmod
List loaded modules. - insmod
Directly load modules. - rmmod
Directly remove modules. - modprobe
Load or unload modules, using a pre-built module database with dependency and location information. - depmod
Rebuild the module dependency database. - modinfo
Display information about a module.
*** Use the modprobe command to load a module:
$ modprobe e1000e
**** Use the modprobe -r command to unload or remove a module:
$ modprobe -r e1000e
**** modprobe requires a module dependency database be updated. Use the depmod command to generate or update the file /lib/modules/$(uname -r)/modules.dep.
***Use the insmod command to directly load a module (requires fully qualified module name):
$ insmod /lib/modules/$(uname -r)/kernel/drivers/net/ethernet/intel/e1000e.ko
***Use the rmmod command to directly remove a module:
$ rmmod e1000e
*** Use the lsmod command to list the loaded modules:
$ lsmod
*** Use the modinfo command to display information about a module (including parameters):
$ modinfo e1000e
No hay comentarios:
Publicar un comentario