diff options
Diffstat (limited to 'xlators/nfs/server/src/nfs.c')
| -rw-r--r-- | xlators/nfs/server/src/nfs.c | 17 | 
1 files changed, 17 insertions, 0 deletions
diff --git a/xlators/nfs/server/src/nfs.c b/xlators/nfs/server/src/nfs.c index 8b4bc75ea00..47b9309db43 100644 --- a/xlators/nfs/server/src/nfs.c +++ b/xlators/nfs/server/src/nfs.c @@ -1054,6 +1054,9 @@ nfs_init_state (xlator_t *this)                          goto free_foppool;                  }          } + +        GF_OPTION_INIT ("nfs.rdirplus", nfs->rdirplus, bool, free_foppool); +  	GF_OPTION_INIT (OPT_SERVER_RPC_STATD, nfs->rpc_statd, path, free_foppool);  	GF_OPTION_INIT (OPT_SERVER_RPC_STATD_PIDFILE, nfs->rpc_statd_pid_file, path, free_foppool); @@ -1266,6 +1269,14 @@ nfs_reconfigure_state (xlator_t *this, dict_t *options)                          OPT_SERVER_GID_CACHE_TIMEOUT, optuint32);          } +        GF_OPTION_RECONF ("nfs.rdirplus", optbool, +                                          options, bool, out); +        if (nfs->rdirplus != optbool) { +                nfs->rdirplus = optbool; +                gf_msg (GF_NFS, GF_LOG_INFO, 0, NFS_MSG_RECONFIG_VALUE, +                        "Reconfigured nfs.rdirplus with value %d", optbool); +        } +          /* reconfig nfs.dynamic-volumes */          ret = dict_get_str_boolean (options, "nfs.dynamic-volumes",                                               GF_NFS_DVM_OFF); @@ -2061,6 +2072,12 @@ struct volume_options options[] = {            .description = "Sets the TTL of an entry in the auth cache. Value is "                           "in seconds."          }, +        { .key  = {"nfs.rdirplus"}, +          .type = GF_OPTION_TYPE_BOOL, +          .default_value = "on", +          .description = "When this option is set to off NFS falls back to " +                         "standard readdir instead of readdirp" +        },          { .key  = {NULL} },  };  | 
