Tutorials

An Introduction to the FreeBSD
Open-Source Operating System

Dr. Marshall Kirk McKusick
Who should take this course:

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. Individuals involved in
technical and sales support can learn the capabilities and limitations
of the system; applications developers can learn how to effectively
and efficiently interface to the system; systems programmers without
direct experience with the FreeBSD kernel can learn how to maintain,
tune, and interface to such systems. This course is directed to
users who have had at least a year of experience using a UNIX-like
system. They should have an understanding of fundamental algorithms
(searching, sorting, and hashing) and data structures (lists, queues,
and arrays).

The course is divided into two days. Together they cover the entire
FreeBSD kernel but subjects have been arranged such that students can
also decide to attend only the first or the second day depending on
the subjects in which they are interested.

Description

This course will provide a firm background in the FreeBSD kernel.
The POSIX kernel interfaces will be used as examples where they are
defined. Where they are not defined, the FreeBSD interfaces will
be described. The course will cover basic kernel services, process
structure, locking, jails, scheduling, signal handling, and virtual
and physical memory management. The kernel I/O structure will be
described showing disk management, how I/O is multiplexed, and
the configuration of special devices. Next the organization of
the filesystem will be described showing how its buffer pool is
integrated with the virtual memory system. The course then covers the
implementation of the fast filesystem and its capabilities including
soft updates and snapshots. The filesystem interface will then be
generalized to show how to support multiple filesystem types. The
course also covers the socket-based network architecture, layering,
and implementation. The socket communications primitives and internal
layering will be discussed, with emphasis on the interfaces between
the layers; the TCP/IP implementation will be used as an example.
A discussion of routing issues will be included. The presentations
will emphasize code organization, data structure navigation, and
algorithms. It will not cover the machine specific parts of the
system such as the implementation of device drivers.

Topics:

Day 1 morning – Kernel Overview

  • Process structure
  • Locking
  • Communications
  • Process Groups and Sessions
  • Jails
  • Scheduling
  • Signals and timers
  • Virtual memory management

Day 1 afternoon – Kernel I/O structure

  • I/O data structures
  • Disk Management
  • Multiplexing I/O
  • Autoconfiguration strategy
  • Configuration of a device driver

Day 2 morning – Filesystems Overview

  • Filesystem organization
  • Block I/O system (buffer cache)
  • Filesystem implementation
  • Soft Updates and Snapshots
  • Support for multiple filesystems

Day 2 afternoon – Networking Implementation

  • System layers and interfaces
  • Internet Protocols
  • Mbufs and control blocks
  • Routing issues
  • TCP algorithms
Course Text:

Marshall Kirk McKusick, Keith Bostic, Michael J Karels, and
John S. Quarterman, “The Design and Implementation of the 4.4BSD
Operating System”, Addison-Wesley Publishing Company, Reading,
Massachusetts, 1996, 608 pages.

Speaker biography:

Dr. Marshall Kirk McKusick writes books and articles, teaches
classes on UNIX- and BSD-related subjects, and provides
expert-witness testimony on software patent, trade secret,
and copyright issues particularly those related to operating
systems and filesystems. He has been a developer and commiter
to the FreeBSD Project since its founding in 1994. While
at the University of California at Berkeley, he implemented
the 4.2BSD fast filesystem and was the Research Computer
Scientist at the Berkeley Computer Systems Research Group
(CSRG) overseeing the development and release of 4.3BSD and
4.4BSD. He earned his undergraduate degree in electrical
engineering from Cornell University and did his graduate
work at the University of California at Berkeley, where he
received master’s degrees in computer science and business
administration and a doctoral degree in computer science.
He has twice been president of the board of the Usenix
Association, is currently a member of the editorial board
of ACM’s Queue magazine, and is a member of the Usenix
Association and ACM, and is a senior member of the IEEE.

In his spare time, he enjoys swimming, scuba diving, and
wine collecting. The wine is stored in a specially
constructed wine cellar (accessible from the Web at
http://www.mckusick.com/~mckusick/) in the basement of the
house that he shares with Eric Allman, his (now) husband
of 35-and-some-odd years.

Building The Network You Need With PF,
The OpenBSD Packet Filter

Peter Hansteen
Who should take this course
This session is aimed at experienced or aspiring network administrators who want to expand their knowledge of PF, the OpenBSD packet filter, and related tools. A basic knowledge of Unix and TCP/IP network configuration is expected and required.
Topics potentially covered include

  • Configuration on OpenBSD, FreeBSD and NetBSD
  • PF ruleset basics and rule interactions: block, pass, match
  • Writing maintainable rulesets
  • Address families: IPv4 NAT vs IPv6
  • Redirection, divert and services with odd dependencies (ftp-proxy, spamd)
  • Adaptive rulesets (state tracking tricks)
  • Traffic shaping with priorities and ‘newqueue’, OpenBSD 5.5 style
  • Legacy ALTQ traffic shaping
  • Per user filtering with authpf
  • High availability with CARP, relayd
  • Wireless vs wired networks
  • Filtering bridges
  • Logging and monitoring – pflog, pflow and others
  • Testing, debugging, and optimizing your configuration
Session information
The session will provide updates on the new PF syntax and features introduced in OpenBSD 4.7 (with samples presented in the old and new syntax where appropriate), with newer updates and previews of relevant new features such as the new traffic shaping subsystem introduced in OpenBSD 5.6 and any other PF related improvements in the upcoming OpenBSD 5.6 release (planned release date November 1st, 2014).
Session materials
The available material (notes and slides I’ve accumulated over the years) covers significantly more than the schedule allows for. To help make the session more targeted to your needs, I would appreciate if you, when you sign up for the session or soon after, send me an email to tutorial@bsdly.net with description of what you would like to learn in this session, and to the extent you are allowed and feel it is appropriate, what your near or longer term future project is.Slides matching the latest version of the tutorial can be found at http://home.nuug.no/~peter/pf/newest/; updated slides will be made available to the general public after the present session has concluded.Timing and logistics allowing, copies of the third edition of Hansteen’s The Book of PF will be available to purchase at the session. (Also see The Book of PF, 2nd edition, No Starch Press November 2010).
Speaker biography:
Peter N. M. Hansteen is a consultant, writer and sysadmin based in Bergen, Norway. He has been tinkering with computers since the mid 1980s, mainly while working to document how the systems work and why they don’t, in English as well as his native Norwegian. Peter rediscovered Unixes about the time 386BSD appeared. After a few years on Linux, which included participation in the RFC1149 implementation (2001), he eventually migrated all important systems in his care to FreeBSD and OpenBSD.A long time freenix advocate, he is a member of the BLUG (Bergen (BSD and) Linux User Group) core group and a former vice president of NUUG (the Norwegian Unix User Group). During recent years a frequent lecturer and tutor with emphasis on OpenBSD and FreeBSD topics, author of several articles and The Book of PF (3rd edition No Starch Press 2011) and maintains his blogosphere presence at http://bsdly.blogspot.com.

Transition to OpenBSD 5.6

Peter Hansteen
Who should take this course
The intended audience or attendee profile is anybody who is considering making the jump to OpenBSD 5.6. You may be considering moving your systems wholly or partly to the new release from an earlier OpenBSD release or to move specific parts of your operation from a different Unix-like operating system to OpenBSD.To help make the session more targeted to your specific interests and needs, I would appreciate if, when you sign up for the session or soon after, send me an email to transition@bsdly.net with a brief description of what you would like to learn in this session, and to the extent you are allowed and feel it is appropriate, what your near or longer term future OpenBSD project is.
Description:
OpenBSD has been the source of a number of BSD innovations over the years, including but not limited to PF (the OpenBSD packet filter, now including a new traffic shaping engine), significantly improved IPSEC tools, OpenSSH (the free Secure Shell server and client), security enhancements including preemtive exploit mitigation, and various other advances of the art and engineering in various parts of the system.At the time of writing (early May 2014) the big news items for OpenBSD 5.6 seem to be the removal of the legacy ALTQ traffic shaping system after a one release grace period (the new traffic shaping system is now the only option), OpenSMTPD as the default mail transfer agent, the debut of the LibreSSL library as an in-tree developed project, the removal of BIND as the default DNS server in favor of nsd and unbound, plus switching the base httpd to nginx (retiring the forked apache 1.3), but it’s not set in stone yet and every release has enhancements that may not be immediately obvious until you start using the system.This session intends to help you tackle the transition to the newest OpenBSD release, highlighting enhancements in the new release and how to avoid any pitfalls that may turn up during the process.
Speaker biography:
Peter N. M. Hansteen is a consultant, writer and sysadmin based in Bergen, Norway. He has been tinkering with computers since the mid 1980s, mainly while working to document how the systems work and why they don’t, in English as well as his native Norwegian. Peter rediscovered Unixes about the time 386BSD appeared. After a few years on Linux, which included participation in the RFC1149 implementation (2001), he eventually migrated all important systems in his care to FreeBSD and OpenBSD.A long time freenix advocate, he is a member of the BLUG (Bergen (BSD and) Linux User Group) core group and a former vice president of NUUG (the Norwegian Unix User Group). During recent years a frequent lecturer and tutor with emphasis on OpenBSD and FreeBSD topics, author of several articles and The Book of PF (3rd edition No Starch Press 2011) and maintains his blogosphere presence at http://bsdly.blogspot.com.

Subversion for FreeBSD developers

Stefan Sperling
Description
FreeBSD switched from CVS to Apache Subversion in 2008. It is the only
major BSD operating system using Subversion for version control and one
of the largest open source projects using it. This tutorial provides a
solid introduction to Subversion geared towards FreeBSD developers.We’ll start with a quick review of Subversion’s design from its conception
in the year 2000 and all the features and quirks added during its still
on-going evolution.We’ll talk about Subversion’s repository and working copy, merging and
merge-tracking, how Subversion’s tree conflict detection feature can
help but also get in the way, the why and how of pitfalls associated
with renames, and more.FreeBSD’s workflow built around Subversion will be discussed with
attendees and reviewed for problems and possible improvements.
Attendees are welcome to present any issues they’ve run into with
Subversion during FreeBSD development.
Speaker biography:
Stefan Sperling works as Subversion developer and consultant at elego
Software Solutions GmbH based in Berlin. He has been contributing to
the Subversion project since 2007. He’s been involved in OpenBSD
development since 2008 even though code he produces during hackathons
is the result of sleep deprivation more than anything else.
At elego he has colleagues working on git and they all get along very well.

Let’s make manuals more useful!

Ingo Schwarze
Who should take this course:

This course is intended for the following audiences. For each group, the topic numbers that will be of the most immediate interest are listed, but the other topics are likely to be useful as well.

  • Software developers, since no software is complete without documentation – in particular, but not limited to, developers of publicly available, portable software. (1, 2, 3, 4, 0)
  • Operating system developers, since all operating system development and maintenance includes keeping the system’s native documentation, and the tools handling it, up to date. (5, 6, 7, 3, 4, 0)
  • Porters, that is, people porting software to a given operating system and providing ports and packages. Such work usually requires dealing with a wide variety of documentation formats. (6, 7, 3, 2, 4)
  • Documentation developers, that is, people specifically working on software manuals, even if they are not developing the software itself. (0, 1, 2, 3, 4, 7)
  • System administrators, to understand how documentation is written, built, installed, and indexed for searching, to help troubleshooting and supporting their users. (6, 2, 4, 1, 7)
  • Some end users of computers running BSD operating systems may also find the course interesting to better understand how to use documentation search and display tools and to get some background on how these tools, and documentation formatting and installation in general, works. (4, 0, 1, 7)

Attendants are expected to have basic experience using the command-line user interface of UNIX-like operating systems. Basic experience in programming and system administration may help understanding a few points, but is not required. Prior knowledge about documentation formatting and processing tools is not required, but doesn’t hurt either.

Ingo Schwarze will try to keep the content accessible for newcomers to the field of documentation formatting, but to also cover the newest developments and tools that specialists in the field will be interested in.

If participants drop Ingo Schwarze a mail beforehand to, preferably right after registering, stating their background and/or what they are most interested in, he can use such information to tune the course content towards the audience.

Description
Manual pages have been a resource of critical importance in UNIX for more than 40 years, since Version 1 AT&T UNIX. The steady evolution of the mandoc toolbox during the last six years allows to leverage the various strengths of the concept much better than in the past and to deliver more useful documentation.

  • (0) The course will start with a brief introduction explaining what these strengths are, and providing some historical background.

After that, it will teach:

  • (1) How to get started using the mdoc(7) formatting language for writing new software manuals, how to do so without spending too much time learning the language, and which resources to use while working on mdoc(7) manuals.
  • (2) How to make sure that mdoc(7)-based documentation in a portable software distribution is portable, using the mandoc(1) -Tman output mode and the ./configure mechanism.
  • (3) How to support quality control of existing manuals using mandoc(1) – Tlint and other tools.

At about this point, there will be a working phase with hands-on exercises.

  • (4) How to use the mandoc-based apropos(1) search tool and how to build its databases with makewhatis(8).
  • (5) How to effectively integrate mandoc(1) as a manual formatter and manual page search system into the base system of a BSD operating system and what to pay attention to while doing so
  • (6) How to effectively use mandoc(1) as a manual formatter and manual page search system in a porting and packaging framework, and what to do about manuals that require groff(1) for correct formatting.
  • (7) Which next steps are recommended for the major BSD systems: OpenBSD, NetBSD, FreeBSD, DragonFly, …

Depending on what Ingo Schwarze gets done in mandoc development during the summer, he is likely to add one or two surprise topics to the course showing the latest developments.

Speaker biography:
Ingo Schwarze has been an OpenBSD user since 2001 and a developer
since 2009. He maintains the OpenBSD in-tree mandoc since making
it the only documentation formatter in the base system in 2009/2010.
He also maintains the portable mandoc distribution since 2013 and
the OpenBSD groff(1) port since 2010 and has contributed to various
parts of the OpenBSD userland, for example the Perl rewrite of the
security(8) script, as well as smaller contributions to man(1), to
the rc.d(8) framework, the yp(8) subsystem, the C library, and
various other programs. Outside the free software world, he studied
physics in Siegen/Germany and worked as a researcher in elementary
particle physics at CERN and at the University of Karlsruhe (KIT),
and as a Perl programmer for Sophos UTM.

Gold sponsors:

Silver sponsors: