# Logstash not uploading data on ES

**URL:** <https://discuss.elastic.co/t/logstash-not-uploading-data-on-es/119172>\
**Category:** Logstash\
**Created:** [February 9, 2018, 6:27am UTC](https://discuss.elastic.co/t/logstash-not-uploading-data-on-es/119172 "2018-02-09T06:27:06Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![niraj\_pandey](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/niraj_pandey/32/44034_2.png) [@niraj\_pandey](https://discuss.elastic.co/u/niraj_pandey)\
**Post date:** [February 9, 2018, 6:27am UTC](https://discuss.elastic.co/t/logstash-not-uploading-data-on-es/119172/1 "2018-02-09T06:27:06Z")

</div>

Hi,

I have created a template and now using logstash to push the data on elasticsearch.  
And I see it's created the index but not uploaded the data. Any idea ?

Here is template:

PUT \_template/ltemplsbacct  
{  
"index\_patterns": ["lsbacct\*","new\_lsbacct\*","lsbacct\_new\*","acct\*","abc\*"],  
"settings": {  
"number\_of\_shards": 1  
},  
"mappings": {  
"type1": {  
"\_source": {  
"enabled": false  
},

```
"properties": {
      "@timestamp": {
        "type": "date"
      },
      "@version": {
        "type": "text",
        "fields": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "CWD": {
        "type": "text",
        "fields": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }

```

} }  
}

Here is input.conf and output.conf

input.conf:

input {  
file {  
path =\> "/tmp/t.txt"  
start\_position =\> "beginning"  
type =\> 'acct'  
tags =\> ["acct"]  
add\_field =\> {"cluster" =\> "xyz" }  
}

output.conf:

output {  
if [type] == "lsbacct"{  
elasticsearch {  
hosts =\> "localhost:9200"  
index =\> "acctlsb-%{+YYYY.MM.dd}"  
}  
#stdout{}  
}

filte.conf is empty

---

<div class="post-metadata">

**Author:** ![niraj\_pandey](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/niraj_pandey/32/44034_2.png) [@niraj\_pandey](https://discuss.elastic.co/u/niraj_pandey)\
**Post date:** [February 9, 2018, 6:28am UTC](https://discuss.elastic.co/t/logstash-not-uploading-data-on-es/119172/2 "2018-02-09T06:28:05Z")

</div>

While the same is working perfect if I do this without using template

---

<div class="post-metadata">

**Author:** ![magnusbaeck](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/magnusbaeck/32/44943_2.png) [@magnusbaeck](https://discuss.elastic.co/u/magnusbaeck)\
**Post date:** [February 9, 2018, 7:34am UTC](https://discuss.elastic.co/t/logstash-not-uploading-data-on-es/119172/3 "2018-02-09T07:34:49Z")

</div>

Have you looked in the Logstash log for clues?

---

<div class="post-metadata">

**Author:** ![niraj\_pandey](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/niraj_pandey/32/44034_2.png) [@niraj\_pandey](https://discuss.elastic.co/u/niraj_pandey)\
**Post date:** [February 9, 2018, 8:17am UTC](https://discuss.elastic.co/t/logstash-not-uploading-data-on-es/119172/4 "2018-02-09T08:17:40Z")

</div>

Got it. Found the clue from elasticsearch logs.  
My mapping was carrying more than one type ☹

But now facing another issue. On kibana Discover page under Available Fields all the fileds are not visible , while i can see those field under visualize when creating some graph.

---

<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:** [March 9, 2018, 8:17am UTC](https://discuss.elastic.co/t/logstash-not-uploading-data-on-es/119172/5 "2018-03-09T08:17:44Z")

</div>

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