`

ZooKeeper: Install

 
阅读更多

ZooKeeper is a centralized service for maintaining configuration information, naming, providing distributed synchronization, and providing group services.

 

Download from offical websit  http://zookeeper.apache.org/

 

#tar -zxf zookeeper-3.4.6.tar.gz

#cd zookeeper-3.4.6

 

 

----conf/zoo.cfg------

 standalone mode

tickTime=2000
dataDir=/var/lib/zookeeper
clientPort=2181

 

Replicated mode

tickTime=2000
dataDir=/var/lib/zookeeper
clientPort=2181
initLimit=5
syncLimit=2
server.1=zhj-c0:2888:3888
server.2=zhj-c1:2888:3888
server.3=zhj-c2:2888:3888

Distributed the zookeeper dir to all zookeeper nodes

 

Set ZOOKEEPER_HOME and PATH in ~/.bashrc

 

Start ZooKeeper

zkServer.sh start

 

Connecting to ZooKeeper

zkCli.sh -server 127.0.0.1:2181

 

 

 

 

Running Replicated ZooKeeper

 

 



Solution:The reason is that the myid file doesn't exist, you should create the myid file and put the corressponding id  in the file in every node of zookeeper cluster. Meanwhile, the dataDir should be created manually first.

Till to now, I start the zookeeper cluster successfully by runing the zkServer.sh start on very node by manually. There maybe a shutcut to start all servers by some command or script.

see:http://docs.ngdata.com/lilyenterprise-docs-1_0/471-lily/493-lily.html

 

Note:For reliable ZooKeeper service, you should deploy ZooKeeper in a cluster known as an ensemble. As long as a majority of the ensemble are up, the service will be available. Because Zookeeper requires a majority, it is best to use an odd number of machines

 

references:

http://zookeeper.apache.org/doc/r3.4.6/zookeeperAdmin.html

  • 大小: 70.2 KB
分享到:
评论

相关推荐

    nginx-zookeeper:为 Nginx 服务器添加 Zookeeper 支持

    要求Zookeeper C 客户端安装 export LIBZOOKEEPER_PREFIX=/path/to/libzookeeper$ ./configure --add-module=/path/to/nginx-zookeeper$ make# make install配置zookeeper_host 主机:端口值的 CSV 列表。 zookeeper...

    ansible-zookeeper:用于安装和配置Apache ZooKeeper的Ansible角色

    Apache ZooKeeper 在RHEL / CentOS 7上安装和配置Apache ZooKeeper的角色。 该角色可用于安装和群集多个ZooKeeper节点,默认情况下,它将使用为清单...zookeeper_install_dir: '{{ zookeeper_root_dir}}/apache-zook

    开源监控管理zookeeper工具:exhibitor-1.6

    - `zookeeper-install`:指定Zookeeper安装目录。 - `zk-hosts`:设置Zookeeper集群的连接字符串,如`localhost:2181,localhost:2182,localhost:2183`。 - `http-port`:Exhibitor监听的HTTP端口,用于提供Web界面。...

    jboss-as-zookeeper:JBoss EAP 6的Zookeeper子系统

    jboss-as-zookeeper 用于JBoss EAP 6的ZooKeeper子系统 安装JMX依赖项 从下载Java管理扩展(JMX)1.2.1 解压缩jmx-1_2_1-ri.zip cd jmx-1_2_1-bin / lib mvn org.apache.maven.plugins:maven-install-plugin:...

    zookeeper-3.5.7:zookeeper原始码解析-源码解析

    阿帕奇ZooKeeper ... mvn clean install To generate an aggregated apidocs for zookeeper-server and zookeeper-jute: mvn javadoc:aggregate (generated files will be at target/site/apido

    node-zookeeper:Apache Zookeeper的node.js客户端

    npm install zookeeper 大功告成! (请注意小写的名字zookeeper ) 消息 :rocket: 自4.8.0版以来新增功能支持Apache ZooKeeper服务器v3.5.5中引入的新节点类型: Container和TTL :rocket: :party_popper: 自...

    ext-zookeeper::person:适用于PHP的基于协程的ZooKeeper客户端

    ext-zookeeper 依赖 Swoole和PHP-X。 已支持的指令 create addAuth get set getChildren delete exists getAcl setAcl getState getClientId 安装 Swoole pecl install swoole 安装 PHP-X 参考 Build ...

    在MAC OSX中安装启动zookeeper1

    brew install zookeeper ``` 四、 ZooKeeper 的启动 安装完成后,需要启动 ZooKeeper 服务。可以使用以下命令启动 ZooKeeper: ``` brew services start zookeeper ``` 或者,直接运行以下命令启动 ZooKeeper: ...

    zookeeper:Apache ZooKeeper

    Apache ZooKeeper 有关Apache ZooKeeper的最新信息,请访问我们的网站: 和我们的Wiki,位于: 包装/发布文物 使用maven构建项目后,可以从... mvn clean install To generate an aggregated apidocs for zookeepe

    zookeeper:使用Python学习项目

    **Zookeeper:使用Python学习项目** Zookeeper是一个分布式协调服务,广泛应用于大数据和分布式系统中,为集群中的各个节点提供一致性、同步、命名服务等。本项目以Python为编程语言,旨在帮助开发者理解和实践...

    使用ansible安装zookeeper

    本教程将详细讲解如何使用Ansible来安装Zookeeper,一个分布式协调服务,常用于管理Apache Hadoop和其他大数据组件。 **一、Ansible简介** Ansible是一款基于Python的自动化工具,它采用无代理的方式工作,通过SSH...

    zookeeper3.5.1.rar

    3. 编译与安装:`make && make install` 4. 配置环境变量:在`~/.bashrc`或`/etc/profile`中添加`export PATH=$PATH:/usr/local/zookeeper/bin` 5. 激活环境变量:`source ~/.bashrc` 三、Zookeeper配置 Zookeeper...

    chef-handler-zookeeper:一个简单的 Chef 报告处理程序,用于向 Zookeeper 发送有关 Chef 运行的通知

    gem install chef-handler-zookeeper 然后添加到配置( /etc/chef/solo.rb为chef-solo 或/etc/chef/client.rb为chef-client): require "chef/handler/zookeeper" # Create the handler zookeeper_handler = ...

    centos8安装zookeeper3.8.0详细步骤

    export ZOOKEEPER_INSTALL=/usr/local/zookeeper export PATH=$PATH:$ZOOKEEPER_INSTALL/bin ``` 5. 启动 ZooKeeper 5.1. 启动 ZooKeeper 服务端 ``` cd /usr/local/zookeeper/bin/ ./zkServer.sh start ``` 5.2. ...

    zookeeper:Express.js应用程序已部署到Heroku

    2. **安装依赖**:通过`npm install express`安装Express.js和其他必要的模块。 3. **编写应用代码**:创建服务器文件(如`app.js`),设置Express应用的基本结构,包括路由和中间件。 4. **设置Procfile**:创建一...

    kafka、zookeeper、offset Explorer安装包

    共有3个安装包: kafka:kafka_2.12-2.8.0.tgz zookeeper:apache-zookeeper-3.7.0-bin.tar.gz kafka可视化工具:offsetexplorer_64bit.exe

    centos8安装zookeeper-3.5.7.docx

    sudo yum install java-1.8.0-openjdk -y java -version ``` 确保`java -version`返回一个有效的Java版本,例如1.8或更高。 ## 1. 基础环境 确保你的系统已经配置了防火墙规则,允许Zookeeper的默认端口(2181和...

    install_zookeeper.sh

    install_zookeeper

    risk-engine:简单的风险引擎

    建造gradle安装跑步: 启动zookeeper:docker run -d --name zookeeper -p 2181:2181 confluent / zookeeper 启动kafka:docker run -d --name kafka -p 9092:9092 --link zookeeper:zookeeper confluent / kafka...

    Zookeeper源码剖析:深入理解Leader选举机制

    3. 使用`mvn clean install -DskipTests`命令编译并安装。 4. 找到启动脚本,如`QuorumPeerMain`,配置相应的配置文件(如`zoo.cfg`)和日志配置。 5. 可以通过`zkCli.sh`连接源码启动的服务器,或者运行`...

Global site tag (gtag.js) - Google Analytics