Compiling a Custom Linux Kernel & Adding systemd (Part 2)

In Part 1, we built a minimal Linux system using BusyBox and a prebuilt kernel. You got a shell running inside a container, mounted pseudo-filesystems, and saw the boot sequence from init to prompt. That was the “hello world” of custom Linux. Now we’re doing the real thing. Today we’re going to compile our own kernel from source, configure only the hardware support we actually need, and compress it to under 10MB. Then we’ll rip out that hand-written init script and replace it with systemd — the same init system that runs on virtually every modern Linux distribution. Finally, we’ll get a real service running (OpenSSH) so you can actually log into your custom system remotely. ...

July 7, 2026 · 12 min · Pragmatic Sysadmin

Building Your Own Linux from Scratch (And Testing It in a Container)

If you’ve been administering Linux servers for a while, you’ve probably developed a love-hate relationship with it. You know how to configure services, debug networking issues, and keep systems running. But somewhere deep down, you’ve wondered: what actually holds this thing together? I don’t mean “how does systemd work” (nobody truly knows). I mean: what happens between hitting the power button and seeing a login prompt? Today, we’re going to build our own minimal Linux system from scratch. And because I’m not a sadist, we’ll test it using Docker containers - spin it up in seconds, tear it down just as fast. ...

March 28, 2026 · 6 min · Pragmatic Sysadmin
☕ Like the free content?
One-tap tip on Ko-fi — no signup needed, just PayPal or card.  ·  Support on Ko-fi →  ·  Privacy