Important Zookeeper Commands

Zookeeper have bunch of commands to get the information about the services managed by Zookeeper as well as Zookeeper itself.

  • Make sure to create softlink for java executable so that zkCli.sh can run.
  • zkCli.sh or zookeeper-shell.sh – It is primarily to get details about services
    • Here are some sample commands. Be careful while running rmr or any del commands.
    • zookeeper-shell.sh comes with Zookeeper as part of Kafka. Typically we will have zkCli.sh

https://gist.github.com/dgadiraju/fe45746363034c1c3d3244c8db641b3b

  • Four letter commands – to get details about Zookeeper cluster
    • Sample Command – echo conf | nc kdbroker01.itversity.com 2181

Make sure you have setup Zookeeper successfully and run zkCli.sh command by the end of this section. If there are any issues, please follow up with us before going any further.

Also, if you are planning to take a break before going to next section, make sure to stop services using Cloudera Manager and then all the 7 servers by going to GCP console so that you do not waste your credits or not charged unnecessarily.

Share this post