Hello all, I'm new to log stash and probably this is a simple mistake on my part. I have a pile of old apache combined logs I want to put into elasticsearch, using logstash. I found that logstash was was not properly translating the date field into @timestamp.
I think I have a very basic filter setup:
grok { match => { "message" => "%{COMBINEDAPACHELOG}" } }
date { match => [ "timestamp" , "dd/MMM/yyyy:HH:mm:ss Z" ] }
geoip { source => "clientip" }
useragent { source => "agent" }
However the output of @timestamp doesn't make any sense to me. For an input like [30/Aug/2015:21:44:25 -0500] I get the following out:
"@timestamp" => "2015-08-31T02:44:25.000Z",
"timestamp" => "30/Aug/2015:21:44:25 -0500",
Looks like a timezone offset problem somewhere, but I haven't figure out where. The original log is printed in central US time, my log stash is in US eastern time. I tried using the date{} "locale" and "timezone" fields, setting TZ shell variable. I verified my server (CentOS) is properly set to US/New_York.
Any thoughts? I'd like @timestamp to match exactly the apache log date ... or worst case have it be 1hr offset between eastern and central time.
thanks,