Section 5 - Some pitfalls

# 6 Section 5 - Some pitfalls

Contents of this section

## 6.1 5.0. make clean

If your new kernel does really weird things (it's happened to me), chances are you forgot to make clean. Symptoms can be anything from your kernel outright crashing, to strange I/O problems, to crummy performance. Make sure you do a make dep, too.

## 6.2 5.1. Huge or slow kernels

If your kernel is sucking up a lot of memory, or is getting really big, or really takes forever to compile even when you've got your new 486DX6/440 working on it, you've probably got lots of unneeded stuff (device drivers, filesystems, etc) configured. If you don't use it, don't configure it, because it does take up memory. If you've got less than 16 megs, make sure that you say yes to ```limit memory to low 16MB`;'' it makes a lot of difference (especially on a 4MB system). The most obvious symptom of bloat is extreme swapping in and out of memory to disk. If your disk is making a lot of noise, look over your kernel configuration.

You can find out how much memory the kernel is using by taking the total amount of memory in your machine and subtracting it from the amount of ``total mem'' in `/proc/meminfo` or the output of the command ```free`.'' You can also find out by doing a ```dmesg`'' (or by looking at the kernel log file, wherever it is on your system). There will be a line that looks like this:

`Memory: 15124k/16384k available (552k kernel code, 384k reserved, 324k data)`

My 386 (which has slightly less junk configured) says this:

`Memory: 7000k/8192k available (496k kernel code, 384k reserved, 312k data)`

## 6.3 5.2. Kernel doesn't compile

If it doesn't compile, then a patch has probably failed, or you got corrupted sources from somewhere. Your version of gcc also might not be correct, or could be messed up. Make sure that the symlinks which Linus describes in the README are right. In general, if a kernel doesn't compile, something is seriously wrong.

## 6.4 5.3. New version of the kernel doesn't seem to boot

LILO either wasn't run, or isn't configured correctly. One thing that ``got'' me once was a problem in the config file. I had ```boot = /dev/hda1`'' instead of ```boot = /dev/hda`'' (This can be really annoying at first, but once you've got a working config file, you shouldn't need to change it.).

## 6.5 5.4. It says ``warning: bdflush not running''

This can be a pretty severe problem. Starting with a kernel release after 1.0 (I can't remember which, exactly, but it was around 20 Apr 1994), a program called ```update`'' which periodically flushes out the filesystem buffers was upgraded/replaced. Get the sources to ```bdflush`'' (you should find it where you got your kernel), and compile it (You will probably want to run under the old kernel while compiling and installing). It will install itself as ```update`'' and you should be fine with the new kernel after that.

## 6.6 5.5. It says weird things about obsolete routing requests

Get new versions of the route program and/or recompile the old stuff. `/usr/include/linux/route.h` (which is actually a file in `/usr/src/linux`) has changed.

Next Chapter, Previous Chapter

Table of contents of this chapter, General table of contents

Top of the document, Beginning of this Chapter