cd /usr/cstor/zookeeper/conf
cp zoo_sample.cfg zoo.cfg
class="hljs-button signin active" data-title="登录复制" data-report-click="{"spm":"1001.2101.3001.4334"}">
1
2
打开zoo.cfg并修改和添加配置项目,如下:
vim zoo.cfg
class="hljs-button signin active" data-title="登录复制" data-report-click="{"spm":"1001.2101.3001.4334"}">
1
# The number of milliseconds of each ticktickTime=2000# The number of ticks that the initial # synchronization phase can takeinitLimit=10# The number of ticks that can pass between # sending a request and getting an acknowledgementsyncLimit=5# the port at which the clients will connectclientPort=2181# the directory where the snapshot is stored.dataDir=/usr/cstor/zookeeper/data
dataLogDir=/usr/cstor/zookeeper/log
server.1=master:2888:3888
server.2=slave1:2888:3888
server.3=slave2:2888:3888
class="hljs-button signin active" data-title="登录复制" data-report-click="{"spm":"1001.2101.3001.4334"}">
评论记录:
回复评论: