Container theory: namespacing
If you’re wondering how some of this container magic works underneath, or just worried that you’ll have to troubleshoot a container environment under pressure one day, it’s useful to familiarize yourself with the concept of namespacing. You can skip this section if you’re not interested in how the container abstraction is built on Linux.
Namespacing is an overloaded term, used to mean different things in different technological niches. In the context of Linux containers, the idea of namespacing is best explained via chroot
(change root). chroot
is an old utility for Unix and Unix-like operating systems that allows a user to change the root (the /
path) of the filesystem.
The usage of this tool is really quite simple: chroot /some/path
will set whatever is in /some/path
to be the new /
. In addition to allowing OS installers to change into the system that is currently being installed to run commands, it also allows for...