Multiple entries in ZFS "sharenfs" property?
Willem Jan Withagen
wjw at digiware.nl
Mon Aug 3 12:23:02 UTC 2015
On 3-8-2015 14:06, Lev Serebryakov wrote:
> On 02.08.2015 23:56, Willem Jan Withagen wrote:
>
>> Nope, that doesn't work, as far as I can tell. You'd have to revert
>> to editting /etc/exports.
> Yep, I know.
>
>> Or hack on 'zfs set sharenfs' to generate multiple lines, in some
>> sort of format. Like making ';' a line separator, and then prefix
>> each part with the volume we are modifying.
>
>> Place to give it a go are in:
>> cddl/compat/opensolaris/misc/fsshare.c:213 if (share) {
>> fprintf(newfd, "%s\t%s\n", mountpoint, translate_opts(shareopts));
>> } And there split the shareopts on the split char (eg. ';') in
>> several shareopts and then loop over them. Disadvantage is that the
>> max length op the options is: MAXPATHLEN. So you can easily run out
>> of space if you have many exports to do.
> Here is PR with patch about this, from 2012 :(
'mmmm
PR URL is missing, I looked but did not find anything.
Just send you some code this morning....
Don't you have commit bits???
So you could checkin a fix if you wanted?
Usually if I have a patch, I just ask (and reask) a previous committer
of that file if he/she wants to do the honnors. Mostly things go fast
from there.
--WjW
More information about the freebsd-fs
mailing list