栏目分类:
子分类:
返回
名师互学网用户登录
快速导航关闭
当前搜索
当前分类
子分类
实用工具
热门搜索
名师互学网 > IT > 前沿技术 > 大数据 > 大数据系统

Zookeeper集群无法启动的原因分析

Zookeeper集群无法启动的原因分析

Zookeeper集群无法启动的原因分析: centos7上搭建三台zookeeper,相关文件配置没有问题
问题描述:
[atguigu@hadoop102 zookeeper-3.4.10]$ bin/zkServer.sh start
ZooKeeper JMX enabled by default
Using config: /opt/module/zookeeper-3.4.10/bin/../conf/zoo.cfg
Starting zookeeper ... STARTED
[atguigu@hadoop102 zookeeper-3.4.10]$ bin/zkServer.sh status
ZooKeeper JMX enabled by default
Using config: /opt/module/zookeeper-3.4.10/bin/../conf/zoo.cfg
Error contacting service. It is probably not running.



原因分析:
提示:之前zoo.cfg中配置文件为:
server.101=hadoop@101:2888:3888
server.102=hadoop@102:2888:3888
server.103=hadoop@103:2888:3888

每台机器上的myid,设置为相应的id号,我这里设置的是101、102、103


解决方案:
重新将zoo.cfg配置文件修改如下:
server.1=192.168.1.101:2888:3888
server.2=192.168.1.102:2888:3888
server.3=192.168.1.103:2888:3888

每台机器上的myid,设置为相应的id号,我这里设置的是1、2、3

如果出现Unexpected exception, exiting abnormally错误:

删除dataDir路径的version -2文件夹。
重启机器!
重启机器!
重启机器!

成功启动:
##hadoop101机器
[atguigu@hadoop101 zookeeper-3.4.10]$ bin/zkServer.sh status
ZooKeeper JMX enabled by default
Using config: /opt/module/zookeeper-3.4.10/bin/../conf/zoo.cfg
Mode: follower
[atguigu@hadoop101 zookeeper-3.4.10]$ 

##hadoop102机器
[atguigu@hadoop102 zookeeper-3.4.10]$ bin/zkServer.sh status
ZooKeeper JMX enabled by default
Using config: /opt/module/zookeeper-3.4.10/bin/../conf/zoo.cfg
Mode: leader
[atguigu@hadoop102 zookeeper-3.4.10]$ 

##hadoop103机器
[atguigu@hadoop103 zookeeper-3.4.10]$ bin/zkServer.sh status
ZooKeeper JMX enabled by default
Using config: /opt/module/zookeeper-3.4.10/bin/../conf/zoo.cfg
Mode: follower
[atguigu@hadoop103 zookeeper-3.4.10]$ 

转载请注明:文章转载自 www.mshxw.com
我们一直用心在做
关于我们 文章归档 网站地图 联系我们

版权所有 (c)2021-2022 MSHXW.COM

ICP备案号:晋ICP备2021003244-6号