运行MR任务时,报错zk连接被拒绝
检查zk集群都是启动状态,发现其中一台,出现如下错误
[root@node4 bin]# zkServer.sh status
JMX enabled by default
Using config: /opt/zookeeper-3.4.6/bin/../conf/zoo.cfg
Error contacting service. It is probably not running.
检查之后,zk集群的配置信息没有问题
netstat -an | grep 2181
端口未被占用,更改启动命令发现
./zkServer.sh start-foreground
如下错误
Unable to load database on disk
java.io.IOException: The current epoch, 24, is older than the last zxid, 158913789953
the current,24,is older than the last zxid
该台服务器上的时间节点与其他服务器不一致,删除后使其自动同步
删除掉/data目录下的version-2目录,重启解决