当前位置:   article > 正文

CentOS7安装ZooKeeper完整步骤

CentOS7安装ZooKeeper完整步骤

1.解压zookeeper安装包

tar -zxf zookeeper-3.4.5-cdh5.14.2.tar.gz

2.移动zookeeper的位置

mv zookeeper-3.4.5-cdh5.14.2 soft/zk345

3.进入soft/zk345/conf/

cd soft/zk345/conf/

4.复制zoo_sample.cfg为zoo.cfg

cp zoo_sample.cfg zoo.cfg

5.修改zoo.cfg

vim zoo.cfg 

5.1修改dataDir

dataDir=/opt/soft/zk345/data

5.2在文件末尾添加server

server.1=主机地址:2888:3888

6.修改/etc/profile

vim /etc/profile

6.1添加zookeeper运行环境

  1. #Zookeeper env
  2. export ZOOKEEPER_HOME=/opt/soft/zk345
  3. export PATH=$PATH:$ZOOKEEPER_HOME/bin

7.执行/etc/profile

source /etc/profile

8.进入zk345下的bin

cd /opt/soft/zk345/sbin/../bin

9.执行zkServer.sh

zkServer.sh start

最后输入命令jps,如果存在进程QuorumPeerMain则安装zookeeper成功!

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/Li_阴宅/article/detail/774433
推荐阅读
相关标签
  

闽ICP备14008679号