Howto: Zookeeper Cheatsheet

Howto: Zookeeper Cheatsheet

First install Zookeeper on Arch GNU/Linux.

$ yay -S zookeeper

Then connect to the server.

$ zkCli.sh -server <server>

List all keys recursively.

$ ls -R /

List the specified path.

$ ls -R <path>

Return a key value.

$ get <path>

Set a key value.

$ set <path> <data>

Delete a value.

$ delete <path>

Remember the rule of the The Four Letter Words.

$ echo stat | nc localhost 2181
$ echo ruok | nc localhost 2181
$ echo srvr | nc localhost 2181
$ echo cons | nc localhost 2181
$ echo dump | nc localhost 2181
$ echo conf | nc localhost 2181

Subscribe to Linux Developer

Don’t miss out on the latest issues. Sign up now to get access to the library of members-only issues.
jamie@example.com
Subscribe