Logstash is not able to consume logs from Kafka


(John_06) #1

I am trying to consume logs from Kafka with Logstash and forward them to ES.

I can see Kafka receives logs from Filebeat but Logstash is not able to consume them, though there are no any errors neither in Kafka nor in Logstash logs.

Can anyone explain what is wrong please?

These are config files:
filebeat.yml:

filebeat.prospectors:
- input_type: log
  paths:
    - /var/log/sample.log
registry_file: /var/lib/filebeat/registry

output.kafka:
  hosts: ["broker_server:9092"]
  topic: 'logstash'

logstash.conf:

input {
  kafka {
    bootstrap_servers => "broker_server:9092"
    topics => ["logstash"]
    codec => "json"
  }
}

filter {
}

output {
  elasticsearch {
    hosts => "elasticsearch:9200"
  }
}

(system) #2

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.