FreeBSD Kernel Internals Course Description

What is FreeBSD?

FreeBSD, like Linux, is an open-source UNIX-like operating system that is widely used to support the core infrastructure of many companies worldwide. Because it can be built with a small footprint, it is also seeing increased use in embedded applications. The licensing terms of FreeBSD do not require the distribution of changes and enhancements to the system. The licensing terms of Linux require that all changes and enhancements to the kernel be made available in source form at minimal cost. Thus, companies that need to control the distribution of their intellectual property increasing are building their products using FreeBSD.

Who Should Take this Course

This course is of direct use to the professionals who work with FreeBSD systems. Applications developers can learn how to effectively and efficiently interface to the system; systems programmers can learn how to extend, enhance, and interface to the system; system administrators without direct experience with the FreeBSD kernel can learn how to maintain, tune, and configure the system; and individuals involved in technical and sales support can learn the capabilities and limitations of the system.

This course provides a broad overview of how the FreeBSD kernel implements its basic services. It will be most useful to those who need to learn how these services are provided. Students who will benefit from this course include operating-system implementors, system programmers, UNIX application developers, administrators, and curious users. This course is directed to users who have had at least a year of experience using a UNIX-like system. Knowledge of the C programming language is helpful, but not essential. They should have an understanding of fundamental algorithms (searching, sorting, and hashing) and data structures (lists, queues, and arrays).

Description

This course provides a firm background in the FreeBSD kernel. The course starts with an introduction to the kernel and the services that it provides including the locking used for concurrency control. Next, the details of processes are described including process management tasks such as scheduling and signals. The security framework and policies are outlined including Capsicum sandboxing and the FreeBSD jail facility that allows the creation of isolated virtual hosts running on the same system. The description of processes concludes with an extensive description of the management of kernel and process memory. The course then turns to an I/O view of the kernel by introducing the I/O framework and detailing the infrastructure for doing I/O multiplexing and supporting both local and remote filesystems. It then describes how it configures and operates both character devices and bulk data transfer devices such as disks and how it manages virtual devices needed support Xen and bhyve virtualization. The design and implementation of three filesystems is covered: the Fast filesystem (FFS), the Zettabyte filesystem (ZFS), and the Network filesystem (NFS). Next the interprocess communication (IPC/socket) interface is detailed followed by coverage of the layering and implementation of the networking including routing, forwarding, and security of the TCP/IP protocols. Following coverage of the kernel startup procedure, the course concludes by pulling the presented concepts together to show how they can be used to do performance measurement and system tuning. The presentations emphasize code organization, data structure navigation, and algorithms rather than reviewing the kernel code itself. It does not cover the machine specific parts of the system such as the implementation of device drivers.

Course Materials

Each student needs a copy of the textbook by Marshall Kirk McKusick, George V. Neville-Neil, and Robert N.M. Watson: The Design and Implementation of the FreeBSD Operating System, Second Edition, published by the Addison-Wesley subsidiary of Pearson Education. Each student also receives a copy of the course notes containing copies of all the overhead slides used in the course and a set of papers that provide supplemental reading to the text book. The evening class and video course also contain a set of weekly readings and exercises. For an extra $50.00 fee, the notes are available in a 550 page spiral-bound book.

Further Information

Click here to get syllabus and class information for the short courses.

Click here to get syllabus and class information for the weekly course and information on how to obtain the class on video.

Click here or on the above to watch the first hour of the first lecture.