Splunk Search

Unable to read date properly from a mysql-log file

pradeep6kumar
Engager

I have a file something like below:

140215  4:07:49 [Note] Plugin 'FEDERATED' is disabled.
140215  4:07:49  InnoDB: Initializing buffer pool, size = 8.0M
etc.

140215 id basically the date as 15thFeb2014 but splunk is not able to read the date instead , its reading everything as event, however it does able to read the time perfectly and showing timestamp as 3/25/14 4:07:49.000 AM and 3/25/14 4:07:49.000 AM respectively(here we can see the dates are incorrect but times are correct) for the two records. I have tried regular expressions to get the date correctly but its only highlighting the time part and not able to read the date part.If anyone knows how the handle such kinds of dates in splunk then please help.

Thanks

Tags (2)
0 Karma

richgalloway
SplunkTrust
SplunkTrust

Try adding "TIME_FORMAT=%y%m%d %k:%M:%S" to your props.conf file.

---
If this reply helps you, Karma would be appreciated.
0 Karma
Get Updates on the Splunk Community!

Threat Hunting Unlocked: How to Uplevel Your Threat Hunting With the PEAK Framework ...

WATCH NOWAs AI starts tackling low level alerts, it's more critical than ever to uplevel your threat hunting ...

Splunk APM: New Product Features + Community Office Hours Recap!

Howdy Splunk Community! Over the past few months, we’ve had a lot going on in the world of Splunk Application ...

Index This | Forward, I’m heavy; backward, I’m not. What am I?

April 2024 Edition Hayyy Splunk Education Enthusiasts and the Eternally Curious!  We’re back with another ...