Failed to connect to backoff(elasticsearch(

I currently have two servers which are as follows: where I installed elasticsearch and kibana where I installed filebeat

Filebeat is able to recover the data except that I have this error in the logs:

{"log.level":"error","@timestamp":"2024-04-15T15:01:26.190+0200","log.logger":"publisher_pipeline_output","log.origin":{"function":"*netClientWorker).run","":"pipeline/client_worker.go","file.line":148},"message":"Failed to connect to backoff(elasticsearch( Get \"\": EOF","":"filebeat","ecs.version":"1.6.0"

Can you help me please

After this error, I have this line right after

{"log.level":"info","@timestamp":"2024-04-16T14:51:39.285+0200","log.logger":"publisher_pipeline_output","log.origin":{"function":"*netClientWorker).run","":"pipeline/client_worker.go","file.line":139},"message":"Attempting to reconnect to backoff(elasticsearch( with 249 reconnect attempt(s)","":"filebeat","ecs.version":"1.6.0"}

This error means that your filebeat cannot connect to Elasticsearch.

Is your Elasticsearch using http or https? If it is using https, then you need to change your filebeat configuration to use https as well.

If it is using http, then you may have a network issue that you need to troubleshoot and solve before using filebeat and elasticsearch.

Thank you Leandro for your response.

If I want to see if Elasticsearch works on the browser, I have to put and it works.

If I want to access Kibana, I have to put and it works.

In my filebeat.yml file I activated the "https" protocol. I restarted filebeat and now I have this error in the logs:

{"log.level":"error","@timestamp":"2024-04-16T15:26:38.952+0200","log.logger":"esclientleg","log.origin":{"function":"*HTTPTransportSettings).RoundTripper.LoggingDialer.func2","":"transport/logging.go","file.line":38},"message":"Error dialing x509: certificate signed by unknown authority","":"filebeat","network":"tcp","address":"","ecs.version":"1.6.0"}

You need to configure SSL in Filebeat as well, check the documentation.

1 Like

Thank you so much Leandro for your help. All it's working now.