Logstash filter for json is not using jason file date

Hi All ,

I am uploading log from a json file . Logstash filter is working . But the same time 2 times log is uploading to elasticsearch , with log date and current date .

example :

jason log

{"index": {"_index":"server-metrics","_type":"metric","_id":"680464"}}
{"index": {"_index":"server-metrics","_type":"metric","_id":"680465"}}

Logstash filter

file {
start_position => "beginning"
path => "/home/elastic/elk/samplelog/server-metrics_4.json"
codec => "json"
type => "json"
output { stdout{ codec => rubydebug }
elasticsearch { hosts => [""]

Log is indexed to both at date "2017-04-15T00:07:00" and current date 9/1/2018

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