summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard Wareing <rwareing@fb.com>2015-07-11 01:13:44 -0700
committerKevin Vigor <kvigor@fb.com>2017-03-06 19:12:02 -0500
commit4e5e8f4d9b3e8c0a7364a1006972857062ac0b90 (patch)
tree4b7b94f9871e85ef9d70346ffa13c89cb949aa17
parent693ef7119dd3d78c55b83e6026a94461f1aae6b4 (diff)
HotFix: Disables rmtab functionality (v3.6.3)
Summary: - This is a new feature for 3.6 to provide "show mount" functionality to clients. It unfortunately is not scalable for large numbers of mounts due to the various activities done in the epoll loop causing IO stalls and very slow mount performance for NFS clients, especially nfs CLI clients. Test Plan: - Built RCs, deployed to gfsinstabu.frc3c08 Reviewers: dph, sshreyas Reviewed By: sshreyas Subscribers: storage@ FB-commit-id: bf30931 Change-Id: I7d0e110be95d82e3d8be7d2ac7576386471c1a47 Signed-off-by: Kevin Vigor <kvigor@fb.com> Reviewed-on: https://review.gluster.org/16859 CentOS-regression: Gluster Build System <jenkins@build.gluster.org> NetBSD-regression: NetBSD Build System <jenkins@build.gluster.org> Smoke: Gluster Build System <jenkins@build.gluster.org> Reviewed-by: Shreyas Siravara <sshreyas@fb.com>
-rw-r--r--xlators/nfs/server/src/mount3.c15
1 files changed, 13 insertions, 2 deletions
diff --git a/xlators/nfs/server/src/mount3.c b/xlators/nfs/server/src/mount3.c
index 57d1874c79a..d6b07ed801c 100644
--- a/xlators/nfs/server/src/mount3.c
+++ b/xlators/nfs/server/src/mount3.c
@@ -36,6 +36,7 @@
#include <sys/socket.h>
#include <sys/uio.h>
+#define SUPPORT_RMTAB 0
/* This macro will assist in freeing up entire link list
* of host_auth_spec structure.
@@ -444,7 +445,7 @@ mount_open_rmtab (const char *rmtab, gf_store_handle_t **sh)
return _gf_true;
}
-
+#if SUPPORT_RMTAB
/* Read the rmtab into a clean ms->mountlist.
*/
static void
@@ -472,6 +473,7 @@ mount_read_rmtab (struct mount3_state *ms)
out:
gf_store_handle_destroy (sh);
}
+#endif
/* Write the ms->mountlist to the rmtab.
*
@@ -597,7 +599,9 @@ mnt3svc_update_mountlist (struct mount3_state *ms, rpcsvc_request_t *req,
nfs = (struct nfs_state *)ms->nfsx->private;
+#if SUPPORT_RMTAB
update_rmtab = mount_open_rmtab (nfs->rmtab, &sh);
+#endif
strncpy (me->exname, expname, MNTPATHLEN);
/* Sometimes we don't care about the full path
@@ -791,7 +795,9 @@ mnt3svc_lookup_mount_cbk (call_frame_t *frame, void *cookie,
}
snprintf (path, PATH_MAX, "/%s", mntxl->name);
+#if SUPPORT_RMTAB
mnt3svc_update_mountlist (ms, req, path, NULL);
+#endif
GF_FREE (path);
if (gf_nfs_dvm_off (nfs_state (ms->nfsx))) {
fh = nfs3_fh_build_indexed_root_fh (ms->nfsx->children, mntxl);
@@ -2265,9 +2271,10 @@ __build_mountlist (struct mount3_state *ms, int *count)
if ((!ms) || (!count))
return NULL;
+#if SUPPORT_RMTAB
/* read rmtab, other peers might have updated it */
mount_read_rmtab(ms);
-
+#endif
*count = 0;
gf_msg_debug (GF_MNT, 0, "Building mount list:");
list_for_each_entry (me, &ms->mountlist, mlist) {
@@ -2399,7 +2406,9 @@ mnt3svc_umount (struct mount3_state *ms, char *dirpath, char *hostname)
nfs = (struct nfs_state *)ms->nfsx->private;
+#if SUPPORT_RMTAB
update_rmtab = mount_open_rmtab (nfs->rmtab, &sh);
+#endif
if (update_rmtab) {
ret = gf_store_lock (sh);
if (ret)
@@ -3026,7 +3035,9 @@ mount3udp_add_mountlist (xlator_t *nfsx, char *host, char *export)
LOCK (&ms->mountlock);
{
list_add_tail (&me->mlist, &ms->mountlist);
+#if SUPPORT_RMTAB
mount_rewrite_rmtab(ms, NULL);
+#endif
}
UNLOCK (&ms->mountlock);
return 0;