System environment
# UNAME-RM
2.6.32-504.el6.x86_64 x86_64
# Cat/etc/redhat-release
CentOS Release 6.6 (Final)
Server role
Host Name |
Ip |
Node1 |
192.168.56.3 |
Node2 |
192.168.56.4 |
Node3 |
192.168.56.5 |
Setting up the Java heap
[Email protected] ~]# vim/app/zookeeper/conf/java.env
Exportjvmflags= "-xmx512m"
Setting up the configuration file
[Email protected] ~]# cd/app/zookeeper/conf/
[email protected] conf]# CP zoo_sample.cfg Zoo.cfg
[email protected] conf]# Vim zoo.cfg
ticktime=2000
initlimit=10
Synclimit=5
Datadir=/data/zookeeper
clientport=2181
server.1=192.168.56.3:2881:3881
server.2=192.168.56.4:2881:3881
server.3=192.168.56.5:2881:3881
Create Data Catalog
[Email protected] ~]# Mkdir/data/zookeeper
Create a myID file
[Email protected] ~]# echo 1 >/data/zookeeper/myid
Start
[[email protected] ~]# zkserver.sh start
environment variable settings are shown in software Deploying a single zookeeper
The remaining two units can be set according to the above steps, just the configuration of the myID file and Single Server Deployment zookeeper cluster As it is.
As a result of the limitations of personal technology, you are also requested to point out. The author can be found through the following two groups.
Beijing Linux operation and maintenance recruitment group: 153677549
Linux OPS Development Group: 298324302
This article is from the "Chang Jie listen to the Wind People" blog, please make sure to keep this source http://kevinhao.blog.51cto.com/5204735/1787995
Multiple servers deploying zookeeper servers