# Not Able to load data in ElasticSearch

**URL:** <https://discuss.elastic.co/t/not-able-to-load-data-in-elasticsearch/213328>\
**Category:** Logstash\
**Created:** [December 30, 2019, 10:27am UTC](https://discuss.elastic.co/t/not-able-to-load-data-in-elasticsearch/213328 "2019-12-30T10:27:49Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Saurabh\_Jain](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/saurabh_jain/32/60073_2.png) [@Saurabh\_Jain](https://discuss.elastic.co/u/Saurabh_Jain)\
**Post date:** [December 30, 2019, 10:27am UTC](https://discuss.elastic.co/t/not-able-to-load-data-in-elasticsearch/213328/1 "2019-12-30T10:27:49Z")

</div>

Hi,

I am trying to upload data via logstash in ElasticSearch but somehow not able to do.

Could you pls chk the conf file and logstash logs and suggest for the same.

input {  
file {  
path =\> "C:\Users\SaurabhJain\Desktop\ElasticSearch\_Kibana\countries-of-the-world\countriesoftheworld.csv"  
start\_position =\> "beginning"  
sincedb\_path =\> "NUL"  
close\_older =\> "1 hour"  
stat\_interval =\> "1 second"  
}  
}  
filter {  
csv {  
separator =\> ","  
columns =\> ["Country","Region","Population","Area"]  
}  
mutate {convert =\> ["Population", "integer"]}  
mutate {convert =\> ["Area", "integer"]}  
}  
output {  
elasticsearch {  
hosts =\> ["localhost:9200"]  
index =\> "countriesdata-%{+dd.MM.YYYY}"  
}  
stdout {codec =\> json\_lines }  
}

C:\Users\SaurabhJain\Desktop\ElasticSearch\_Kibana\>logstash -f country.conf  
Thread.exclusive is deprecated, use Thread::Mutex  
Sending Logstash logs to C:/Users/SaurabhJain/Desktop/ElasticSearch\_Kibana/logstash-7.5.1.tar/logstash-7.5.1/logs which is now configured via log4j2.properties  
[2019-12-30T15:21:24,805][WARN][logstash.config.source.multilocal] Ignoring the 'pipelines.yml' file because modules or command line options are specified  
[2019-12-30T15:21:24,921][INFO][logstash.runner] Starting Logstash {"logstash.version"=\>"7.5.1"}  
[2019-12-30T15:21:26,262][INFO][org.reflections.Reflections] Reflections took 41 ms to scan 1 urls, producing 20 keys and 40 values  
[2019-12-30T15:21:27,179][INFO][logstash.outputs.elasticsearch][main] Elasticsearch pool URLs updated {:changes=\>{:removed=\>, :added=\>[[http://localhost:9200/](http://localhost:9200/)]}}  
[2019-12-30T15:21:27,349][WARN][logstash.outputs.elasticsearch][main] Restored connection to ES instance {:url=\>"[http://localhost:9200/](http://localhost:9200/)"}  
[2019-12-30T15:21:27,380][INFO][logstash.outputs.elasticsearch][main] ES Output version determined {:es\_version=\>7}  
[2019-12-30T15:21:27,380][WARN][logstash.outputs.elasticsearch][main] Detected a 6.x and above cluster: the `type` event field won't be used to determine the document \_type {:es\_version=\>7}  
[2019-12-30T15:21:27,433][INFO][logstash.outputs.elasticsearch][main] New Elasticsearch output {:class=\>"LogStash::Outputs::ElasticSearch", :hosts=\>["[//localhost:9200](https://localhost:9200)"]}  
[2019-12-30T15:21:27,465][INFO][logstash.outputs.elasticsearch][main] Using default mapping template  
[2019-12-30T15:21:27,511][WARN][org.logstash.instrument.metrics.gauge.LazyDelegatingGauge][main] A gauge metric of an unknown type (org.jruby.specialized.RubyArrayOneObject) has been create for key: cluster\_uuids. This may result in invalid serialization. It is recommended to log an issue to the responsible developer/development team.  
[2019-12-30T15:21:27,511][INFO][logstash.javapipeline][main] Starting pipeline {:pipeline\_id=\>"main", "pipeline.workers"=\>8, "pipeline.batch.size"=\>125, "pipeline.batch.delay"=\>50, "pipeline.max\_inflight"=\>1000, "pipeline.sources"=\>["C:/Users/SaurabhJain/Desktop/ElasticSearch\_Kibana/country.conf"], :thread=\>"#\<Thread:0x5074bc run\>"}  
[2019-12-30T15:21:27,549][INFO][logstash.outputs.elasticsearch][main] Attempting to install template {:manage\_template=\>{"index\_patterns"=\>"logstash-_", "version"=\>60001, "settings"=\>{"index.refresh\_interval"=\>"5s", "number\_of\_shards"=\>1}, "mappings"=\>{"dynamic\_templates"=\>[{"message\_field"=\>{"path\_match"=\>"message", "match\_mapping\_type"=\>"string", "mapping"=\>{"type"=\>"text", "norms"=\>false}}}, {"string\_fields"=\>{"match"=\>"_", "match\_mapping\_type"=\>"string", "mapping"=\>{"type"=\>"text", "norms"=\>false, "fields"=\>{"keyword"=\>{"type"=\>"keyword", "ignore\_above"=\>256}}}}}], "properties"=\>{"@timestamp"=\>{"type"=\>"date"}, "@version"=\>{"type"=\>"keyword"}, "geoip"=\>{"dynamic"=\>true, "properties"=\>{"ip"=\>{"type"=\>"ip"}, "location"=\>{"type"=\>"geo\_point"}, "latitude"=\>{"type"=\>"half\_float"}, "longitude"=\>{"type"=\>"half\_float"}}}}}}}  
[2019-12-30T15:21:28,097][INFO][logstash.javapipeline][main] Pipeline started {"pipeline.id"=\>"main"}  
[2019-12-30T15:21:28,135][INFO][filewatch.observingtail][main] START, creating Discoverer, Watch with file and sincedb collections  
[2019-12-30T15:21:28,151][INFO][logstash.agent] Pipelines running {:count=\>1, :running\_pipelines=\>[:main], :non\_running\_pipelines=\>}  
[2019-12-30T15:21:28,467][INFO][logstash.agent] Successfully started Logstash API endpoint {:port=\>9600}

---

<div class="post-metadata">

**Author:** ![Badger](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/badger/32/25190_2.png) [@Badger](https://discuss.elastic.co/u/Badger)\
**Post date:** [December 30, 2019, 2:44pm UTC](https://discuss.elastic.co/t/not-able-to-load-data-in-elasticsearch/213328/2 "2019-12-30T14:44:31Z")

</div>

> [@Saurabh\_Jain](#):
>
> path =\> "C:\Users\SaurabhJain\Desktop\Elasticsearch\_Kibana\countries-of-the-world\countriesoftheworld.csv"

Do not use backslash in filenames in the path option of a file input. Use / (or \\).

---

<div class="post-metadata">

**Author:** ![Saurabh\_Jain](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/saurabh_jain/32/60073_2.png) [@Saurabh\_Jain](https://discuss.elastic.co/u/Saurabh_Jain)\
**Post date:** [January 1, 2020, 8:59am UTC](https://discuss.elastic.co/t/not-able-to-load-data-in-elasticsearch/213328/4 "2020-01-01T08:59:57Z")

</div>

Thanks @Badger

It worked . I changed the path to forward slash.

path =\> "C:/Users/SaurabhJain/Desktop/ElasticSearch\_Kibana/countries-of-the-world/countriesoftheworld.csv"

---

<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 29, 2020, 9:00am UTC](https://discuss.elastic.co/t/not-able-to-load-data-in-elasticsearch/213328/5 "2020-01-29T09:00:26Z")

</div>

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