filebeat separate index for logs

filebeat.inputs:
- ...
fields:
type: "logs1"
- ...
fields:
type: "logs2"

setup.template.name: "myindex-%{[agent.version]}"
setup.template.pattern: "myindex-%{[agent.version]}-*"

output.elasticsearch:
...
index: "myindex-%{[agent.version]}-%{[fields.type]:other}-%{+yyyy.MM.dd}"

Leave a Reply

Your email address will not be published. Required fields are marked *