glusterd: send the duplicate brick info to the cli
Signed-off-by: Raghavendra Bhat <raghavendrabhat@gluster.com> Signed-off-by: Anand Avati <avati@gluster.com> BUG: 2803 ([glusterfs-3.2.0qa14]: volume create succeeds even though there is a volume with an export directory in the path of current volume) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=2803
This commit is contained in:
parent
276c0cecad
commit
4ba7635f4d
@ -1001,9 +1001,8 @@ glusterd_handle_create_volume (rpcsvc_request_t *req)
|
||||
if (!ret) {
|
||||
ret = -1;
|
||||
snprintf (err_str, sizeof (err_str), "Brick: %s:%s, %s"
|
||||
" in the arguments mean the same",
|
||||
tmpbrkinfo->hostname, tmpbrkinfo->path,
|
||||
brick);
|
||||
" one of the arguments contain the other",
|
||||
tmpbrkinfo->hostname, tmpbrkinfo->path, brick);
|
||||
goto out;
|
||||
}
|
||||
list_add_tail (&brickinfo->brick_list, &tmpvolinfo.bricks);
|
||||
@ -1423,9 +1422,8 @@ brick_val:
|
||||
if (!ret) {
|
||||
ret = -1;
|
||||
snprintf (err_str, sizeof (err_str), "Brick: %s:%s, %s"
|
||||
" in the arguments mean the same",
|
||||
tmpbrkinfo->hostname, tmpbrkinfo->path,
|
||||
brick);
|
||||
" one of the arguments contain the other",
|
||||
tmpbrkinfo->hostname, tmpbrkinfo->path, brick);
|
||||
goto out;
|
||||
}
|
||||
list_add_tail (&brickinfo->brick_list, &tmpvolinfo.bricks);
|
||||
|
@ -739,6 +739,7 @@ glusterd_volume_brickinfo_get (uuid_t uuid, char *hostname, char *path,
|
||||
"given path %s lies"
|
||||
" within %s", path,
|
||||
brickiter->path);
|
||||
*brickinfo = brickiter;
|
||||
break;
|
||||
}
|
||||
} else
|
||||
@ -748,6 +749,7 @@ glusterd_volume_brickinfo_get (uuid_t uuid, char *hostname, char *path,
|
||||
" %s", brickiter->path,
|
||||
path);
|
||||
ret = 0;
|
||||
*brickinfo = brickiter;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user