I have date_time = 1582225804228
which is Thursday, February 20, 2020 1:10:04.228
when I use following filter it convert that to 2020-02-20T19:10:04.228Z ( which is UTC) time format
But I also want another field created with it which represent CST = 2020-02-20T01:10
this is my code but it didn't work
-- Follwoing works- output to - 2020-02-20T19:10:04.228Z (UTC)
date { match => ["date_time", "UNIX_MS","ISO8601"]
target => "date_time"
}
-- This do not work what ever I do. it still print time in UTC i.e 19:10
date { match => ["date_time_timezone", "UNIX_MS","ISO8601"]
timezone => "CST6CDT"
target => "date_time_timezone"
}
I just did add following after ruby. that made that time exactly same as my local time.
and now I have two timestamp in index one is UTC one is local.
kibana I use UTC time
sql I use local time.
date { match => ["date_time_timezone", "yyyy-MM-dd HH:mm:ss"]
timezone => "Etc/UTC"
target => "date_time_timezone"
}
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.