# Logstash 5.6.x to 6.1.0 and ES template update

**URL:** <https://discuss.elastic.co/t/logstash-5-6-x-to-6-1-0-and-es-template-update/112482>\
**Category:** Logstash\
**Created:** [December 19, 2017, 5:20pm UTC](https://discuss.elastic.co/t/logstash-5-6-x-to-6-1-0-and-es-template-update/112482 "2017-12-19T17:20:43Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![phr0gz](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/phr0gz/32/9454_2.png) [@phr0gz](https://discuss.elastic.co/u/phr0gz)\
**Post date:** [December 19, 2017, 5:20pm UTC](https://discuss.elastic.co/t/logstash-5-6-x-to-6-1-0-and-es-template-update/112482/1 "2017-12-19T17:20:43Z")

</div>

Hello,

**Here is the list of changes/recommendations (I hope I don't miss anything):**

1. Logstash:  
ES output plugin will change the document\_type from logs to doc

2. ElasticSearch:  
Indices created in Elasticsearch 6.0.0 or later may only contain a single mapping type.  
_default_ mapping will be removed on ES 7 (so it's better to not use this one).

3. Concerning the upgrade:  
Recommended upgrade order is Elasticsearch --\> Kibana --\> Logstash

**Actual infrastructure:**

1. Logstash 5.6 is inserting data to Elasticsearch 5.3 and Kibana 5.6 is used to view the data.

2. Logstash is creating different indexes every days with `index => "logstash-index1-%{+YYYY.MM.dd}"` (using custom templates stored in Elasticsearch) in Elasticsearch.

3. For the predefined templates I use the following mapping:  
`... "mappings" : { "Log" : { "dynamic" : false, "_source" : { "enabled" : true }, "properties":{ ....`

**Upgrade to ELK 6**  
I plan to update ELK stack to 6.x (with the shortest downtime possible), and I've few questions about how to do it:

1. Before starting the upgrade can I update the mapping of the templates to:  
`... "mappings" : { "doc" : { "dynamic" : false, "_source" : { "enabled" : true }, "properties":{ ...`

Then do I need to add the document\_type value and set it to doc?  
And few days later I will update the ELK stack in the recommended order.  
Can it work in that way?

1. If I upgrade ES and Kibana first, can I let Logstash in the 5.6 or will I have issues when the new indexes will be created the day after?

2. Or must I stop Logstash before the daily indexes creation, and then:  
a/ Upgrade the ES templates as mentioned previously.  
b/ Upgrade ES --\> Kibana --\> Logstash  
c/ Start ES --\> Kibana --\> Logstash

Thanks.

---

<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, 2018, 5:20pm UTC](https://discuss.elastic.co/t/logstash-5-6-x-to-6-1-0-and-es-template-update/112482/2 "2018-01-16T17:20:58Z")

</div>

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