# How can i able to see my documents content using logstash?

**URL:** <https://discuss.elastic.co/t/how-can-i-able-to-see-my-documents-content-using-logstash/71206>\
**Category:** Logstash\
**Created:** [January 11, 2017, 11:09am UTC](https://discuss.elastic.co/t/how-can-i-able-to-see-my-documents-content-using-logstash/71206 "2017-01-11T11:09:43Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Yaswanth](https://avatars.discourse-cdn.com/v4/letter/y/94ad74/32.png) [@Yaswanth](https://discuss.elastic.co/u/Yaswanth)\
**Post date:** [January 11, 2017, 11:09am UTC](https://discuss.elastic.co/t/how-can-i-able-to-see-my-documents-content-using-logstash/71206/1 "2017-01-11T11:09:43Z")

</div>

Hi,  
ES 2.4.0  
Logstash 5.1.1  
I want to get the contents of documents from localhost index and i used the following code :

input {  
elasticsearch {  
hosts =\> "[http://localhost:9200/](http://localhost:9200/)"  
index =\> "mediacontent-jan-2017"

}  
}  
output {  
stdout{  
}  
}

Rather than data content i am getting like this:  
status in cmd prompt:

2017-01-11T11:03:05.129Z %{host} %{message}  
2017-01-11T11:03:05.129Z %{host} %{message}  
2017-01-11T11:03:05.129Z %{host} %{message}  
2017-01-11T11:03:05.129Z %{host} %{message}  
2017-01-11T11:03:05.129Z %{host} %{message}  
2017-01-11T11:03:05.129Z %{host} %{message}  
2017-01-11T11:03:05.129Z %{host} %{message}  
2017-01-11T11:03:05.145Z %{host} %{message}  
2017-01-11T11:03:05.145Z %{host} %{message}  
2017-01-11T11:03:05.145Z %{host} %{message}  
2017-01-11T11:03:05.145Z %{host} %{message}  
2017-01-11T11:03:05.145Z %{host} %{message}  
2017-01-11T11:03:05.145Z %{host} %{message}  
2017-01-11T11:03:05.145Z %{host} %{message}  
2017-01-11T11:03:05.145Z %{host} %{message}  
2017-01-11T11:03:05.145Z %{host} %{message}  
2017-01-11T11:03:05.145Z %{host} %{message}  
2017-01-11T11:03:05.145Z %{host} %{message}  
2017-01-11T11:03:05.145Z %{host} %{message}  
2017-01-11T11:03:05.145Z %{host} %{message}  
2017-01-11T11:03:05.145Z %{host} %{message}  
2017-01-11T11:03:05.145Z %{host} %{message}  
2017-01-11T11:03:05.145Z %{host} %{message}  
2017-01-11T11:03:05.145Z %{host} %{message}  
2017-01-11T11:03:05.145Z %{host} %{message}  
2017-01-11T11:03:05.145Z %{host} %{message}  
2017-01-11T11:03:05.145Z %{host} %{message}  
2017-01-11T11:03:05.145Z %{host} %{message}  
2017-01-11T11:03:05.160Z %{host} %{message}  
2017-01-11T11:03:05.160Z %{host} %{message}  
2017-01-11T11:03:05.160Z %{host} %{message}  
2017-01-11T11:03:05.160Z %{host} %{message}  
2017-01-11T11:03:05.160Z %{host} %{message}  
2017-01-11T11:03:05.160Z %{host} %{message}  
2017-01-11T11:03:05.160Z %{host} %{message}  
2017-01-11T11:03:05.160Z %{host} %{message}  
2017-01-11T11:03:05.160Z %{host} %{message}  
2017-01-11T11:03:05.160Z %{host} %{message}  
2017-01-11T11:03:05.160Z %{host} %{message}  
2017-01-11T11:03:05.160Z %{host} %{message}  
2017-01-11T11:03:05.160Z %{host} %{message}  
2017-01-11T11:03:05.160Z %{host} %{message}  
2017-01-11T11:03:05.160Z %{host} %{message}  
2017-01-11T11:03:05.160Z %{host} %{message}  
2017-01-11T11:03:05.160Z %{host} %{message}  
2017-01-11T11:03:05.160Z %{host} %{message}  
2017-01-11T11:03:05.160Z %{host} %{message}  
2017-01-11T11:03:05.160Z %{host} %{message}  
2017-01-11T11:03:05.160Z %{host} %{message}

How can i able to see my content?

---

<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:** [January 11, 2017, 12:58pm UTC](https://discuss.elastic.co/t/how-can-i-able-to-see-my-documents-content-using-logstash/71206/2 "2017-01-11T12:58:38Z")

</div>

Set e.g. `codec => rubydebug` for your stdout output.

---

<div class="post-metadata">

**Author:** ![Yaswanth](https://avatars.discourse-cdn.com/v4/letter/y/94ad74/32.png) [@Yaswanth](https://discuss.elastic.co/u/Yaswanth)\
**Post date:** [January 11, 2017, 1:39pm UTC](https://discuss.elastic.co/t/how-can-i-able-to-see-my-documents-content-using-logstash/71206/3 "2017-01-11T13:39:43Z")

</div>

thanks..  
The solution is working fine in my laptop. But when i use the rubydebug along with my documents contents timestamp,version etc are coming but i want only my document contents.  
1)Can you tell me how to achieve that?  
2)when i executed the same code in my PC it remains in Successfully started state without any output .May i know why this problem is coming?

---

<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:** [February 8, 2017, 1:39pm UTC](https://discuss.elastic.co/t/how-can-i-able-to-see-my-documents-content-using-logstash/71206/4 "2017-02-08T13:39:54Z")

</div>

Closed on February 8, 2017, 1:39pm UTC

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