summaryrefslogtreecommitdiffstats
path: root/cli/src
diff options
context:
space:
mode:
authorAvra Sengupta <asengupt@redhat.com>2013-07-25 14:58:46 +0530
committerVijay Bellur <vbellur@redhat.com>2013-07-29 04:42:40 -0700
commit355ff31dff9713319a1d2663e5f8d3d386c1b938 (patch)
tree25bb85af8cdcf50d0371f0c4a84c740dfd41340b /cli/src
parentebbe623fe44dddc9318067698bf3796035265997 (diff)
glusterd: Fixing create force issues while it returned true everytime.
Now geo-rep create force will return true if a node is down, and log an appropriate message. It will also return true with an appropriate log message if the slave verification fails. However it will not return true if the config file is deleted, ot corrupted, so as not to get the state_file's path. It will also fail if the slave url is invalid. If the push-pem option is given and /var/lib/glusterd/geo-replication/common_secret.pem.pub is not present, then also the create force command will fail. Change-Id: Ie7532a0884ddf9c3008bd30832d171d5b53b540e BUG: 988314 Signed-off-by: Avra Sengupta <asengupt@redhat.com> Reviewed-on: http://review.gluster.org/5405 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amarts@redhat.com> Reviewed-by: Vijay Bellur <vbellur@redhat.com>
Diffstat (limited to 'cli/src')
-rw-r--r--cli/src/cli-rpc-ops.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/cli/src/cli-rpc-ops.c b/cli/src/cli-rpc-ops.c
index 959addf1a0c..0205b4cc618 100644
--- a/cli/src/cli-rpc-ops.c
+++ b/cli/src/cli-rpc-ops.c
@@ -4302,8 +4302,6 @@ gf_cli_gsync_set_cbk (struct rpc_req *req, struct iovec *iov,
char *slave = NULL;
int32_t type = 0;
call_frame_t *frame = NULL;
- gf_boolean_t is_force = _gf_false;
-
if (req->rpc_status == -1) {
ret = -1;
@@ -4340,9 +4338,7 @@ gf_cli_gsync_set_cbk (struct rpc_req *req, struct iovec *iov,
goto out;
}
- is_force = dict_get_str_boolean (dict, "force", _gf_false);
-
- if (rsp.op_ret && !is_force) {
+ if (rsp.op_ret) {
cli_err ("%s", rsp.op_errstr ? rsp.op_errstr :
GEOREP" command unsuccessful");
ret = rsp.op_ret;