Skip to main content

is_ephemeral_host_seed_mount

Function is_ephemeral_host_seed_mount 

Source
pub fn is_ephemeral_host_seed_mount(line: &[u8]) -> bool
Expand description

True for one ephemeral host FUSE seed mount row in /proc/<pid>/mountinfo grammar: filesystem type fuse.squashfuse_ll and a mount point whose last path component is a host seed name, <hex>-seed-<seed>-ns-<digits>, where <seed> is a non-empty run of ASCII letters, digits, _ and -.

The host’s squashfuse infrastructure creates these mounts, normally at /mnt/xarfuse/uid-<uid>/<seed name>, either one per host process (seed nspid<digits>_cgpid<digits>) or one per named host tool (for example seed chef, fb-pcie-error-log or devserver-cleanup_hg_cache). Those rows are other processes’ runtime state imported into the guest namespace by shared mount propagation: they are not created by Hermit, by the guest session, or by any ancestor the guest can name, and they appear, disappear and are remounted under new mount IDs asynchronously as unrelated host processes and tool runs start and stop (named-tool seeds were observed living four to five seconds, and the chef seed was remounted under a new mount ID). Passing their membership through made /proc/<pid>/mountinfo (and the length of every read of it) a host-timing observation: in the procfs-sanitized-paths divergence, one seed row changed the tail read length between two strict runs.

This is a chosen determinism fidelity trade. Seed rows are real mounts in the guest namespace (imported by shared propagation and traversable), and Linux omits no real mount from mountinfo. Hermit nevertheless excludes the class, long-lived named seeds included, because its membership is owned by unrelated host processes and changes asynchronously, the same scope choice DETERMINISM_ARGUMENT.md makes for other changing host inputs. The class is decided by the seed name, not by the directory it is shown under, so other SquashFUSE mounts (for example a long-lived /mnt/xarfuse/stable-release) stay visible, and a guest whose root makes the displayed path /xarfuse/uid-<uid>/<seed> still excludes the same rows the launch-time capture excluded. Other host mount churn, such as logind’s /run/user/<uid> tmpfs mounts, is not in this class and stays visible.

Only mountinfo rows are classified. /proc/<pid>/mounts is passed through unchanged: https://github.com/rrnewton/hermit/issues/3719.