blog

Pourquoi j'aime BSD

· all posts

post

All of us have used Windows or macOS, some of us have used GNU/Linux, but relatively few have used a BSD. Arguably, part of this can be attributed to the licensing disputes and legal battles that troubled the BSD community throughout the early 1990s.

Linus Torvalds once stated that had 386BSD been available when he began developing Linux, Linux probably would never have happened, and he might have contributed to BSD instead. It's an interesting thought.

But alas, it is no long the 90s. The legal troubles have long since been resolved, the original BSD-4-CLAUSE advertising requirement was pulled back by Berkeley, and 386BSD's descendants have grown into mature operating systems with vastly different philosophies.

So where do we stand today, and why do I enjoy this group of operating systems enough to dedicate an entire article to them? For those who don't enjoy falling down rabbit holes and opening every link in an article, we'll begin with a brief diagrammatic history of BSD.

BSD Family Tree

Nice and brief, innit? XD Thanks ryoon for the diagram.

This diagram is an excellent family tree of UNIX through the ages. There is a metric ton of history here, far more than I intend to cover in one or many article/s, but the take away is how three projects which descend from much of the same code, have spent over thirty years developing their own identities. Namely FreeBSD, NetBSD, and OpenBSD.

All three are general-purpose UNIX-like operating systems. They share a common ancestry, many conventions, and plenty of code and ideas. They are also developed as complete operating systems, with the kernel, core utilities, documentation, and system configuration maintained as parts of a larger whole. But where they differ is in each's priority.

FreeBSD has spent much of its existence refining an operating system suited to servers, networking, storage, and demanding production workloads. OpenBSD places extraordinary emphasis on correctness, security, and code auditing. NetBSD has pursued portability to an extent that few, if any, other operating system can claim. These are not exclusive qualities of course; FreeBSD cares about security just not as anally as OpenBSD (No OS does.), OpenBSD supports numerous architectures, just not to the extent of NetBSD, and NetBSD is perfectly capable of running production services, just far more hands on than FreeBSD.


FreeBSD

FreeBSD emerged in 1993 from the work surrounding 386BSD and its unofficial patchkit. Developers including Jordan Hubbard, Nate Williams, and Rod Grimes wanted to produce a maintained and usable system rather than continue accumulating patches against an aging release.

From those beginnings, FreeBSD developed into an operating system with a strong reputation for networking, performance, reliability, and server workloads.

What I enjoy most about FreeBSD is the practically of it. It has never struck me as a project particularly interested in reinventing the operating system, and instead its development seems directed toward making an already capable system more useful. Perhaps not useful to YOU in particular, since desktop support is lacking, an example being 802.11ac support only coming in 2024. But technologies that demonstrate this particularly well are jails and bhyve.

Jails were introduced with FreeBSD 4.0 in 2000, allowing administrators to isolate services and operating environments while sharing the host's kernel. They extend the traditional chroot concept by restricting more than filesystem access, including processes, users, and networking resources.

Yes, linux does have a similar ability called LXC, but that required kernel patching to achieve, and for those unfamiliar with the linux kernel its a feat of its own to build. One I encourage any striving sysadmin to do at least once! It was not until dockers release in 2013 that Linux containerization (feature wise) caught up to jails. Before docker fan boys can say anything though, jails provide stronger security than Docker containers. They are a native kernel feature isolating processes by default, and do not require a privileged daemon or a complex configuration. Docker relies on stacking multiple mechanisms (namespaces, cgroups, seccomp) and historically runs with root privileges. To achieve comparable (not equal) isolation requires deliberate hardening, enjoy that docuhell rabbit hole, try and remember what you did. :-)

Bhyve is a hypervisor introduced into the FreeBSD base system with the release of FreeBSD 10.0 in 2014. While jails provide operating-system-level isolation, bhyve allows FreeBSD to host full virtual machines, including entirely different operating systems.

Now, is bhyve as feature-rich as something like Proxmox? No, but that isn't really a fair comparison either. Proxmox is an entire virtualization platform built around managing virtual machines and containers utilizing KVM and QEMU as its virtual stack and debian as the OS host. Bhyve, on the other hand, is just another capability built into FreeBSD. It doesn't attempt to turn FreeBSD into a dedicated virtualization platform, but can be ran as one. While Proxmox is usually considered Type 1 (Bare-metal), Bhyve can be either Type 1 or Type 2 (hosted) like virtualbox.

