1. cd /usr/share,创建 zookeeper文件夹
2. 进入zookeeper
3. 下载zookeeper
wget https://archive.apache.org/dist/zookeeper/zookeeper-3.5.9/apache-zookeeper-3.5.9-bin.tar.gz
4. 解压
tar -zxvf apache-zookeeper-3.5.9-bin.tar.gz
5. 进入conf文件夹,复制zoo_sample.cfg命名为zoo.cfg
cd apache-zookeeper-3.5.9-bin/conf
cp zoo_sample.cfg zoo.cfg
6. 修改zoo.cfg中配置,改好后保存
7. 编辑 /etc/profile, 在文件末尾追加内容
生效profile
source /etc/profile
8. 启动zookeeper
cd bin
// 启动zookeeper
./zkServer.sh start
// 查看zookeeper状态
./zkServer.sh status
// 关闭zookeeper服务
./zkServer.sh stop
// 重启zookeeper服务
./zkServer.sh restart
标签:bin,cfg,zookeeper,zoo,Centos7,sh,zkServer,安装 From: https://www.cnblogs.com/feng-gamer/p/16642828.html