summaryrefslogtreecommitdiffstats
path: root/xlators/mgmt/glusterd/src/glusterd.c
diff options
context:
space:
mode:
authorshishir gowda <shishirng@gluster.com>2011-05-27 03:37:14 +0000
committerAnand Avati <avati@gluster.com>2011-05-31 22:52:26 -0700
commita3bd6682c3ca9e083ed0de8da8ef42bbaa86416f (patch)
treed5a65c6d9a9cc8062102307b0a42f34b41bde99b /xlators/mgmt/glusterd/src/glusterd.c
parentef39bf9d233b39ea616e62b52ee6de69d06f9c8d (diff)
glusterd: add upgrade/downgrade xlator options
If started with upgrade-option, the current behavior is to recreate brick volfiles, as from 3.2 marker xlator is default. downgrade option is not functionally supported. Signed-off-by: shishir gowda <shishirng@gluster.com> Signed-off-by: Anand Avati <avati@gluster.com> BUG: 2904 (glusterd should have upgrade/downgrade xlator options) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=2904
Diffstat (limited to 'xlators/mgmt/glusterd/src/glusterd.c')
-rw-r--r--xlators/mgmt/glusterd/src/glusterd.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd.c b/xlators/mgmt/glusterd/src/glusterd.c
index 670cda00f4e..53f1460bfba 100644
--- a/xlators/mgmt/glusterd/src/glusterd.c
+++ b/xlators/mgmt/glusterd/src/glusterd.c
@@ -714,6 +714,10 @@ init (xlator_t *this)
glusterd_op_sm_init ();
glusterd_opinfo_init ();
+ ret = glusterd_handle_upgrade_downgrade (this->options, conf);
+ if (ret)
+ goto out;
+
glusterd_restart_bricks (conf);
ret = glusterd_restart_gsyncds (conf);
if (ret)
@@ -818,6 +822,12 @@ struct volume_options options[] = {
{ .key = {"rpc-auth-allow-insecure"},
.type = GF_OPTION_TYPE_BOOL,
},
+ { .key = {"upgrade"},
+ .type = GF_OPTION_TYPE_BOOL,
+ },
+ { .key = {"downgrade"},
+ .type = GF_OPTION_TYPE_BOOL,
+ },
{ .key = {NULL} },
};