И это всё МОЁ

Всем привет.

Как настроить в logstash так чтобы логи postifx шли в индекс postfix ?

Если конфиге logstash сделать

input {
beats {
port => 5044
}
}

filter {
grok {
}
}
output {
elasticsearch {
hosts => "localhost:9200"
index => "postfix-%{+YYYY.MM.dd}"
}

}

А в конфиге filebeat.yml

filebeat.inputs:
- type: log
enabled: true
paths:
- /var/log/maillog*
exclude_files: [".gz$"]
tags: ["postfix"]
output.logstash:
hosts: ["10.50.11.8:5044"]

То в логах logstash получим

Could not index event to Elasticsearch. {:status=>400, :action=>["index", {:_id=>nil, :_index=>"buildlog4", :_type=>"_doc", :routing=>nil}, #<LogStash::Event:0x49522875>], :response=>{"index"=>{"_index"=>"buildlog4", "_type"=>"_doc", "_id"=>"tmgaz20Bp3jq-MOqGvqp", "status"=>400, "error"=>{"type"=>"mapper_parsing_exception", "reason"=>"failed to parse field [host] of type [text] in document with id 'tmgaz20Bp3jq-MOqGvqp'. Preview of field's value: '{name=mail1.mydomain.com}'", "caused_by"=>{"type"=>"illegal_state_exception", "reason"=>"Can't get text on a START_OBJECT at 1:357"}}}}}

То есть логи с mail1.mydomain.com пытается записать в индекс buildlog4.

Любая помощь =)