Start zookeeper listening on localhost only

Revision history
Tags: kafka zookeeper

I’m setting up a local kafka server with a backing zookeeper instance, but it listens on all interfaces ( by default.

To make zookeeper listen on localhost only, use clientPortAddress in the config/ My full config now looks like this:


Now, when starting zookeeper, it prints the address it’s listening to

# cd kafka_2.12-1.0.0
# bin/ config/
[ <redacted> ]
[2018-01-03 15:58:54,629] INFO binding to port localhost/ (org.apache.zookeeper.server.NIOServerCnxnFactory)

If you have any comments or feedback, please send me an e-mail. (stig at stigok dotcom).

Did you find any typos, incorrect information, or have something to add? Then please propose a change to this post.

Creative Commons License This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.