You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@zookeeper.apache.org by "Hadoop QA (JIRA)" <ji...@apache.org> on 2018/09/11 01:53:00 UTC

[jira] [Commented] (ZOOKEEPER-2847) Cannot bind to client port when reconfig based on old static config

    [ https://issues.apache.org/jira/browse/ZOOKEEPER-2847?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16610005#comment-16610005 ] 

Hadoop QA commented on ZOOKEEPER-2847:
--------------------------------------

-1 overall.  GitHub Pull Request  Build
      

    +1 @author.  The patch does not contain any @author tags.

    +1 tests included.  The patch appears to include 3 new or modified tests.

    +1 javadoc.  The javadoc tool did not generate any warning messages.

    +1 javac.  The applied patch does not increase the total number of javac compiler warnings.

    +1 findbugs.  The patch does not introduce any new Findbugs (version 3.0.1) warnings.

    +1 release audit.  The applied patch does not increase the total number of release audit warnings.

    -1 core tests.  The patch failed core unit tests.

    +1 contrib tests.  The patch passed contrib unit tests.

Test results: https://builds.apache.org/job/PreCommit-ZOOKEEPER-github-pr-build/2150//testReport/
Findbugs warnings: https://builds.apache.org/job/PreCommit-ZOOKEEPER-github-pr-build/2150//artifact/trunk/build/test/findbugs/newPatchFindbugsWarnings.html
Console output: https://builds.apache.org/job/PreCommit-ZOOKEEPER-github-pr-build/2150//console

This message is automatically generated.

> Cannot bind to client port when reconfig based on old static config
> -------------------------------------------------------------------
>
>                 Key: ZOOKEEPER-2847
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-2847
>             Project: ZooKeeper
>          Issue Type: Bug
>          Components: server
>    Affects Versions: 3.5.3, 3.6.0
>            Reporter: Fangmin Lv
>            Priority: Major
>              Labels: pull-request-available
>          Time Spent: 10m
>  Remaining Estimate: 0h
>
> When started the ensemble with old static config that the server string doesn't have client port, dynamically remove and add the same server from the ensemble will cause that server cannot bind to client port, and the ZooKeeper server cannot serve client requests anymore.
> From the code, we'll set the clientAddr to null when start up with old static config, and dynamic config forces to have <client port> part, which will trigger the following rebind code in QuorumPeer#processReconfig, and cause the address already in used issue.
>     public boolean processReconfig(QuorumVerifier qv, Long suggestedLeaderId, Long zxid, boolean restartLE) {
>         ...
>         if (myNewQS != null && myNewQS.clientAddr != null
>                 && !myNewQS.clientAddr.equals(oldClientAddr)) {
>             cnxnFactory.reconfigure(myNewQS.clientAddr);
>             updateThreadName();
>         }
>         ...
>     }



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)