My setup works without Dockerizing. Now, making a Dockerized project, logstash cannot connect to the ES instance. I set http.host: "0.0.0.0" in logstash.yml, and my pipeline.conf is:
Maybe my host / dynamic routing is the issue, but I have tried the following possibilities:
[ 'elasticsearch' ]
[ 'elasticsearch:9200' ]
[ '192.168.1.7:9200' ]
[ '0.0.0.0:9200' ]
Would really appreciate helping my Logstash connect to ES! For some reason it says:
logstash | [WARN ] 2020-08-04 01:59:58.622 [LogStash::Runner] licensereader - Attempted to resurrect connection to dead ES instance, but got an error. {:url=>"http://0.0.0.0:9200/", :error_type=>LogStash::Outputs::ElasticSearch::HttpClient::Pool::HostUnreachableError, :error=>"Elasticsearch Unreachable: [http://0.0.0.0:9200/][Manticore::SocketException] Connection refused (Connection refused)"}
What does your Elasticsearch configuration look like? What do the logs of ES say? (The bootstrap checks might have failed.)
And just to understand your infrastructure: Logstash and ES are on two different servers in the same network and one is called elasticsearch?
Thank you for your prompt reply! What does your Elasticsearch configuration look like?
So I have no explicit elasticsearch.yml, I have the following two yml:
logstash.yml:
- pipeline.id: main
path.config: "/usr/share/logstash/pipeline"
What do the logs of ES say? (The bootstrap checks might have failed.)
I will followup a reply with the log. (didn't see any failed bootstrap tests)
And just to understand your infrastructure: Logstash and ES are on two different servers in the same network and one is called elasticsearch?
That sounds accurate; to confirm, here is my docker-compose.yml:
Thanks for sharing useful information with us.. It really helpful to me..I always prefer to read the quality content and this thing I found in you post. thanks for sharing with us..
Hello once again! I am still stuck on this issue unfortunately. Any tips on why the Dockerized version cannot connect Logstash to ES, but the non-docker version is fine? Thanks!
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.