Show HN: Dualayer Hierarchy Standard (DHS) – Zero-FHS Layout for Musl and Glibc
Dualayer Hierarchy Standard (DHS:Repo: https://github.com/Zainium-Dynamics/dualayer-hierarchy-stand... Full Specification (23-page PDF): https://zainiumdynamics.tech/dhs
DHS 1.1 defines a layered filesystem hierarchy for immutable Linux systems where musl and glibc coexist side by side without conflict. Either C library can be primary; the distribution chooses.
Root layout (no /usr, /bin, /sbin, /lib, /lib64, /etc, /var, or /boot at /, not even as symlinks):
/
|-- overlayer/ (the entire OS: all layers)
|-- home/ (user home directories)
|-- root/ (root home)
|-- dev/ (devtmpfs)
|-- proc/ (procfs)
|-- sys/ (sysfs)
|-- run/ (tmpfs; removable media at /run/media/user/label)
`-- tmp/ (temporary files)
Layer structure under /overlayer (composed at boot via OverlayFS with syshub as lower and userland/union as upper): /overlayer/
|-- syshub/ (read-only base OS; boots without userland)
|-- userland/ (installed packages: union/, work/, registry/)
|-- ignition/ (kernels, initramfs, bootloader; read-only)
|-- agents/ (optional AI coding agent instructions/policies)
`-- .syshub-pending/ (staged atomic base upgrade, applied at next boot)
Dual-libc isolation:
musl and glibc each live in their own GNU target-triplet directory (arch-vendor-linux-musl and arch-vendor-linux-gnu) with separate loaders, headers, C++ runtimes, loader configs, and toolchains. Shared directories (/overlayer/syshub/bin, lib, include) belong strictly to the primary libc and search paths never cross, while both read shared system config (passwd, hosts, resolv.conf, zoneinfo) from /overlayer/syshub/etc.FHS compatibility: Foreign packages are adapted at install time (PT_INTERP, RPATH, pkg-config, shebangs). Runtime FHS path lookups use a preload resolver and loader redirection (the known LD_PRELOAD limitation for static/setuid binaries is documented in Chapter 7).
Reference implementation — Zainium OS (https://github.com/Zainium-Dynamics): - Layers: syshub (base), zexlib (userland), zaisys (ignition) - Libc design: Design A (musl primary in base, glibc as a userland package) - Boot & atomic upgrades: quantra-ramfs - Package manager & receipts: zex - Path/loader resolver & toolchain switcher: libsys_resolver.so, sys-resolver - Protected base/ignition paths: elevate, elevate-pam
Looking for honest technical critique on where this layout holds up, where it breaks down, and what edge cases are missing.