[Bug 221064] zfs should not be able to shadow mount on root directory from userspace

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Sat Jul 29 08:34:39 UTC 2017


--- Comment #6 from David NewHamlet <wheelcomplex at gmail.com> ---
(In reply to Poul-Henning Kamp from comment #5)

kenv vfs.root.mountfrom="second rootfs(zfs:newtank/rootfs)" and reboot -r will
trigger kernel to stop all running proccess(include first init) and umount
first rootfs. After that, kernel will try to mount second filesystem as rootfs
and execute init from second rootfs. 

This might be a better way to handle your case.

This is a useful feature similar to switch_root in Linux world which is very
common in embedded linux.

It was introduced by trasz on Sep 18 2015, 5:35 PM.


You are receiving this mail because:
You are the assignee for the bug.

More information about the freebsd-fs mailing list