1下载好之后解压zookeeper,解压到/usr/local/src/
[root@master ~]# ls
anaconda-ks.cfg jdk-8u152-linux-x64.tar.gz_AuthParam=1633782117_62df496016cc06231de1f3c34916034d zookeeper-3.4.8.tar.gz
[root@master ~]# tar -zxvf zookeeper-3.4.8.tar.gz -C /usr/local/src/
2.修改名称
[root@master ~]# cd /usr/local/src/
[root@master src]# ls
java zookeeper-3.4.8
[root@master src]# mv zookeeper-3.4.8/ zookeeper
[root@master src]# ls
java zookeeper
3.zookeeper文件参数配置:
(1)创建zookeeper数据目录
[root@master zookeeper]# mkdir data //data是用来传输数据的,
[root@master zookeeper]# mkdir logs //logs 是用来记录日志的
(2)修改zoo.cfg文件:
[root@master zookeeper]# cd conf/
[root@master conf]# cp zoo_sample.cfg zoo.cfg
[root@master conf]# vi zoo.cfg
dataDir=/usr/local/src/zookeeper/data //修改
dataLogDir=/usr/local/src/zook