I've been trying to push logs with Logstash into 3-node elasticsearch cluster. I start logstash, logstash logs all fine, but no logs appear in ES. I've 3 nodes, both data and master-eligible nodes, and one among them is an injest node.
My logstash pipeline postfix.conf:
output {
elasticsearch {
hosts => [ "elk00-pco.easydns.vpn:9200", "elk01-pco.easydns.vpn:9200", "elk02-pco.easydns.vpn:9200" ]
user => "logstash_logs"
password => "logstash_logs."
ssl => true
cacert => "/etc/logstash/ca.pem"
index => "logstash-postfix-%{+YYYY.MM.dd}"
}
stdout { codec => rubydebug }
}
User logstash_logs
has a role under the same name, which has privileges monitoring
, manage_index_templates
, and all
privileges to logstash-*
indices.
The logstash log (some lines omitted):
[2017-12-22T13:17:43,018][INFO ][logstash.agent ] Successfully started Logstash API endpoint {:port=>9600}
[2017-12-22T13:17:44,673][INFO ][logstash.outputs.elasticsearch] Elasticsearch pool URLs updated {:changes=>{:removed=>, :added=>[https://logstash_system:xxxxxx@elk00-pco.easydns.vpn:9200/, https://logstash_system:xxxxxx@elk01-pco.easydns.vpn:9200/, https://logstash_system:xxxxxx@elk02-pco.easydns.vpn:9200/]}}
[2017-12-22T13:17:44,677][INFO ][logstash.outputs.elasticsearch] Running health check to see if an Elasticsearch connection is working {:healthcheck_url=>https://logstash_system:xxxxxx@elk00-pco.easydns.vpn:9200/, :path=>"/"}
[2017-12-22T13:17:45,423][WARN ][logstash.outputs.elasticsearch] Restored connection to ES instance {:url=>"https://logstash_system:xxxxxx@elk02-pco.easydns.vpn:9200/"}
[2017-12-22T13:17:45,440][INFO ][logstash.outputs.elasticsearch] New Elasticsearch output {:class=>"LogStash::Outputs::Elasticsearch", :hosts=>["https://elk00-pco.easydns.vpn:9200", "https://elk01-pco.easydns.vpn:9200", "https://elk02-pco.easydns.vpn:9200"]}
[2017-12-22T13:17:45,441][INFO ][logstash.pipeline ] Starting pipeline {:pipeline_id=>".monitoring-logstash", "pipeline.workers"=>1, "pipeline.batch.size"=>2, "pipeline.batch.delay"=>5, "pipeline.max_inflight"=>2, :thread=>"#<Thread:0x1f40dc3d@/usr/share/logstash/logstash-core/lib/logstash/pipeline.rb:290 run>"}
[2017-12-22T13:17:45,574][INFO ][logstash.licensechecker.licensereader] Elasticsearch pool URLs updated {:changes=>{:removed=>, :added=>[https://logstash_system:xxxxxx@elk00-pco.easydns.vpn:9200/, https://logstash_system:xxxxxx@elk01-pco.easydns.vpn:9200/, https://logstash_system:xxxxxx@elk02-pco.easydns.vpn:9200/]}}
[2017-12-22T13:17:45,579][INFO ][logstash.licensechecker.licensereader] Running health check to see if an Elasticsearch connection is working {:healthcheck_url=>https://logstash_system:xxxxxx@elk00-pco.easydns.vpn:9200/, :path=>"/"}
[2017-12-22T13:17:45,631][WARN ][logstash.licensechecker.licensereader] Restored connection to ES instance {:url=>"https://logstash_system:xxxxxx@elk00-pco.easydns.vpn:9200/"}
[2017-12-22T13:17:45,867][INFO ][logstash.pipeline ] Pipeline started {"pipeline.id"=>".monitoring-logstash"}
[2017-12-22T13:17:47,404][INFO ][logstash.outputs.elasticsearch] Elasticsearch pool URLs updated {:changes=>{:removed=>, :added=>[https://logstash_logs:xxxxxx@elk00-pco.easydns.vpn:9200/, https://logstash_logs:xxxxxx@elk01-pco.easydns.vpn:9200/, https://logstash_logs:xxxxxx@elk02-pco.easydns.vpn:9200/]}}
[2017-12-22T13:17:47,408][INFO ][logstash.outputs.elasticsearch] Running health check to see if an Elasticsearch connection is working {:healthcheck_url=>https://logstash_logs:xxxxxx@elk00-pco.easydns.vpn:9200/, :path=>"/"}
[2017-12-22T13:17:47,590][WARN ][logstash.outputs.elasticsearch] Restored connection to ES instance {:url=>"https://logstash_logs:xxxxxx@elk00-pco.easydns.vpn:9200/"}
[2017-12-22T13:17:47,617][INFO ][logstash.outputs.elasticsearch] Running health check to see if an Elasticsearch connection is working {:healthcheck_url=>https://logstash_logs:xxxxxx@elk01-pco.easydns.vpn:9200/, :path=>"/"}
[2017-12-22T13:17:47,891][WARN ][logstash.outputs.elasticsearch] Restored connection to ES instance {:url=>"https://logstash_logs:xxxxxx@elk01-pco.easydns.vpn:9200/"}
[2017-12-22T13:17:47,897][INFO ][logstash.outputs.elasticsearch] Running health check to see if an Elasticsearch connection is working {:healthcheck_url=>https://logstash_logs:xxxxxx@elk02-pco.easydns.vpn:9200/, :path=>"/"}
[2017-12-22T13:17:48,039][WARN ][logstash.outputs.elasticsearch] Restored connection to ES instance {:url=>"https://logstash_logs:xxxxxx@elk02-pco.easydns.vpn:9200/"}
[2017-12-22T13:17:48,049][INFO ][logstash.outputs.elasticsearch] Using mapping template from {:path=>nil}
[2017-12-22T13:17:48,057][INFO ][logstash.outputs.elasticsearch] Attempting to install template {:manage_template=>{"template"=>"logstash-", "version"=>60001, "settings"=>{"index.refresh_interval"=>"5s"}, "mappings"=>{"default"=>{"dynamic_templates"=>[{"message_field"=>{"path_match"=>"message", "match_mapping_type"=>"string", "mapping"=>{"type"=>"text", "norms"=>false}}}, {"string_fields"=>{"match"=>"", "match_mapping_type"=>"string", "mapping"=>{"type"=>"text", "norms"=>false, "fields"=>{"keyword"=>{"type"=>"keyword", "ignore_above"=>256}}}}}], "properties"=>{"@timestamp"=>{"type"=>"date"}, "@version"=>{"type"=>"keyword"}, "geoip"=>{"dynamic"=>true, "properties"=>{"ip"=>{"type"=>"ip"}, "location"=>{"type"=>"geo_point"}, "latitude"=>{"type"=>"half_float"}, "longitude"=>{"type"=>"half_float"}}}}}}}}
[2017-12-22T13:17:48,072][INFO ][logstash.outputs.elasticsearch] New Elasticsearch output {:class=>"LogStash::Outputs::Elasticsearch", :hosts=>["//elk00-pco.easydns.vpn:9200", "//elk01-pco.easydns.vpn:9200", "//elk02-pco.easydns.vpn:9200"]}
[2017-12-22T13:17:48,276][INFO ][logstash.pipeline ] Starting pipeline {:pipeline_id=>"main", "pipeline.workers"=>2, "pipeline.batch.size"=>125, "pipeline.batch.delay"=>5, "pipeline.max_inflight"=>250, :thread=>"#<Thread:0x37340b02@/usr/share/logstash/logstash-core/lib/logstash/pipeline.rb:290 run>"}
[2017-12-22T13:17:48,554][INFO ][logstash.pipeline ] Pipeline started {"pipeline.id"=>"main"}
[2017-12-22T13:17:48,577][INFO ][logstash.agent ] Pipelines running {:count=>2, :pipelines=>[".monitoring-logstash", "main"]}
[2017-12-22T13:17:48,579][INFO ][logstash.inputs.metrics ] Monitoring License OK
All checks out fine. I did get this configuration working once. Then, I ran _all
index delete, reconfigured x-pack authentication, and now, no logs/indices are showing up in Kibana. How to track down the issue?
Thanks.