I have Logstash 7.6.2 running in my local & using elasticsearch output plugin to write data to Elastic in Elastic Cloud.
elasticsearch {
hosts => ["https://ELASTIC-CLOUD-DNS:9243"]
ssl => true
ssl_certificate_verification => false
cacert => "PATH_TO_CA_CERT_IN_PEM_DOWNLOADED_FROM_ELASTIC-CLOUD"
user => "USERNAME"
password => "PASSWORD"
index => "index-%{my-date}"
}
Error seen when running Logstash:
[logstash.outputs.elasticsearch][main] Attempted to resurrect connection to dead ES instance, but got an error. {:url=>"https://xxxxxx:xxxxxx@EC-DNS:9243/", :error_type=>LogStash::Outputs::Elasticsearch::HttpClient::Pool::HostUnreachableError, :error=>"Elasticsearch Unreachable: [https://xxxxxx:xxxxxx@EC-DNS:9243/][Manticore::ClientProtocolException] PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target"}