Zookeeper is a high-performance coordinator for distributed applications.It provide configuration information, naming, distributed synchronization and group services as centralized service.

Step 1 : First create a folder where zookeeper is to be installed. Then copy the zookeeper tar file(here we are using zookeeper-3.4.5.tar.gz) in that location.

mkdir -p /home/hduser/Utilities

cd /home/hduser/Utilities

tar -xzvf zookeeper-3.4.5.tar.gz

Step 2 : Edit the zoo.cfg file in the zookeeper/conf folder. If zoo.cfg file is not there, create that file from zoo_sample.cfg.

nano /home/hduser/zookeeper/conf/zoo.cfg

given below an example of zoo.cfg file.We have to edit the ‘dataDir’ in zoo.cfg file. If the dataDir is not exist in that location, we have to create that location.Here dataDir is in ‘/var/zookeeper’ location.Also we have to mention the Ipaddress of the zookeeper installed system and port number.

1234567891011tickTime=2000dataDir=/var/zookeeperclientPort=2181initLimit=5syncLimit=2server.1=172.22.91.40:2888:3888

Step 3: Start Zookeeper

/home/hduser/zookeeper/bin/zkServer.sh start

Step 5 :For checking Zookeeper is started or not

“QuorumPeerMain” is displayed when we are typing jps.

Leave a Reply

Your email address will not be published. Required fields are marked *