# Logstash not reading csv file

**URL:** <https://discuss.elastic.co/t/logstash-not-reading-csv-file/158512>\
**Category:** Logstash\
**Created:** [November 28, 2018, 9:03am UTC](https://discuss.elastic.co/t/logstash-not-reading-csv-file/158512 "2018-11-28T09:03:51Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![fillic2002](https://avatars.discourse-cdn.com/v4/letter/f/c2a13f/32.png) [@fillic2002](https://discuss.elastic.co/u/fillic2002)\
**Post date:** [November 28, 2018, 9:03am UTC](https://discuss.elastic.co/t/logstash-not-reading-csv-file/158512/1 "2018-11-28T09:03:52Z")

</div>

I am not able to see any error on running the pipeline but the data is not read either on stdout or elasticsearch. here is my pipeline. I am using 6.5.0

input{  
file{  
path=\>"C:\TR\d\Professional\ELK\Data\test.csv"  
start\_position=\>"beginning"  
sincedb\_path=\>"C:\TR\d\Professional\ELK\Data\sincedb.log"  
}  
}filter{  
csv{  
separator=\>","  
columns=\>["col1","col2","col3","col4"]  
}  
}output {  
elasticsearch {  
hosts=\>"[http://localhost:9200](http://localhost:9200)"  
index=\>"mynewindex"  
}  
}

---

<div class="post-metadata">

**Author:** ![Eniqmatic](https://avatars.discourse-cdn.com/v4/letter/e/ea5d25/32.png) [@Eniqmatic](https://discuss.elastic.co/u/Eniqmatic)\
**Post date:** [November 28, 2018, 12:14pm UTC](https://discuss.elastic.co/t/logstash-not-reading-csv-file/158512/2 "2018-11-28T12:14:50Z")

</div>

Try this:

input{  
file{  
path=\>"C:/TR/d/Professional/ELK/Data/test.csv"  
start\_position=\>"beginning"  
sincedb\_path=\>"C:/TR/d/Professional/ELK/Data/sincedb.log"  
}  
}filter{  
csv{  
separator=\>","  
columns=\>["col1","col2","col3","col4"]  
}  
}output {  
elasticsearch {  
hosts=\>"[http://localhost:9200](http://localhost:9200)"  
index=\>"mynewindex"  
}  
}

---

<div class="post-metadata">

**Author:** ![fillic2002](https://avatars.discourse-cdn.com/v4/letter/f/c2a13f/32.png) [@fillic2002](https://discuss.elastic.co/u/fillic2002)\
**Post date:** [November 28, 2018, 12:42pm UTC](https://discuss.elastic.co/t/logstash-not-reading-csv-file/158512/3 "2018-11-28T12:42:27Z")

</div>

What is the difference and what is fixed?

---

<div class="post-metadata">

**Author:** ![Eniqmatic](https://avatars.discourse-cdn.com/v4/letter/e/ea5d25/32.png) [@Eniqmatic](https://discuss.elastic.co/u/Eniqmatic)\
**Post date:** [November 28, 2018, 12:46pm UTC](https://discuss.elastic.co/t/logstash-not-reading-csv-file/158512/4 "2018-11-28T12:46:46Z")

</div>

The direction of the slashes in the path.

---

<div class="post-metadata">

**Author:** ![fillic2002](https://avatars.discourse-cdn.com/v4/letter/f/c2a13f/32.png) [@fillic2002](https://discuss.elastic.co/u/fillic2002)\
**Post date:** [November 28, 2018, 12:55pm UTC](https://discuss.elastic.co/t/logstash-not-reading-csv-file/158512/5 "2018-11-28T12:55:51Z")

</div>

That fixes the issue..... this lets me believe that the option --config.test\_and\_exit is of no use if this is not captured via this command? this is a silly thing which stopped my entire parsing and showing no error at all....

---

<div class="post-metadata">

**Author:** ![Eniqmatic](https://avatars.discourse-cdn.com/v4/letter/e/ea5d25/32.png) [@Eniqmatic](https://discuss.elastic.co/u/Eniqmatic)\
**Post date:** [November 28, 2018, 12:57pm UTC](https://discuss.elastic.co/t/logstash-not-reading-csv-file/158512/6 "2018-11-28T12:57:55Z")

</div>

I'm unsure, just run as a service is nicer!

---

<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:** [December 26, 2018, 12:57pm UTC](https://discuss.elastic.co/t/logstash-not-reading-csv-file/158512/7 "2018-12-26T12:57:58Z")

</div>

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