【Kibana】【ElasticSearch】【6.8.6】运行kibana报错[error][status][plugin:[email protected]]

 

今天遇到一个特别坑的问题,在虚拟机使用docker, 安装完elasticSearch的集群后,在win10下安装kibana, 一直提示下面的错误。然后各种尝试。比如

  1. 在虚拟机上使用docker安装kibana(怀疑windows的kibana与docker通信问题)
  2. 在虚拟机上直接安装kibana等办法.

以上2步都没有解决问题。

然后怀疑与集群有关。 所以建了一个单机的elasticSearch,然后使用原来的kibana连接,发现运行正常。最后通过docker logs 查看ES集群的报错信息,发现原来是集群搭建有问题。

 

解决办法:

我的ec脚本是参考: https://www.cnblogs.com/ghostdot/p/12455505.html

具体ES的docker脚本如下elasticsearch.yml, 而我犯的低级错误是。。。

没有改network.publish_host的IP,这里的network.publish_host其实是你宿主机的IP。

需要总结的另一个经验是, 在首次运行docker的时候,不要使用-d参数,否则有很多错误无法看到。

 

Elasticsearch.yml:

cluster.name: elasticsearch-cluster  #集群唯一名称,所有节点一致

node.name: es_node1                     #节点名称

network.bind_host: 0.0.0.0              #设置可以访问的ip,默认为0.0.0.0,这里全部设置通过

network.publish_host: 192.168.2.2       #设置其它结点和该结点交互的ip地址

http.port: 9200                     #设置对外服务的http端口,默认为9200

transport.tcp.port: 9300           #设置节点之间交互的tcp端口,默认是9300

http.cors.enabled: true

http.cors.allow-origin: "*"

node.master: true           #配置该结点是否有资格被选举为主结点(候选主结点),为了防止脑裂,配置奇数个候选主结点

node.data: true              #配置该结点是数据结点,用于保

discovery.zen.ping.unicast.hosts: ["192.168.2.2:9300","192.168.2.2:9301","192.168.2.2:9302"] #集群个节点IP地址

discovery.zen.minimum_master_nodes: 2  #自动发现master节点的最小数

indices.query.bool.max_clause_count: 10240

 

错误日志:

log   [14:10:30.821] [info][status][plugin:[email protected]] Status changed from uninitialized to green - Ready

  log   [14:10:30.850] [info][status][plugin:[email protected]] Status changed from uninitialized to green - Ready

  log   [14:10:32.414] [info][status][plugin:[email protected]] Status changed from uninitialized to green - Ready

  log   [14:10:33.850] [error][status][plugin:[email protected]] Status changed from yellow to red - Service Unavailable

  log   [14:10:33.854] [error][status][plugin:[email protected]] Status changed from yellow to red - Service Unavailable

  log   [14:10:33.859] [error][status][plugin:[email protected]] Status changed from yellow to red - Service Unavailable

  log   [14:10:33.863] [error][status][plugin:[email protected]] Status changed from yellow to red - Service Unavailable

  log   [14:10:33.865] [error][status][plugin:[email protected]] Status changed from yellow to red - Service Unavailable

 

 

 

 

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章