summaryrefslogtreecommitdiffstats
path: root/xlators/mgmt/glusterd/src/glusterd-rebalance.c
diff options
context:
space:
mode:
Diffstat (limited to 'xlators/mgmt/glusterd/src/glusterd-rebalance.c')
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-rebalance.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-rebalance.c b/xlators/mgmt/glusterd/src/glusterd-rebalance.c
index 84d9210a105..c14bcd156b4 100644
--- a/xlators/mgmt/glusterd/src/glusterd-rebalance.c
+++ b/xlators/mgmt/glusterd/src/glusterd-rebalance.c
@@ -421,6 +421,15 @@ glusterd_rebalance_cmd_validate (int cmd, char *volname,
goto out;
}
+ ret = glusterd_disallow_op_for_tier (*volinfo, GD_OP_REBALANCE, cmd);
+ if (ret) {
+ gf_log ("glusterd", GF_LOG_ERROR, "Received rebalance command "
+ "on Tier volume %s", volname);
+ snprintf (op_errstr, len, "Rebalance operations are not "
+ "supported on a tiered volume");
+ goto out;
+ }
+
ret = 0;
out: