summaryrefslogtreecommitdiffstats
path: root/xlators/mgmt/glusterd/src/glusterd-op-sm.c
diff options
context:
space:
mode:
Diffstat (limited to 'xlators/mgmt/glusterd/src/glusterd-op-sm.c')
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-op-sm.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-op-sm.c b/xlators/mgmt/glusterd/src/glusterd-op-sm.c
index 52ab039b9ec..45fcebffea1 100644
--- a/xlators/mgmt/glusterd/src/glusterd-op-sm.c
+++ b/xlators/mgmt/glusterd/src/glusterd-op-sm.c
@@ -3457,6 +3457,8 @@ out:
return required;
}
+/* This function shouldn't be used when the quorum validation needs to happen
+ * on the non-global peer list */
static int
glusterd_op_validate_quorum (xlator_t *this, glusterd_op_t op,
dict_t *dict, char **op_errstr)
@@ -3466,7 +3468,6 @@ glusterd_op_validate_quorum (xlator_t *this, glusterd_op_t op,
glusterd_volinfo_t *volinfo = NULL;
char *errstr = NULL;
-
errstr = "Quorum not met. Volume operation not allowed.";
if (!glusterd_is_op_quorum_validation_required (this, op, dict))
goto out;
@@ -3483,7 +3484,10 @@ glusterd_op_validate_quorum (xlator_t *this, glusterd_op_t op,
goto out;
}
- if (does_gd_meet_server_quorum (this, _gf_false)) {
+ /* Passing NULL implies quorum calculation will happen on global peer
+ * list */
+ if (does_gd_meet_server_quorum (this, NULL,
+ _gf_false)) {
ret = 0;
goto out;
}