I've run FreeBSD with a full graphical environment (a loose term, considering I still use Fluxbox, but what is a desktop environment other than a window manager with a bunch of tools slapped onto it?) using my Ryzen's integrated graphics, while simultaneously running Windows in a bhyve virtual machine with my Radeon RX 7600 passed directly through to it.

Connect one monitor to the motherboard for FreeBSD, another connected to the RX 7600 for Windows. Two operating systems, two GPUs, one computer, and a KVM switch for the mouse and keyboard. It is capable of playing Windows games with near-native performance (including games using kernel-level anti-cheat unlike virtualbox), while retaining FreeBSD as my primary operating system.

I have also used FreeBSD as a Type 1 Hypervisor to run multiple services along side jails, There is a slew of jail management and bhyve management software offerings. Or as I like, you can barebones it and use the handbook.

Between these two technologies, FreeBSD offers two very different approaches to running isolated workloads on the same physical machine.

Add in ZFS, the Ports Collection and FreeBSD's extensive networking capabilities, and you have an operating system that deserves far more attention than it receives.

There is considerably more to discuss here, particularly concerning jails, VNET, bhyve, and the ways they can be used together. Those deserve an article of their own, and in time they will come.


OpenBSD

OpenBSD began in 1995 when Theo de Raadt, one of NetBSD's original founders, established a separate project following disagreements within the NetBSD development team. Theo de Raadt left the NetBSD project in 1994 after the core team revoked his access to the source repository and asked him to resign due to interpersonal conflicts and his aggressive communication style.

Over the following decades, OpenBSD developed an identity centered on code correctness, proactive security, careful auditing, and integrated cryptography.

I think it would be a mistake to describe OpenBSD simply as a secure operating system, however. Security is the result of a much broader engineering philosophy, and this philosophy is the reason I run it on this very machine I currently write from (a Thinkpad T590).

The developers place considerable emphasis on reducing complexity, examining source code for potential problems, and avoiding unnecessary functionality. Rather than assuming security can be added after the fact, the project treats it as an ongoing concern throughout the development process.

This approach has produced some particularly useful technologies.

The pledge(2) system call allows programs to restrict the categories of operations they are permitted to perform. unveil(2) allows programs to limit which parts of the filesystem they can access. Together, they provide mechanisms for reducing the damage a compromised application might otherwise cause.

There is also pf, OpenBSD's packet filter, which has become one of the most broadly accepted and embraced tools for managing firewalls and network traffic, and has been ported to FreeBSD, NetBSD, and DragonflyBSD. Even MacOS uses a modified version of it.

Probably the best-known contribution from the OpenBSD project is OpenSSH. Anyone who has administered a remote UNIX server has almost certainly encountered it, whether they knew it or not. The default ssh client on FreeBSD, NetBSD, OpenBSD, DragonflyBSD, most GNU/Linux distros, Windows, and Mac is OpenSSH. Most if not all cloud providers use OpenSSH, most ISP's, most routers, and Git Hosting use OpenSSH.

What drew me to OpenBSD though is that its design decisions seem to follow a consistent set of principles. These principles align with my own most the time and is why my main development machine (This Thinkpad T590) runs it. The OpenBSD project is willing to make choices that may be inconvenient to some users if those choices better serve its long-term goals, and that is something I value.

[--Edited 11/08/2026

Most will read that last statement and wonder how the hell that is helpful to anyone! My response is look at the Linux kernel. Its well over 40 Million lines of code at this point, because they are wanting to include everyone's wishes. Yes you can still build a custom kernel. Challenge: Build a FreeBSD kernel and a Linux Kernel. Which was easier, took less time, and is infinitely more scriptable?

More does not mean better, and listening to everyone will ultimately please no one. :-)

Edited 11/08/2026--]

OpenBSD's security mechanisms deserve a much closer examination than I can give them here. I intend to return to pledge, unveil, pf, and several of its other security controls in future articles.


NetBSD

