diff options
author | Kaushik BV <kaushikbv@gluster.com> | 2010-10-03 02:41:29 +0000 |
---|---|---|
committer | Vijay Bellur <vijay@dev.gluster.com> | 2010-10-03 03:05:03 -0700 |
commit | 609a89ceace25a0a81d0a9cafde3a4d1afd1b916 (patch) | |
tree | 0205b67be6e1e2f33e9a0c9c1ca4ea0737ebff05 /xlators/protocol/server | |
parent | 53b8c7470f9e40c60c5eebd1fbad5c6d274f7ee5 (diff) |
mgmt/Glusterd: new command volume reset <volname>, volume set enhancementsv3.1.0qa39
- Write the reconfigured options in 'info' file to make it persistant
- Implementation of volume set <volname> history
- Implementation of volume reset <volname>
Signed-off-by: Kaushik BV <kaushikbv@gluster.com>
Signed-off-by: Vijay Bellur <vijay@dev.gluster.com>
BUG: 1159 ()
URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=1159
Diffstat (limited to 'xlators/protocol/server')
-rw-r--r-- | xlators/protocol/server/src/server.c | 20 |
1 files changed, 18 insertions, 2 deletions
diff --git a/xlators/protocol/server/src/server.c b/xlators/protocol/server/src/server.c index 719ffdc31cc..26848001171 100644 --- a/xlators/protocol/server/src/server.c +++ b/xlators/protocol/server/src/server.c @@ -481,16 +481,32 @@ reconfigure (xlator_t *this, dict_t *options) gf_log (this->name, GF_LOG_WARNING, "'trace' takes on only boolean values. " "Neglecting option"); - return -1; + ret = -1; + goto out; } conf->trace = trace; gf_log (this->name, GF_LOG_TRACE, "Reconfigured trace" " to %d", conf->trace); } + if (!conf->auth_modules) + conf->auth_modules = dict_new (); - return 0; + dict_foreach (options, get_auth_types, conf->auth_modules); + ret = validate_auth_options (this, options); + if (ret == -1) { + /* logging already done in validate_auth_options function. */ + goto out; + } + + ret = gf_auth_init (this, conf->auth_modules); + if (ret) { + dict_unref (conf->auth_modules); + goto out; + } +out: + return ret; } int |