当前位置:网站首页>zk 有一个节点报 It is probably not running且日志无明显报错
zk 有一个节点报 It is probably not running且日志无明显报错
2022-06-23 03:50:00 【ximi_xuexi】
在一次问题排查中,发现应用有部分关于zk的日志报错。且在查看zk状态时,发现有一个节点报错It is probably not running。
1、使用./zkServer.sh status查看所有zk节点的状态。
./zkServer.sh status 这个指令的正常返回应该是leader或者是follower。
2、发现除一个报错节点外,其余节点均返回状态均为follower。
报错节点报错信息如下:
It is probably not running
3、日志排查
在仔细排查过日志后,发现zk无明显报错
4、发现是配置问题
在zk的配置zoo.cfg中,有一个配置:leaderServes=no(默认为yes)
我们先看看leaderServes配置的意义:
leader服务是否接受客户端连接,默认yes。
可以牺牲读取吞吐量为代价增加更高的更新吞吐量,可以设置no。
节点大于3个时建议关闭。
这样就可以明确知道,是由于leaderServes配置为了no,导致leader节点不再接受客户端连接,导致命令行工具无法连接到zk,出现It is probably not running报错。
5、修改配置测试
修改配置:
leaderServes=yes
重新启动zk,之后可以发现./zkServer.sh status查询zk状态,leader节点的返回恢复正常了。
边栏推荐
- [binary tree] flip equivalent binary tree
- #18生成器函数的参数传递
- 自动化测试常见的面试题
- If you want to understand PostgreSQL, you must first brush the architecture
- [ACNOI2022]不猜不行
- Pta:6-33 student ranking table (destructor)
- Pta:6-30 time addition
- P1347 sorting (TOPO)
- [advanced binary tree] AVLTree - balanced binary search tree
- Dynamics 365 插件中权限操作
猜你喜欢
随机推荐
Photoshop PS viewing pixel coordinates, pixel colors, pixel HSB colors
What is metadata
[ACNOI2022]不猜不行
抖音x-bogus和_signature参数分析
Pta:6-33 student ranking table (destructor)
QMainWindow
P1347 sorting (TOPO)
【多模态】UNIMO
PTA: Simulation Implementation of 7-86 set (function template)
OpenJudge NOI 1.13 51:古代密码
Pta:7-58 Book audio-visual rental management
Pta:6-73 function call
photoshop PS 查看像素坐标、像素颜色、像素HSB颜色
Pta:7-31 journal charges
PTA:7-37 学号解析
Leetcode 1208. 尽可能使字符串相等
深度学习 TensorFlow入门
P1363 phantom maze (DFS)
Analysis on the current situation of the Internet of things in 2022
PTA: spacing of 7-69 data



![[multimode] unimo](/img/a5/a857e20e1432ef3623527c8655a49a.png)



![3D数学基础[十六] 匀加速直线运动的公式](/img/51/5b05694bbd0f4fd01dd26cf55b22c7.png)

