Category: Zookeeper
-
判断 zookeeper 健康状态
echo stat | nc localhost 2181 | grep Mode You will get the response if the node is acting as a leader: Mode: leader If it is a follower, you will see: Mode: follower Alternatively, you can use the zkServer.sh located in /opt/zookeeper/bin: ./zkServer.sh status [root@misc010-prod ~]# echo mntr |nc 10.16.1.60 2181 zk_version 3.4.10-39d3a4f269333c922ed3db283be479f9deacaa0f, built…