zookeeper (伪)集群模式的安装
来源:互联网 发布:淘宝刷心悦会员封号 编辑:程序博客网 时间:2024/05/20 23:04
1)下载
wget http://mirrors.cnnic.cn/apache/zookeeper/zookeeper-3.4.6/zookeeper-3.4.6.tar.gz
2)解压
tar zxvf zookeeper-3.4.6.tar.gz
3)配置
cd zookeeper-3.4.6
cp -rf conf/zoo_sample.cfg conf/zoo.cfgvim conf/zoo.cfgzoo.cfg:
# The number of milliseconds of each tick()
tickTime=2000
# The number of ticks that the initial
# synchronization phase can take
initLimit=10
# The number of ticks that can pass between
# sending a request and getting an acknowledgement
syncLimit=5
# the directory where the snapshot is stored.
# do not use /tmp for storage, /tmp here is just example sakes.
#用于存放数据快照的文件夹,同事用于集群标识 ID 的 myid 文件也放在这儿(一个配置文件只能包含一个 dataDir,即使它被注释掉了)
dataDir=/usr/local/zooDataDir1
dataLogDir=/usr/local/zooDataLogDir
# the port at which the clients will connect,服务端口
clientPort=2181
# the maximum number of client connections.
# increase this if you need to handle more clients
#maxClientCnxns=60
#
# Be sure to read the maintenance section of the
# administrator guide before turning on autopurge.
#
# http://zookeeper.apache.org/doc/current/zookeeperAdmin.html#sc_maintenance
#
# The number of snapshots to retain in dataDir
#autopurge.snapRetainCount=3
# Purge task interval in hours
# Set to "0" to disable auto purge feature
#autopurge.purgeInterval=1
# zookeeper 集群中的每两台机器都是互连的
# 以下是集群其他服务的配置,格式: server.服务器ID=服务器IP:端口1:端口2
server.1=localhost:2888:3888
server.2=localhost:12888:13888
server.3=localhost:22888:23888
# 其中,端口1用来主动连接其他机器,端口2用来接受其他机器的连接,共同使zookeeper集群融为一体
# 服务器ID,在 dataDir(前面的一个配置项)这个目录下新建一个 myid 的文件,文件内容分别是 1,2,3。。。
4)启动zookeeper
依次启动每个节点: sh zkServer.sh start
5)进入zookeeper
sh zkCli.sh
6)Java客户端的连接地址
localhost:2181,localhost:12181,localhost:22181
- zookeeper (伪)集群模式的安装
- zookeeper 伪集群模式安装
- zookeeper伪集群模式安装和配置
- 伪集群模式zookeeper
- zookeeper 伪集群模式
- zookeeper伪集群安装
- ZooKeeper 伪集群安装
- zookeeper的伪集群搭建模式
- zookeeper单机伪集群模式
- zookeeper入门(一)——ZooKeeper伪集群安装
- zookeeper伪分布式集群安装
- zookeeper伪集群安装部署
- mac安装zookeeper伪集群
- ZooKeeper伪分布式集群安装
- zookeeper伪集群安装步骤
- zookeeper伪分布式集群安装
- ZooKeeper伪分布式集群安装
- ZooKeeper伪分布式集群安装
- iOS 按钮超过父视图范围无法响应事件的处理方法
- 创建spine动画
- Modify WIFI history chart in battery
- Linux环境进程间通信(五): 共享内存(上)
- 土豪金100元正反面
- zookeeper (伪)集群模式的安装
- sql server 2008 基础知识
- OTL之Oracle开发总结
- otl编译方法
- sql中带有like时如何使用预编译。
- ORACLE中的DUAL表详解 (转)
- 钻一钻Tomcat 之 Tomcat项目部署(Ⅵ)
- 2686 Matrix(DP)
- bitmap图片转换成JPG图片