Linux is a phenomenon of the internet. Born out of the needs of a poor student to save money it has grown to become more popular than any other freely available operating system. To many Linux is an enigma. How can something that is free be worthwhile? In a world dominated by a handful of large software corporations, how can something that has been written by a bunch of ``hackers'' (sic) hope to compete? How can software contributed to by many different people in many different countries around the world have a hope of being stable and effective? Yet stable and effective it is and compete it does. Many Universities and research establishments use it for their everyday computing needs. People are running it on their home PCs and I would wager that most companies are using it somewhere even if they do not always realize that they do. Linux is used to browse the web, host web sites, write thesis, send electronic mail and, as always with computers, to play games. Linux is emphatically not a toy; it is a fully developed and professionally written operating system used by enthusiasts all over the world.
Linux was the solution to a simple need. Linus Torvalds, its author and principle maintainer was too poor a student to afford to buy Minix. Minix is a simple, Unix like, operating system widely used as a teaching aid but it cost more than Linus either had or was willing to spend. His solution was to write his own software. He took as his model the Unix operating system as that was an operating system that he was familiar with in his day to day student life. Unix is a multi-tasking, multi-user operating system developed by the Computing Research Group at the Bell Laboratories in New Jersey, USA. He started with an Intel 386 based PC and started to write. Progress was rapid and excited by this Linus offered his efforts to other students via the emerging world wide computer networks, then mainly used by the academic community. Others saw the software and started contributing. Much of this new software was itself the solution to a problem that they had. Alan Cox needed the networking code in the Linux kernel and so he wrote some, it was as simple as that. Before long, Linux had become an operating system.
Most people use Linux as a simple tool, often just installing one of the many good CD ROM-based distributions. A lot of Linux users use it to write applications or to run applications written by others. Many Linux users read the HOWTOs avidly and feel both the thrill of success when some part of the system has been correctly configured and the frustration of failure when it has not. A minority are bold enough to write device drivers and offer kernel patches to Linus Torvalds, the creator and maintainer of the Linux kernel. Linus accepts additions and modifications to the kernel sources from anyone, anywhere. This might sound like a recipe for anarchy but Linus exercises strict quality control and merges all new code into the kernel himself. At any one time though, there are only a handful of people contributing sources to the Linux kernel.
The majority of Linux users do not look at how the operating system works, how it fits together. This is a shame because looking at Linux is a very good to learn more about how an operating system functions. Not only is it well written, all the sources are freely available for you to look at. This is because although the authors retain the copyrights to their software, they allow the sources to be freely redistributable under the Free Software Foundation's GNU Public License. At first glance though, the sources can be confusing; you will see directories called /kernel, /mm and /net but what do they contain and how does that code work? What is needed is a broader understanding of the overall structure and aims of Linux. This, in a nutshell, is the aim of this book: to promote a clear understanding of how Linux, the operating system, works. To provide a mind model that allows you to picture what is happening within the system as you copy a file from one place to another or read electronic mail. I well remember the excitement that I felt when I first realized just how an operating system actually worked. It is that excitement that I want to pass on to the readers of this book.
My involvement with Linux started late in 1994 when I visited Jim Paradis who was working on a port of Linux to the Alpha AXP processor based systems. I have worked for Digital Equipment Co. Limited since 1984, mostly in networks and communications and in 1992 I started working for the newly formed Digital Semiconductor division. This division's goal was to enter fully into the merchant chip vendor market and sell chips, and in particular the Alpha AXP range of microprocessors but also and Alpha AXP system boards outside of Digital. When I first heard about Linux I immediately saw an opportunity to sell more Alpha AXP hardware. Jim's enthusiasm was catching and I started to help on the port. As I worked on this, I began more and more to appreciate not only the operating system but also the community of engineers that produces it. They are, by any standards, a remarkable set of people and my involvement with them and with the Linux kernel has been perhaps the most satisfying time of my time in software development. People often talk to me about Linux at work and at home and I am only too happy to oblige as the more that I have used Linux in both my professional and personal life the more that I have become a Linux zealot. The may note that I use the term `zealot' and not `bigot'; I define a Linux zealot to be an enthusiast that recognizes that there are other operating systems but prefers not to use them. As my wife, Gill, once remarked ``I never realized that we would have his and her operating systems''. For me, as an engineer, Linux suits my needs perfectly. It is a superb, flexible and adaptable engineering tool. Mostly freely available software easily builds on Linux and can often simply download pre-built executables files or install them from a CD ROM. What else could I use to learn to program in C++ or learn about Java for free?
Alpha AXP is only one of the many hardware platforms that Linux runs on. Most Linux kernels are running on Intel processor based systems but a growing number of non-Intel Linux systems are becoming more commonly available. Amongst these are Alpha AXP, MIPS, Sparc and PowerPC. This book could have been written using any one of those platforms but my background and technical experiences with Linux are with Linux on the Alpha AXP and this is why this book sometimes uses that hardware as an example to illustrate some key point. It must be noted that around 95% of the Linux kernel sources are common to all of the hardware platforms that it runs on. Likewise, around 95% of this book is about the machine independent parts of the Linux kernel.