Splunk Search

How can I handle a time stamp with flexible spaces?

ddrillic
Ultra Champion

We have a syslog data that was written to disk via the FULLDATE macro. For today, it looks like — 2019 Apr 3 19:30:01 with double space. I assume that it would be 2019 Apr 13 19:30:01 in ten days with only one space.

I wonder which format to use in props.conf -

TIME_FORMAT=%Y %b %d %H:%M:%S works fine for 2019 Apr 3 19:30:01 but not for 2019 Apr 13 19:30:01, which is counter intuitive to me.

On Unix, I see -

date "+%Y %b %d %H:%M:%S" as 2019 Apr 03 15:45:41. Apparently space and zero are interchangeable.

Any ideas?

Tags (2)
0 Karma

ddrillic
Ultra Champion

This warning threw me off ; -)alt text

0 Karma

ddrillic
Ultra Champion

It seems that it was my bad - it works just fine.

0 Karma
Get Updates on the Splunk Community!

Community Content Calendar, November Edition

Welcome to the November edition of our Community Spotlight! Each month, we dive into the Splunk Community to ...

October Community Champions: A Shoutout to Our Contributors!

As October comes to a close, we want to take a moment to celebrate the people who make the Splunk Community ...

Stay Connected: Your Guide to November Tech Talks, Office Hours, and Webinars!

What are Community Office Hours? Community Office Hours is an interactive 60-minute Zoom series where ...