无法与 Elasticsearch 通信,请重置连接并重试。EOFError (EOFError)

无法与 Elasticsearch 通信,请重置连接并重试。EOFError (EOFError)

我正在使用 helm chart 在 kubernetes 中安装 elasticsearch、kibana 和 fluentd Elasticsearch 和 kibana pods 顺利启动,但 fluentd pods 没有启动,出现以下错误:

2023-06-13 13:29:39 +0000 [warn]: #0 [filter_kube_metadata] !! The environment variable 'K8S_NODE_NAME' is not set to the node name which can affect the API server and watch efficiency !!
2023-06-13 13:29:39 +0000 [info]: adding match in @KUBERNETES pattern="**" type="relabel"
2023-06-13 13:29:39 +0000 [info]: adding filter in @DISPATCH pattern="**" type="prometheus"
2023-06-13 13:29:39 +0000 [info]: adding match in @DISPATCH pattern="**" type="relabel"
2023-06-13 13:29:39 +0000 [info]: adding match in @OUTPUT pattern="**" type="elasticsearch"
2023-06-13 13:29:41 +0000 [warn]: #0 Could not communicate to Elasticsearch, resetting connection and trying again. EOFError (EOFError)
2023-06-13 13:29:41 +0000 [warn]: #0 Remaining retry: 14. Retry to communicate after 2 second(s).
2023-06-13 13:29:45 +0000 [warn]: #0 Could not communicate to Elasticsearch, resetting connection and trying again. EOFError (EOFError)
2023-06-13 13:29:45 +0000 [warn]: #0 Remaining retry: 13. Retry to communicate after 4 second(s).
2023-06-13 13:29:53 +0000 [warn]: #0 Could not communicate to Elasticsearch, resetting connection and trying again. EOFError (EOFError)
2023-06-13 13:29:53 +0000 [warn]: #0 Remaining retry: 12. Retry to communicate after 8 second(s).

elasticsearch 的命令:

helm install elasticsearch-master elastic/elasticsearch -n efk

fluentd 的命令:

helm install fluentd fluent/fluentd --set elasticsearch.password=22qz66p1gsr8ELA1 -n efk

kibana 命令:

helm install kibana elastic/kibana -n efk

elasticsearch 图片:

Image:       docker.elastic.co/elasticsearch/elasticsearch:8.5.1
Ports:       9200/TCP, 9300/TCP
Host Ports:  0/TCP, 0/TCP

kibana 图像:

  Image:      docker.elastic.co/kibana/kibana:8.5.1
    Port:       5601/TCP
    Host Port:  0/TCP

流畅的图像:

Image:      fluent/fluentd-kubernetes-daemonset:v1.15.2-debian-elasticsearch7-1.0
Port:       24231/TCP
Host Port:  0/TCP

fluentd 配置映射 elasticsearch 输出

04_outputs.conf: |-
    <label @OUTPUT>
      <match **>
        @type elasticsearch
        host elasticsearch-master
        port 9200
        path ""
        user elastic
        password 22qz66p1gsr8ELA1
      </match>
    </label>

我该如何修复

相关内容