linux 下 Zookeeper 安装

2020-05-16  本文已影响0人  击石小记

安装包下载:https://mirrors.tuna.tsinghua.edu.cn/apache/zookeeper/zookeeper-3.6.1/apache-zookeeper-3.6.1-bin.tar.gz

  1. 假设文件下载解压到路径为:/mnt/d/dev_pkg/apache-zookeeper-3.6.1-bin/apache-zookeeper-3.6.1-bin
cd  /mnt/d/dev_pkg/apache-zookeeper-3.6.1-bin/apache-zookeeper-3.6.1-bin 
mkdir data_dir
  1. 创建配置 vi conf/zoo.cfg 输入以下内容:
tickTime=2000
dataDir=/var/lib/zookeeper
clientPort=2181
  1. 启动 Server:bin/zkServer.sh start
  2. 启动 Client:bin/zkCli.sh -server 127.0.0.1:2181

参考:https://zookeeper.apache.org/doc/current/zookeeperStarted.html

上一篇下一篇

猜你喜欢

热点阅读