Hello,
I'm setting up elasticsearch and centralized pipeline management.
Elasticsearch crashes with these errors:
[2020-04-13T00:41:44,943][ERROR][logstash.licensechecker.licensereader] Unable to retrieve license information from license server {:message=>"Elasticsearch Unreachable: [http://127.0.0.1:9200/][Manticore::SocketException] Connection refused (Connection refused)"}
[2020-04-13T00:41:45,021][ERROR][logstash.configmanagement.elasticsearchsource] Failed to fetch X-Pack information from Elasticsearch. This is likely due to failure to reach a live Elasticsearch cluster.
I am using cloud_id
and cloud_auth
in the logstash.yml
configuration. This is what it looks like:
path.data: /var/lib/logstash
cloud.id: <cluster>:<string>
cloud.auth: elastic:<password>
log.level: info
path.logs: /var/log/logstash
xpack.management.enabled: true
xpack.management.pipeline.id: ["mypipeline"]
xpack.management.elasticsearch.cloud_id: <cluster>:<string>
xpack.management.elasticsearch.cloud_auth: elastic:<password>
This is the complete log:
[2020-04-13T00:48:45,460][INFO ][logstash.configmanagement.bootstrapcheck] Using Elasticsearch as config store {:pipeline_id=>["mypipeline"], :poll_interval=>"5000000000ns"}
[2020-04-13T00:48:47,305][ERROR][logstash.licensechecker.licensereader] Unable to retrieve license information from license server {:message=>"Elasticsearch Unreachable: [http://127.0.0.1:9200/][Manticore::SocketException] Connection refused (Connection refused)"}
[2020-04-13T00:48:47,392][ERROR][logstash.configmanagement.elasticsearchsource] Failed to fetch X-Pack information from Elasticsearch. This is likely due to failure to reach a live Elasticsearch cluster.
[2020-04-13T00:48:47,406][FATAL][logstash.runner ] An unexpected error occurred! {:error=>#<LogStash::LicenseChecker::LicenseError: Failed to fetch X-Pack information from Elasticsearch. This is likely due to failure to reach a live Elasticsearch cluster.>, :backtrace=>["/usr/share/logstash/x-pack/lib/license_checker/licensed.rb:67:in `with_license_check'", "/usr/share/logstash/x-pack/lib/config_management/elasticsearch_source.rb:55:in `initialize'", "/usr/share/logstash/x-pack/lib/config_management/hooks.rb:41:in `after_bootstrap_checks'", "org/logstash/execution/EventDispatcherExt.java:71:in `execute'", "/usr/share/logstash/logstash-core/lib/logstash/runner.rb:299:in `execute'", "/usr/share/logstash/vendor/bundle/jruby/2.5.0/gems/clamp-0.6.5/lib/clamp/command.rb:67:in `run'", "/usr/share/logstash/logstash-core/lib/logstash/runner.rb:242:in `run'", "/usr/share/logstash/vendor/bundle/jruby/2.5.0/gems/clamp-0.6.5/lib/clamp/command.rb:132:in `run'", "/usr/share/logstash/lib/bootstrap/environment.rb:73:in `<main>'"]}
[2020-04-13T00:48:47,418][ERROR][org.logstash.Logstash ] java.lang.IllegalStateException: Logstash stopped processing because of an error: (SystemExit) exit
It looks like it's trying to connect to 127.0.0.1:9200
(where I don't have elasticsearch) instead of the cloud cluster.
I created the pipeline mypipeline
in Logstash Pipelines from the Kibana Management and its syntax is correct. This pipeline works fine if I save it in a /conf.d/mypipeline.conf
instead of centralized pipeline management.