Many Linux newbies think that kernel recompilation is inherent and almost necessary thing to do after OS is just installed or some time later. By the following advices I would try to show these fellows in which situations this really makes sense and what to do if one persists
1. If you don't know why you should patch/recompile kernel - DO NOT DO THIS.
2. If your running kernel is smart and supports all necessary hardware, technologies and doesn't contain critical vulnerabilities - DO NOT REBUILD IT.
3. If you don't know what are kernel patches and why they are used - DO NOT REBUILD KERNEL.
4. If kernel with needed functionality is available as binary package for your distribution (especially in official repositories) - DO NOT BUILD KERNEL.
5. If you insist, certainly read Kernel HOWTO and notes about kernel recompilation in regards to your distribution.
6. Do change kernel config values only if you know what they mean.
7. Don't forget to build initrd before rebooting your system.
8. Do not remove workable kernel and make it default in boot loader menu (like grub).
9. Don't panic if something goes wrong - most probably the same situation happened to thousands people earlier. But sometimes shit happens.
10. Rebuilding procedure usually takes hours depending on hardware you use. BE PATIENT! 
11 (thanks to Erek Dyskant). Use your distro’s package management system to build kernels whenever possible (like make-kpkg in Debian or rpmbuild in Fedora/RedHat/CentOS)
I really hope this helps and pretty sure you'll build your "perfect" kernel once
Any further advices are WELCOME!
P.S. Thanks to Stas Kogut for encouraging me to write this post.
Welcome to Linux Screw! If you're new here, you may want to subscribe our RSS feed.
Share This
As it comes from name of the post, here is interactive Linux kernel map I recently came across. It’s available as web application as well as html version. I think you understand who it may be useful for…
Good luck in programming!
Share This
Small tip: there is modinfo utility to get more information regarding Linux kernel modules. Here is an example of it’s usage:
viper@viper-laptop:~$ modinfo ati_agp
filename: /lib/modules/2.6.20-16-lowlatency/kernel/drivers/char/agp/ati-agp.ko
license: GPL and additional rights
author: Dave Jones
srcversion: 6920C657E39118CCE9BAC63
alias: pci:v00001002d*sv*sd*bc06sc00i00*
depends: agpgart
vermagic: 2.6.20-16-lowlatency SMP preempt mod_unload 586
Share This
There are several utilities in FreeBSD to manage kernel modules. Among them are: kldload, kldstat, kldunload.
First (kldload) would be useful for loading files *.ko into FreeBSD kernel using kernel linker. Second (kldstat) displays status of files loaded into kernel. Third (kldunload) helps to unload files which were previously loaded into kernel with kldload.
This utilities are analogues of modprobe and lsmod utilities in Linux.
Example: in order to enable ipfw kernel module without FreeBSD restarting you can do:
cd /boot/kernel
kldload ipfw.ko
Another way to enable ipfw is to add line firewall_enable="YES" into /etc/rc.conf and restart FreeBSD. But kldload method is much more easier and fast as for me 
Share This
M. Tim Jones, Consultant Engineer, Emulex Corp.:
One of the greatest features of the Linux® operating system is its networking stack. It was initially a derivative of the BSD stack and is well organized with a clean set of interfaces. Its interfaces range from the protocol agnostics, such as the common sockets layer interface or the device layer, to the specific interfaces of the individual networking protocols. This article explores the structure of the Linux networking stack from the perspective of its layers and also examines some of its major structures.

Anatomy of the Linux networking stack by IBM.
Share This
Recent Ideas