# Winlogbeat -\> Logstash -\> JsonFile -\> Logstash -\> EL

**URL:** <https://discuss.elastic.co/t/winlogbeat-logstash-jsonfile-logstash-el/76012>\
**Category:** Logstash\
**Created:** [February 22, 2017, 10:06am UTC](https://discuss.elastic.co/t/winlogbeat-logstash-jsonfile-logstash-el/76012 "2017-02-22T10:06:43Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Alo](https://avatars.discourse-cdn.com/v4/letter/a/f04885/32.png) [@Alo](https://discuss.elastic.co/u/Alo)\
**Post date:** [February 22, 2017, 10:06am UTC](https://discuss.elastic.co/t/winlogbeat-logstash-jsonfile-logstash-el/76012/1 "2017-02-22T10:06:43Z")

</div>

Hi there:)

I'm having a scenario where we are grabbing Events via Winlogbeat which writes them to a RAID 1 NAS for backup reasons. Unfortunately we can't let winlogbeat write directly in EL.

first logstash cfg:  
input {  
beats {  
port =\> "5044"   
}  
}  
output {  
file {  
path =\> "Z://ea/ea\_log-%{+YYYY-MM-dd}.json"   
}  
}

After that, a second machine with logstash grabs them and tries to write them into EL.

second logstash cfg:  
input {  
file {  
path =\> "Z:/ea/ea\_log-\*.json"   
ignore\_older =\> 8640000  
start\_position =\> "beginning"   
codec =\> "json"   
}  
}

output {  
elasticsearch {  
hosts =\> ["localhost:9200"]  
index =\> "ea-%{+YYYY.MM.dd}"  
}  
}

So everything works fine and kibana sees a lot of entries.

BUT when it comes down to parse the "message" field we are experiencing \_jsonparsefailure.

I know that we forced this problem by setting the codec to JSON and the message field is plain text that comes from the events, but there must be a possibility to get the fields correctly to EL.

I already tried to use the winlogbeat\_template on my ea index but had no success.

I also played around with:  
json {  
source =\> "message"  
}  
in the logstash cfg, but i'm just not getting this thing parsed by EL ☹

Can someone help me out?  
Thanks in advance and excuse my english 🙂

---

<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 22, 2017, 10:06am UTC](https://discuss.elastic.co/t/winlogbeat-logstash-jsonfile-logstash-el/76012/2 "2017-03-22T10:06:53Z")

</div>

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