Re: ZFS delegation- zfs send| zfs recv fails for not being able to unmount dataset as regular user
Date: Sat, 07 Aug 2021 07:44:51 UTC
On Thu, Aug 5, 2021 at 11:49 PM parv/freebsd wrote: > How do I get around the the issue of normal user being unable to unmount > the dataset ... > > # zfs send -R -v send-test/original@to-copy | zfs recv -F -d -v -s send-test-copy > full send of send-test/original@to-copy estimated size is 51.1K > total estimated size is 51.1K > cannot unmount '/send-test-copy/original': permission denied > warning: cannot send 'send-test/original@to-copy': Broken pipe > > ... so that the transfer would succeed? > > After posting this, a thought had occurred to me that I might need to set some MIB to allow non-root user to perform (un)mount. Found the reason (vfs.usermount MIB was 0) & the solution (set the MIB to 1) myself. zfs-allow(8) manual page need to have a pointer to the above MIB. - parv > I am testing ZFS delegation on FreeBSD 13, with > > ... > # zfs allow send-test-copy > ---- Permissions on send-test-copy ----------------------------------- > Local+Descendent permissions: > user parv create,destroy,diff,hold,mount,promote,receive,release,send,snapshot > > # ll /send-test-copy > total 10 > drwxr-xr-x 3 parv parv uarch 3 20210805.1741 ./ > drwxr-xr-x 25 root wheel uarch 31 20210805.1715 ../ > drwxr-xr-x 2 parv parv uarch 2 20210805.1741 original/ > > --