Date: Mon, 3 Aug 2015 14:22:46 +0200 From: Willem Jan Withagen <wjw@digiware.nl> To: lev@FreeBSD.org Cc: fs@freebsd.org Subject: Re: Multiple entries in ZFS "sharenfs" property? Message-ID: <55BF5D16.9060705@digiware.nl> In-Reply-To: <55BF5932.2090107@FreeBSD.org> References: <130767529.20150801150343@serebryakov.spb.ru> <55BDF5D2.3090306@digiware.nl> <1941826477.20150802210808@serebryakov.spb.ru> <55BE83FA.1060208@digiware.nl> <55BF5932.2090107@FreeBSD.org>
next in thread | previous in thread | raw e-mail | index | archive | help
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
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?55BF5D16.9060705>