]> granicus.if.org Git - zfs/commitdiff
Remove unconditional sharetab update
authorBrian Behlendorf <behlendorf1@llnl.gov>
Tue, 7 Jan 2014 17:31:38 +0000 (09:31 -0800)
committerBrian Behlendorf <behlendorf1@llnl.gov>
Tue, 7 Jan 2014 17:48:09 +0000 (09:48 -0800)
Removes the unconditional sharetab update when running any zfs
command. This means the sharetab might become out of date if
users are manually adding/removing shares with exportfs.  But
we shouldn't punish all callers to zfs in order to handle that
unlikely case. In the unlikely event we observe issues because
of this it can always be added back to just the share/unshare
call paths where we need an up to date sharetab.

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Turbo Fredriksson <turbo@bayour.com>
Signed-off-by: Chris Dunlop <chris@onthe.net.au>
Issue #845

lib/libshare/libshare.c

index 6625a1b0cd6fd982e62ff6d0170de4febfe2baed..ea59dcdbc60eb82088b3f62a0e2519304c55d7c0 100644 (file)
@@ -105,14 +105,6 @@ libshare_init(void)
 {
        libshare_nfs_init();
        libshare_smb_init();
-
-       /*
-        * This bit causes /etc/dfs/sharetab to be updated before libzfs gets a
-        * chance to read that file; this is necessary because the sharetab file
-        * might be out of sync with the NFS kernel exports (e.g. due to reboots
-        * or users manually removing shares)
-        */
-       sa_fini(sa_init(0));
 }
 
 static void