# How can we store input\>file\>csv filename into log file?

**URL:** <https://discuss.elastic.co/t/how-can-we-store-input-file-csv-filename-into-log-file/103432>\
**Category:** Logstash\
**Created:** [October 10, 2017, 7:58pm UTC](https://discuss.elastic.co/t/how-can-we-store-input-file-csv-filename-into-log-file/103432 "2017-10-10T19:58:32Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![surajbs](https://avatars.discourse-cdn.com/v4/letter/s/e68b1a/32.png) [@surajbs](https://discuss.elastic.co/u/surajbs)\
**Post date:** [October 10, 2017, 7:58pm UTC](https://discuss.elastic.co/t/how-can-we-store-input-file-csv-filename-into-log-file/103432/1 "2017-10-10T19:58:33Z")

</div>

Hi,

How can we write or store input filename into log file?

Below is my config for the input:  
input {  
file {  
path =\> "path to file/\*.csv"  
type =\> "csv"  
start\_position =\> beginning  
}  
file {  
path =\> "path to log/logstash-plain.log"  
type =\> "syslog"  
sincedb\_path =\> "null"

Any idea or support would be really helpful.

Thank you.

---

<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:** [November 7, 2017, 7:58pm UTC](https://discuss.elastic.co/t/how-can-we-store-input-file-csv-filename-into-log-file/103432/2 "2017-11-07T19:58:40Z")

</div>

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