# Reading template in logstash

**URL:** <https://discuss.elastic.co/t/reading-template-in-logstash/27123>\
**Category:** Logstash\
**Created:** [August 10, 2015, 12:48pm UTC](https://discuss.elastic.co/t/reading-template-in-logstash/27123 "2015-08-10T12:48:00Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Dan](https://avatars.discourse-cdn.com/v4/letter/d/eada6e/32.png) [@Dan](https://discuss.elastic.co/u/Dan)\
**Post date:** [August 10, 2015, 12:48pm UTC](https://discuss.elastic.co/t/reading-template-in-logstash/27123/1 "2015-08-10T12:48:01Z")

</div>

Hi All,

i am using logstash jdbc-input plugin to load data.I want all string columns should be analyzed.

I fallowed bellow steps::

1. i have placed my own template at  
"C:\logstash-1.5.3\vendor\bundle\jruby\1.9\gems\logstash-output-elasticsearch-1.0.5-java\lib\logstash\outputs\elasticsearch " drive.

2.in the logstash config file i mention below output parameter

template =\> "C:\logstash-1.5.3\vendor\bundle\jruby\1.9\gems\logstash-output-elasticsearch-1.0.5-java\lib\logstash\outputs\elasticsearch\datalake\_template.json"

3.when i am searching for list of available template by using curl command  
curl -XGET localhost:9200/\_template/

It's not looking for the template which i given.

But i am not able to find that which template it's reading.

Please let me know where is the default template location.

Please help me.

Regards,  
Dinesh.

---

<div class="post-metadata">

**Author:** ![umangjain](https://avatars.discourse-cdn.com/v4/letter/u/8e8cbc/32.png) [@umangjain](https://discuss.elastic.co/u/umangjain)\
**Post date:** [August 10, 2015, 5:28pm UTC](https://discuss.elastic.co/t/reading-template-in-logstash/27123/2 "2015-08-10T17:28:50Z")

</div>

Try this as it works for me:

elasticsearch {  
template\_overwrite =\> true  
template\_name =\> xyztemplate  
template =\> "/opt/logstash/template.json"  
protocol =\> "http"  
codec =\> "plain"  
manage\_template =\> true  
host =\> "localhost"  
index =\> "xyz-%{+YYYY.MM}"  
}

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:** [July 6, 2017, 5:32am UTC](https://discuss.elastic.co/t/reading-template-in-logstash/27123/3 "2017-07-06T05:32:27Z")

</div>


