zookeeper 集群配置采坑 Connection refused WARN [QuorumPeer[myid=1]/0:0:0:0:0:0:0:0:2181:QuorumCnxManager@584] - Cannot open channel to 3 at election address slave2/192.168.127.133:3888


坑一:

 

Cannot open channel to 2 at election address slave1/192.168.127.132:3888
java.net.ConnectException: Connection refused (Connection refused)

 

如上情況:132 ip 3888 端口沒開。通常是zookeeper服務沒起

端口檢查:

   netstat -anp | grep 3888

正常開啟如下:

 zookeeper 集群不像hadoop集群,在master上啟動后其他的slave也啟動。必須手動或者其他腳本啟動。啟動后。/usr/local/zookeeper/bin目錄下會生成zookeeper.out文件

坑二:

   確保:集群中的selinux 關閉

   檢查:

getenforce:
disabled : 已經關閉


setenforce 0 臨時關閉


vim /etc/selinux/config

改為disabled

 

  三: 確保防火牆關閉或者端口在防火牆中配置好:

centos7 :

 

systemctl stop firewalld.service

 


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM