How to check kernel module dependencies on Linux

Similar to software packages, many Linux kernel modules are not self-contained, but rather rely on other modules to load and operate successfully. It is useful to know kernel module dependencies under various circumstances. For example, you may want to know which other modules a particular misbehaving kernel module relies on, so that you can find […]
Continue reading…

 

How to build a custom kernel module or device driver for XenServer

Citrix allows one to build any custom kernel module or hardware driver for XenServer, by offering Driver Development Kit (DDK). A DDK is essentially a virtual machine with all the kernel headers and development tools needed to extend the XenServer kernel. The following guide is on how to use DDK to compile a custom kernel […]
Continue reading…

 

How to compile the Linux kernel on Debian or Ubuntu

Reasons why you want to build a custom Linux kernel are numerous. For example, you may want to add driver support for devices which are not recognized by the generic kernel shipped with Linux distros. You may want to optimize the kernel for your hardware, tweak performance tuning options, or turn on or off specific […]
Continue reading…

 

How to reboot automatically after kernel panic

There are cases where you encounter kernel panic. Kernel panic may occur while you are playing with some experimental kernel module that someone else wrote, or developing a custom kernel module yourself. Kernel panic can happen due to hardware failure as well. If you would like to reboot your system automatically after kernel panic has […]
Continue reading…

 

How to reload sysctl.conf

Linux provides a sysctl interface for checking and modifying kernel parameters which are listed under /proc/sys directory. You can persistently set or change those kernel parameters via /etc/sysctl.conf. If you have modified /etc/sysctl.conf, and want to activate the change in the kernel without rebooting, you need to do the following. On FreeBSD: $ sudo /etc/rc.d/sysctl […]
Continue reading…

 

How to load a kernel module at boot time

Loadable kernel modules are a convenient way to modify the running kernel without rebuilding the kernel from scratch. You can also free up memory resources by unloading any unnecessary kernel module. A kernel module can be loaded or unloaded on the fly by modprobe command. When loading a kernel module with modprobe, the command will […]
Continue reading…