I have a field called event_timestamp with format Thu Dec 09 15:02:66 IST 2021
I want to parse this format to default elastic acceptable format
I use date filter as below
date{
match => ["event_timestamp","EEE MMM dd HH:mm:ss zzz yyyy"]
}
what else I have to do still I am getting could not get index to Elasticsearch due to date field ca not parse error is there
The date filter does not parse named zone, you should change your match to the one shared in the previous answer.
date { match => ["event_timestamp", "EEE MMM dd HH:mm:ss 'IST' yyyy"] }
Also, you will need to specify your timezone to the filter and you can't use named timezone as well because they can be ambigous, in your case, IST can mean 3 completely different timezones, as explained in this another question
You will need something like this:
date {
match => ["event_timestamp", "EEE MMM dd HH:mm:ss 'IST' yyyy"]
timezone => "Asia/Kolkata"
}
Assuming that by IST, you mean India Standard Time, so you should use Asia/Kolkata as the 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.