The Linux Kernel HOWTO

Al Dev (Alavoor Vasudevan)


v6.7, 15 Aug 2003

This is a detailed guide to kernel configuration, compilation, upgrades, and troubleshooting for ix86-based systems. Can be useful for other architectures as well. This document is kept small & simple, so that even non-technical "home computer users" will be able to compile and run the Linux Kernel.

Table of Contents
1. Introduction
2. Quick Steps - Kernel Compile
2.1. Precautionary Preparations
2.2. Minor Upgrading of Kernel
2.3. New Release Changes: Documentation
2.4. For the Impatient
2.5. Building New Kernel - Explanation of Steps
2.6. Troubleshooting
2.7. Post Kernel Building
3. Loadable Modules
3.1. Installing the module utilities
3.2. Modules distributed with the kernel
3.3. Howto Install Just A Single Module ?
4. Cloning of Linux Kernels
5. Important questions and their answers
5.1. What does the kernel do, anyway?
5.2. Why would I want to upgrade my kernel?
5.3. What kind of hardware do the newer kernels support?
5.4. What version of gcc and libc do I need?
5.5. What's a loadable module?
5.6. How much disk space do I need?
5.7. How long does it take?
6. Patching the kernel
6.1. Applying a patch
6.2. If something goes wrong
6.3. Getting rid of the .orig files
6.4. Other patches
7. Tips and tricks
7.1. Redirecting output of the make or patch commands
7.2. Conditional kernel install
7.3. Kernel updates
8. Mount RPMs With FTPFS
8.1. Using the ftpfs
8.2. The ftpfs Commands
9. Linux Kernel Textbooks and Documents
10. Kernel Files Information
10.1. vmlinuz and vmlinux
10.2. Bootloader Files
10.3. Message File
10.4. initrd.img
10.5. bzImage
10.6. module-info
10.7. config
10.8. grub
11. Linux System Administration Tools
12. Advanced Topics - Linux Boot Process
12.1. References for Boot Process
13. Other Formats of this Document
13.1. Acrobat PDF format
13.2. Convert Linuxdoc to Docbook format
13.3. Convert to MS WinHelp format
13.4. Reading various formats
14. Appendix A - Creating initrd.img file
14.1. Using mkinitrd
14.2. Kernel Docs
14.3. Linuxman Book
15. Appendix B - Sample lilo.conf
15.1. Resources on LILO
15.2. Troubleshooting LILO
15.3. Sample on LILO
16. Appendix C - GRUB Details And A Sample grub.conf
16.1. References on GRUB
16.2. Tips On GRUB
16.3. Sample GRUB Conf File
17. Appendix D - Post Kernel Building
18. Appendix E - Troubleshoot Common Mistakes
18.1. Kernel Compiles OK but make modules fail
18.2. Compiles OK but does not boot
18.3. The System Hangs at LILO
18.4. No init found
18.5. Lot of Compile Errors
18.6. The 'depmod' gives "Unresolved symbol error messages"
18.7. Kernel Does Not Load Module - "Unresolved symbols" Error Messages
18.8. Kernel fails to load a module
18.9. Loadable modules
18.10. See Docs
18.11. make clean
18.12. Huge or slow kernels
18.13. The parallel port doesn't work/my printer doesn't work
18.14. Kernel doesn't compile
18.15. New version of the kernel doesn't seem to boot
18.16. You forgot to run LILO, or system doesn't boot at all
18.17. It says `warning: bdflush not running'
18.18. I can't get my IDE/ATAPI CD-ROM drive to work
18.19. It says weird things about obsolete routing requests
18.20. ``Not a compressed kernel Image file''
18.21. Problems with console terminal after upgrade to Linux v1.3.x
18.22. Can't seem to compile things after kernel upgrade
18.23. Increasing limits