Dubbo - ZooKeeper安装和基本操作

版权声明:写文章辛苦,请不要复制粘贴,如果要,请注明来处 https://blog.csdn.net/u012627861/article/details/83003334

安装

  1. 下载ZooKeeper(tar.gz文件,下载后解压即可)
    你可以在https://www.apache.org/dyn/closer.cgi/zookeeper/查看下载地址。下面的地址也可以任选一个
    http://mirror.bit.edu.cn/apache/zookeeper/ (建议,秒下)
    http://mirrors.hust.edu.cn/apache/zookeeper/
    http://mirrors.shu.edu.cn/apache/zookeeper/
    http://mirrors.tuna.tsinghua.edu.cn/apache/zookeeper/
  2. 配置ZooKeeper
    解压下载好的ZooKeeper压缩包,复制一份conf/zoo-sample.cfg并改名为zoo.cfg。因为ZooKeeper启动时默认会读取conf/zoo.cfg文件。如果找不到该文件将会启动失败并提示invalid config。完了后如下图:
    在这里插入图片描述
  3. 启动ZooKeeper
    windows: 双击运行bin/zkServer.cmd
    mac: sh bin/zkServer.sh start

基本操作

  1. 启动
    windows: 双击运行bin/zkServer.cmd
    mac/linux: sh bin/zkServer.sh start
  2. 关闭
    mac/linux: sh bin/zkServer.sh stop
  3. 重启
    mac/linux: sh bin/zkServer.sh restart

(完)

猜你喜欢

转载自blog.csdn.net/u012627861/article/details/83003334