Skip to content

Fix storage and fstab basejail bugs - #772

Merged
gronke merged 4 commits into
mainfrom
storage-fstab
Jul 8, 2026
Merged

Fix storage and fstab basejail bugs#772
gronke merged 4 commits into
mainfrom
storage-fstab

Conversation

@gronke

@gronke gronke commented Jul 8, 2026

Copy link
Copy Markdown
Member
  • The procfs and linprocfs mount commands are built with proper arguments instead of concatenating to "mount-t" and "procfsproc", a missing config key skips the mount instead of raising, and MountFailed reports the mountpoint when the mount command fails.
  • update_release sets the release attribute that Fstab declares instead of assigning to the jails read-only release property.
  • Parsing a jail fstab skips the auto-created basejail destinations again: the storage backend class is checked with issubclass and queried through _get_basejail_mounts, and the mutable default argument is no longer mutated.

gronke added 4 commits July 8, 2026 06:42
Missing commas concatenated the arguments to mount-t and procfsproc, so mounting procfs or linprocfs into a jail could never have worked.
A missing config key now skips the mount instead of raising, MountFailed reports the mountpoint instead of the filesystem type when the mount command fails, and linprocfs no longer requires mount_procfs to be enabled.
update_release assigned to the jails read-only release property and crashed with an AttributeError.
The release attribute that the class declares was intended.
The check used isinstance on the storage backend class, which is always False, and the intended list of basejail mounts was read from an attribute that does not exist.
The backend class is now checked with issubclass and queried through _get_basejail_mounts, and the skip list is rebound so that the mutable default argument stays unchanged.
Nullfs mounts sourced from ZFS snapshot directories do not appear in the getfsstat output on FreeBSD 13, so the test for starting a basejail read as if no mounts existed and was marked expected-to-fail.
Enabling basejail on an existing jail works; the test now proves each base directory mount through statfs, a read-only write probe and a clean unmount after stopping the jail.
@gronke gronke changed the title Storage fstab Fix storage and fstab basejail bugs Jul 8, 2026
@gronke
gronke merged commit 641bde0 into main Jul 8, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant