Review of "Understanding the Linux Kernel" (3rd edition)

Authors: Daniel Pierre Bovet and Marco Cesati
Publisher: O'Reilly
Review by: Cosimo
Rating: ****
Date: 2006/05/07
Copertina del libro

This book is entirely dedicated to the Linux Kernel. This is its 3rd edition. The first, published in 2000, was based on 2.2 kernel. The second, of the end of 2002, was about 2.4. This one is based on 2.6.11.

The authors, Daniel Bovet and Marco Cesati, teach in Tor Vergata Rome University using Linux as "learning material" for their operating systems classes.

The book is more than 900 pages, in 20 chapters, 2 appendixes and an analytical Linux source code index. There are many arguments, from low level (memory management, processes, interrupts) to high level (device drivers, ext2/3 filesystems and executable files).

The reference architecture is x86, which is somewhat simpler. However the book remarks clearly the platform-independent principles, valid for all the architectures.

Throughout the book, several code fragments from Linux source are dissected and analyzed in detail. In these cases, it is useful to have at least a basic knowledge of C language, maybe even some rough idea of Assembler.

UtLK takes you on a guided tour of the most significant data structure, algorithms and programming tricks used in the kernel.

Very interesting is the 7th chapter about Process Scheduling. It explains the "new" process scheduling algorithm adopted in 2.6 kernels, that executes in constant time, no matter the number of running processes.
The previous scheduling mechanism (kernel 2.4) and all the involved data structures are presented, analyzing the transition to the new algorithm, and how the adoption of different data structures helped achieving this spectacular improvement.

One of the big wins of this book is that it helps studying Linux, giving a minimal walk-through guide for the huge kernel source code.

In some parts of the book, like memory pages cache or interrupt management, there are implementation detail explanations of kernel functions with long lists of algorithm steps (even 30!).
Reading those lists without source code at hand is not feasible. They can be useful as references, though.

Conclusions

A very good book, interesting and complete. I'd suggest it to those interested in studying how Linux works and it has been developed.

Pros

Cons