jails Can jail.conf use a ZFS pool with jailed=on

In my jail.conf, I use path = /data/foo and it works great. Is there a way to set 'jailed=on' for a ZFS pool and start a jail?

When I set 'zfs set jailed=on ztank/data/foo' the pool is unmounted - and then I can't start the jail. Is there a way to tell jail to run with a ZFS pool instead of a path?

Also, not sure if this is related, but I am trying to get syncoid in a jail, but "permission is denied: hold". And I can't seem to delegate in a jail...

zfs allow -u zfsbackup send,snapshot,hold ztank/data/foo
 
just mount the zfs dataset to a path
And use that path for the jail.
Or do you want to mount a zfs dataset inside a jail to use it by the jail?
 
You cannot attach a jailed dataset's children to another jail.
You can also not attach the root file system of the jail or any
dataset which needs to be mounted before the zfs rc script is run
inside the jail, as it would be attached unmounted until it is
mounted from the rc script inside the jail.
zfs-jail(8)
 
Back
Top