Tips And Tricks
Q:
How can I prevent kernel modules from starting?
A:
Just put them in the blacklist.
Q:
How can I put kernel modules in blacklist?
A:
Add the line
blacklist moduleName
to
/etc/modprobe.d/blacklist.conf
or, in just one step, run
# echo "blacklist moduleName" >> /etc/modprobe.d/blacklist.conf
Q:
How can I add modules to kernel?
A:
It is possible to use insmod or modprobe. In most cases modprobe is preferred because it discovers if the module that is going to be added needs other modules and resolves dependencies.
# modprobe moduleName
Q:
How can I use multiple cores to speed up kernel compiling?
A:
Using the -jN parameter make splits his entire work in N jobs:
$ make -j4 bzImage
I used -j4 because of my Intel Atom D525 (2 cores, 2 threads each core).
Q:
How can I create a kernel configuration file (.config) from my local settings?
A:
I recently discovered a fast way to obtain a .config file from le local modules and drivers loaded in my system. Inside the kernel source folder you can run the command:
# make localmodconfig
to create also modules and initrds, or:
# make localyesconfig
to create a big monolith.