I'm trying to research what the best approach would be to replicate the SquashFS functionality on FreeBSD. I want to be able to make a create a filesystem, install whatever files, assets, and programs that I need on it, image and compress it, and finally ship it to another machine to mount as r/o. Preferably, I'd like the underlying filsystem to be ZFS, but that's not a hard requirement.
I've considered three options:
I've considered three options:
- mdconfig() with GEOM_UZIP() - Looks like I can use ZFS, but is that the 'best' approach?
- ZFS with `file` vdev - man page says it's "strongly discouraged", not sure how compression works with that.
- ZFS snapshots that I can send and receive between machines. It's unclear to me how I would mount them on the fly.