0
votes

i have this same problem:

Logstash can not connect to Elastic search

My /conf.d/logstash.conf:

input {
  beats {
    port => 5044
    ssl => true
    ssl_certificate => "/etc/pki/tls/certs/logstash-beats.crt"
    ssl_key => "/etc/pki/tls/private/logstash-beats.key"
    }
}
filter {
    geoip {
    source => "clientip"
    }
}
output {
   elasticsearch {
   host => "http://anotherip, that is not localhost:9200"
   manage_template => false
   index => "%{[@metadata][beat]}-%{+YYYY.MM.dd}"
}}

Error:

error_type=>LogStash::Outputs::ElasticSearch::HttpClient::Pool::HostUnreachableError, :error=>"Elasticsearch Unreachable: [http://localhost:9200/]

Where logstash pick this ip adress? "localhost:9200"

1

1 Answers

0
votes

I solve my problem, i just kill the service with kill -9, after this systemctl start service and works well. Thanks.