Logstash adds 9200 port to elastic host during healthcheck

(Tatiana Koroleva) #1

I run elastic cluster in aws (as a service) , so its https endpoint does not have a 9200 ending. But logstash still adds :9200 at the end during healthcheck -

[2018-06-07T11:46:38,218][INFO ][logstash.outputs.elasticsearch] Running health check to see if an Elasticsearch connection is working {:healthcheck_url=>vpc-elasticsearch-internal-..........amazonaws.com:9200/, :path=>"/"}
[2018-06-07T11:47:08,364][WARN ][logstash.outputs.elasticsearch] Attempted to resurrect connection to dead ES instance, but got an error. {:url=>"vpc-elasticsearch-internal-..........amazonaws.com:9200/", :error_type=>LogStash::Outputs::ElasticSearch::HttpClient::Pool::HostUnreachableError, :error=>"Elasticsearch Unreachable: [https://vpc-elasticsearch-internal-..........amazonaws.com:9200/][Manticore::ConnectTimeout] connect timed out"} 

of course the connection fails. Keep in mind that I already have XPACK_MONITORING_ENABLED set to false. Is there any setting I can change to work around this?
Running logstash in k8s - image: docker.elastic.co/logstash/logstash:6.2.4

Thank you in advance!

Tatyana K

(Magnus B├Ąck) #2

Have you tried setting the port number explicitly in the URL?

(Tatiana Koroleva) #3

Magnus, you are a genius =) added 443 at the end and it worked. I guess it's a good idea to add this detail to https://www.elastic.co/guide/en/logstash/current/plugins-outputs-elasticsearch.html
Thank you!

(system) #4

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.