只启动一个zookeeper配置 server1只需要配置一个

[root@wx03 conf]# cat zoo.cfg 
# The number of milliseconds of each tick
tickTime=2000
# The number of ticks that the initial 
# synchronization phase can take
initLimit=10
# The number of ticks that can pass between 
# sending a request and getting an acknowledgement
syncLimit=5
# the directory where the snapshot is stored.
# do not use /tmp for storage, /tmp here is just 
# example sakes.
dataDir=/zookeeper/server1/data
dataLogDir=/zookeeper/server1/logs
# the port at which the clients will connect
clientPort=2181
server.1=127.0.0.1:2888:3888
[root@wx03 conf]# 

原文地址:https://www.cnblogs.com/hzcya1995/p/13350536.html