# Filebeat Elasticsearch output data stream?

**URL:** <https://discuss.elastic.co/t/filebeat-elasticsearch-output-data-stream/371562>\
**Category:** Elastic Search\
**Created:** [December 5, 2024, 7:33pm UTC](https://discuss.elastic.co/t/filebeat-elasticsearch-output-data-stream/371562 "2024-12-05T19:33:55Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![stephenb](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/stephenb/32/40856_2.png) [@stephenb](https://discuss.elastic.co/u/stephenb)\
**Post date:** [December 6, 2024, 3:54am UTC](https://discuss.elastic.co/t/filebeat-elasticsearch-output-data-stream/371562/3 "2024-12-06T03:54:11Z")

</div>

Example: Can be set per input

```auto
filebeat.inputs:
- type: filestream
  id: my-filestream-id
  enabled: true
  paths:
    - /var/log/*.log
  fields_under_root: true
  fields:
    data_stream.type: logs
    data_stream.dataset: my.app
    data_stream.namespace: prod
    event.dataset: my.app

setup.ilm.enabled: false
setup.template.enabled: false
# setup.template.settings:
# index.number_of_shards: 1

setup.kibana:

output.elasticsearch:
  hosts: ["http://localhost:9200"]
  index: "%{[data_stream.type]}-%{[data_stream.dataset]}-%{[data_stream.namespace]}"

```

---

_[View the full topic](https://discuss.elastic.co/t/filebeat-elasticsearch-output-data-stream/371562)._
