Overlay file systems are used by container systems like docker for saving disk space.

The “layers” we see as docker runs through every command of Dockerfile is result of docker building another lower directory (possibly reusable) to the cascaded overlay file system used for a container.

Since container systems like docker use overlays, re-building an existing image with different tag doesn’t go through the build steps like installing packages again! :)

Excalidraw Diagram →

overlay-fs.excalidraw

overlay-fs.png

Show me some code/commands!

References