change connect glusterd addr filter localhost (#4442)#4443
Open
shenwen2012 wants to merge 2 commits intogluster:develfrom
Open
change connect glusterd addr filter localhost (#4442)#4443shenwen2012 wants to merge 2 commits intogluster:develfrom
shenwen2012 wants to merge 2 commits intogluster:develfrom
Conversation
when use localhost(127.0.0.1) addr mount a volume, if glusterd is down ,client not change connect other glusterd server , because socket bind 127.0.0.1 can not connect other node addr success . so change volume server round-roubin filter 127.0.0.1 Fixes: gluster#4442 Signed-off-by: tanshiping <tanshiping44@gmail.com>
…lusterd-server change connect glusterd addr filter localhost (gluster#4442)
Collaborator
|
Can one of the admins verify this patch? |
2 similar comments
Collaborator
|
Can one of the admins verify this patch? |
Collaborator
|
Can one of the admins verify this patch? |
Collaborator
|
CLANG-FORMAT FAILURE: index b34710065..ba7de91a9 100644
--- a/glusterfsd/src/glusterfsd-mgmt.c
+++ b/glusterfsd/src/glusterfsd-mgmt.c
@@ -2830,9 +2830,11 @@ mgmt_rpc_notify(struct rpc_clnt *rpc, void *mydata, rpc_clnt_event_t event,
"Exhausted all volfile servers, Retrying from again!");
}
} else {
- char *local_str="127.0.0.1";
- if (strncmp(local_str,rpc_trans->myinfo.identifier,strlen(local_str)) != 0) {
- server = list_entry(server->list.next, typeof(*server), list);
+ char *local_str = "127.0.0.1";
+ if (strncmp(local_str, rpc_trans->myinfo.identifier,
+ strlen(local_str)) != 0) {
+ server = list_entry(server->list.next, typeof(*server),
+ list);
}
}
ctx->cmd_args.curr_server = server; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
when use localhost(127.0.0.1) addr mount a volume, if glusterd is down ,client not change connect other glusterd server , because socket bind 127.0.0.1 can not connect other node addr success . so change volume server round-roubin filter 127.0.0.1
Fixes: #4442