USC2025+SE2 — Backups for the people!
We have started deploying a new backup server, levering the zfs
filesystem together with FreeBSD jails
🤓
We have started deploying a new backup server, levering the zfs
filesystem together with FreeBSD jails
🤓
So, we’ve seen how to create a native jail using FreeBSD’s toolset, and we’ve fine-tuned a few of its settings, including mounting select directories from the host into the jail.
Is that really enough though? 🙃
We want zfs
inside our jail, period!
Since we use a dedicated zfs dataset per jail, isn’t that enough? Well, dataset management (and anything disk-related) is handled on the host.
Practically speaking, this means that the root
user inside the jail cannot
alter dataset properties, nor create new ones.
So, we’ve seen how to create a native jail using FreeBSD’s toolset. Meaning we have a brand-new system to configure!
Some jail-related specificities:
vnet
jails allows for virtualizing the entire network stack;Let’s copy /etc/resolv.conf
& /etc/localtime
from the host into the jail,
so that it can issue DNS requests, and most importantly be on time ;)
FreeBSD jails were introduced in June 2000. They were the first open-source solution for lightweight virtualization, and proved to be foundational to the container revolution that took off later on, preceding the emergence of linux-vserver in October 2001, or LXC containers at the end of 2008.
The jail technology inspired Sun’s engineers, who refined and further elaborated on its concepts through the development of Solaris Zones in 2004, as this talk by Bryan Cantrill amusingly evokes.