what is zookeeper port and its usage?

前端 未结 1 1558
借酒劲吻你
借酒劲吻你 2020-12-08 20:03

I am quite new for zookeeper port through which I am coming across from past few days.
I introduced with zookeeper port keyword at two occasion:

1条回答
  •  独厮守ぢ
    2020-12-08 20:41

    Zookeeper is used in distributed applications mainly for configuration management and high availability operations. Zookeeper does this by a Master-Slave architecture. Neo4j and VoltDb might be using zookeeper for this purpose

    Coming to the ports understanding : suppose u have 3 servers for zookeepers ... You need to mention in configuration as

    clientPort=2181
    server.1=zookeeper1:2888:3888
    server.2=zookeeper2:2888:3888
    server.3=zookeeper3:2888:3888
    

    Out of these one server will be the master and rest all will be slaves.If any server goes OFF then zookeeper elects leader automatically .

    Servers listen on three ports: 2181 for client connections; 2888 for follower connections, if they are the leader; and 3888 for other server connections during the leader election phase .

    0 讨论(0)
提交回复
热议问题