# Logstash output from filebeat. What is 'index' configuration option?

**URL:** <https://discuss.elastic.co/t/logstash-output-from-filebeat-what-is-index-configuration-option/212421>\
**Category:** Beats\
**Tags:** filebeat\
**Created:** [December 19, 2019, 12:31am UTC](https://discuss.elastic.co/t/logstash-output-from-filebeat-what-is-index-configuration-option/212421 "2019-12-19T00:31:11Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Anand9](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/anand9/32/59665_2.png) [@Anand9](https://discuss.elastic.co/u/Anand9)\
**Post date:** [December 19, 2019, 12:31am UTC](https://discuss.elastic.co/t/logstash-output-from-filebeat-what-is-index-configuration-option/212421/1 "2019-12-19T00:31:11Z")

</div>

This is an excerpt taken from filebeat config for logstash output [here](https://www.elastic.co/guide/en/beats/filebeat/current/logstash-output.html#logstash-index)

![image](https://us1.discourse-cdn.com/elastic/original/3X/b/6/b634028875359e480b109dafae1fb6d68be48d9b.png)  
I'm wondering what does index have to do with logstash. In my logstash configuration itslef, if I redirect logs to ElasticSearch I believe my logs will be indexed under "logstash-%{+YYYY.MM.dd}" as the documentation says [here](https://www.elastic.co/guide/en/logstash/current/plugins-outputs-elasticsearch.html#plugins-outputs-elasticsearch-index).

So why is there an option to set `index` for filebeat's logstash output?

---

<div class="post-metadata">

**Author:** ![rugenl](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/rugenl/32/12887_2.png) [@rugenl](https://discuss.elastic.co/u/rugenl)\
**Post date:** [December 19, 2019, 2:20am UTC](https://discuss.elastic.co/t/logstash-output-from-filebeat-what-is-index-configuration-option/212421/2 "2019-12-19T02:20:46Z")

</div>

Yes, there is an index parameter. From the doc, if filebeat 7.5.0 send the data to logstash, the index would be filebeat-7.5.0.

```
output {
  elasticsearch {
    hosts => ["http://localhost:9200"]
    index => "%{[@metadata][beat]}-%{[@metadata][version]}" 
  }
}
```

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [January 16, 2020, 2:20am UTC](https://discuss.elastic.co/t/logstash-output-from-filebeat-what-is-index-configuration-option/212421/3 "2020-01-16T02:20:51Z")

</div>

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