NetBSD is the oldest of the three projects, having been established in 1993 by Chris Demetriou, Theo de Raadt, Adam Glass, and Charles Hannum (No websites for Adam or Charles). And stands alone as a project in rejecting AI derived code.

Like FreeBSD, it originated from dissatisfaction with the development and maintenance of 386BSD. Unlike FreeBSD's early emphasis on the Intel 386 platform, NetBSD placed architecture independence among its central goals and has remained a defining characteristic of the project ever since.

NetBSD is perhaps most famous for its portability. Its codebase has supported an extraordinary variety of processor architectures and hardware platforms, ranging from conventional desktop computers and servers to older workstations, embedded systems, and machines that most people would consider obsolete.

Its unofficial reputation can be summarized by the familiar expression: Of course it runs NetBSD.

Supporting radically different architectures requires developers to consider which parts of an operating system are genuinely machine-independent and which are tied to particular hardware. It encourages careful separation of components and discourages assumptions that only hold true on one platform.

This has produced some interesting implementations, including NetBSD's rump kernels, which allow portions of kernel functionality to operate outside a conventional kernel environment.pkgsrc, NetBSD's package management framework, can be used on operating systems beyond NetBSD itself.

Its pretty clear I have not worked with NetBSD as much, but I still appreciate it takes a novel approach to operating system development. There is something admirable about preserving support for older machines while continuing to develop a modern UNIX-like operating system.

NetBSD's portability also raises an interesting question: just how much of an operating system can remain independent of the hardware it runs on? That is a subject I intend to explore separately, ideally with some decidedly unusual hardware. Here is some examples of what it can run on:

  • The pc532, a homebrew computer board from 1989 ran NetBSD until support was dropped in 2008 when GCC lost compatibility. (Fuckin Stallman..)

  • Sega Dreamcast

  • Nintendo Wii

  • H/PC PDA's


The influence of the BSD's even predate these projects! Berkeley UNIX contributed considerably to the development and adoption of TCP/IP networking, the sockets API, and numerous utilities and operating-system concepts that became commonplace throughout the UNIX world.

These ideas eventually influenced GNU/Linux and other operating systems, whether through code, interfaces, or the broader UNIX conventions they helped establish and I think that is an important part of BSD's history. Its significance cannot be measured solely by how many people install FreeBSD, OpenBSD, or NetBSD on their computers. A great deal of its influence exists elsewhere.

I have spent years working with computers, networks, and various operating systems, both professionally and out of curiosity. I enjoy understanding how systems work, not just learning which commands are necessary to accomplish a particular task.

That curiosity has taken me through just about every operating system, and I have a habit of changing them more frequently than is probably reasonable. I have worked with the OpenBSD, FreeBSD, various implementations of GNU/Linux, HaikuOS, and 9front I still particularly enjoy 9front and will perhaps have an article in time covering it. I have even experimented and worked with smaller Hobbyist OS's such as KolibriOS for its crazy small footprint (1.44MB!) and Genode as a framework for custom kernel and OS userland. I've even made the legendary TempleOS run.

Yet I always have 2 machines. One running FreeBSD, one running OpenBSD. And the reason for that is largely because of it is documentation, and its organization. I appreciate being able to run man and find a useful explanation of how something works, or read the project's documentation without having to piece together instructions from several unrelated sources. I like that the operating system's themselves are treated as coherent projects. Kernels, userlands, configurations, and documentation are each developed with an awareness of one another.

But I think I enjoy them so much, because they have clear direction. FreeBSD does not need to become OpenBSD, nor does NetBSD need to become FreeBSD. Each project benefits from the existence of the others, and each offers something worth studying.

I am not a BSD zealot, contrary to what you get from this article. I do not believe that BSD is the best for every use case, and I certainly do not expect anyone to abandon their preferred operating system in favor of it. So what is the point of all this typing them...?

Well to convert you of course!

No-no, that's not it. While I admire the engineering, the history, and the willingness of these projects to maintain their respective directions over decades of technological change, I understand the idea of preference and usefulness. OpenBSD will never run Steam, FreeBSD will never be on at the bleeding edge of WiFi, and NetBSD will forever look to the past for hardware.

share
comments

Comments

No comments yet. Start the conversation.

No account needed. The first time you use a username it is reserved for this browser, so nobody else can post as you.