# Unable to create monthly index in filebeat to elasticsearch

**URL:** <https://discuss.elastic.co/t/unable-to-create-monthly-index-in-filebeat-to-elasticsearch/281567>\
**Category:** Beats\
**Tags:** filebeat\
**Created:** [August 16, 2021, 3:43pm UTC](https://discuss.elastic.co/t/unable-to-create-monthly-index-in-filebeat-to-elasticsearch/281567 "2021-08-16T15:43:56Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Shaiju\_Sam](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/shaiju_sam/32/86283_2.png) [@Shaiju\_Sam](https://discuss.elastic.co/u/Shaiju_Sam)\
**Post date:** [August 16, 2021, 3:43pm UTC](https://discuss.elastic.co/t/unable-to-create-monthly-index-in-filebeat-to-elasticsearch/281567/1 "2021-08-16T15:43:56Z")

</div>

Hi Team,

I am trying to sending logs from couple of my windows servers using filebeat to elasticsearch directly. The index patterns are getting created by default ( filebeat-7.10.2-2021.08.16) however I want to create a custom index name for each of the servers. also I want them to be on monthly index.

I tried with the below since I have my ILM policy disabled  
output.elasticsearch.index: "solrlogsuat.35-%{[agent.version]}-%{+yyyy.MM}"  
setup.template.name: "solrlogsuat.35"  
setup.template.pattern: "solrlogsuat.35-\*"

Once I restart, the filebeat seems to run fine however I dont see the index getting created in ES. Can someone pls help

---

<div class="post-metadata">

**Author:** ![Shaiju\_Sam](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/shaiju_sam/32/86283_2.png) [@Shaiju\_Sam](https://discuss.elastic.co/u/Shaiju_Sam)\
**Post date:** [August 16, 2021, 3:57pm UTC](https://discuss.elastic.co/t/unable-to-create-monthly-index-in-filebeat-to-elasticsearch/281567/2 "2021-08-16T15:57:58Z")

</div>

This the yml config

- type: log  
paths:
  - D:\solr\solr-7.3.0\server\logs\*.log  
fields:  
logtype: "Seal\_SOLR\_Logs"  
device: "SealUAT-10.200.179.35"  
enabled: true  
reload.enabled: true  
reload.period: 10s  
setup.ilm.enabled: false  
setup.ilm.check\_exists: false  
output.elasticsearch.index: "solrlogsuat.35-%{[agent.version]}-%{+yyyy.MM.dd}"  
setup.template.name: "solrlogsuat.35"  
setup.template.pattern: "solrlogsuat.35-_"  
output.elasticsearch:  
hosts: ["_._._.\*:9200"]

---

<div class="post-metadata">

**Author:** ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)\
**Post date:** [August 17, 2021, 12:52am UTC](https://discuss.elastic.co/t/unable-to-create-monthly-index-in-filebeat-to-elasticsearch/281567/3 "2021-08-17T00:52:36Z")

</div>

Can you share the entire config file.

Please also format your code/logs/config using the `</>` button, or markdown style back ticks. It helps to make things easy to read which helps us help you 🙂

---

<div class="post-metadata">

**Author:** ![Shaiju\_Sam](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/shaiju_sam/32/86283_2.png) [@Shaiju\_Sam](https://discuss.elastic.co/u/Shaiju_Sam)\
**Post date:** [September 9, 2021, 4:36am UTC](https://discuss.elastic.co/t/unable-to-create-monthly-index-in-filebeat-to-elasticsearch/281567/4 "2021-09-09T04:36:52Z")

</div>

Hi ,

Thanks for the reply

I was able to fix the issue by using the below in output section

```auto
- Indices
     - index: "solrlogsuat-%{YYYY.MM}"

```

---

<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:** [October 7, 2021, 6:37am UTC](https://discuss.elastic.co/t/unable-to-create-monthly-index-in-filebeat-to-elasticsearch/281567/5 "2021-10-07T06:37:16Z")

</div>

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