This page covers common configuration steps for ZooKeeper deployments.
Use the same configuration file referenced in the setup guide for your installation.
Typical location:
/etc/zookeeper/zoo.cfg
zoo.cfg)tickTime=2000
dataDir=/var/lib/zookeeper
clientPort=2181
initLimit=10
syncLimit=5
server.1=10.0.0.10:2888:3888
server.2=10.0.0.11:2888:3888
server.3=10.0.0.12:2888:3888
Per-node myid example:
echo 1 | sudo tee /var/lib/zookeeper/myid
myid unique and aligned with server.N entries.2181, 2888, and 3888 to trusted networks.Reload services or restart the cluster nodes after updates.
sudo systemctl restart zookeeper
Run a service discovery query to confirm configuration is valid.
echo ruok | nc 127.0.0.1 2181
echo stat | nc 127.0.0.1 2181