Getting Data In

Include or clean incorrect timestamps

atown100
New Member

I have an application log that primarily has timestamps like the following:-

(14.2) 05-12-15 14:28:14 (.....

However sometimes, for certain events, the application misses off the last digit and we get this:-

(14.2) 05-12-15 14:28:1 (....

Obviously, Splunk splits up my events correctly when the timestamp is correct but merges events when the timestamp is wrong.

Is there any way to either;
a) exclude the text lines from the logs where the timestamp is wrong (we can probably live with this) before indexing, or
b) make Splunk use the incorrect timestamps as well, maybe appending a zero (0) onto them

Thanks for any assistance.
b/

Tags (2)
0 Karma

woodcock
Esteemed Legend

Make this a Heavy Forwarder and repair the events before they are indexed:
http://docs.splunk.com/Documentation/Splunk/5.0.4/Data/Anonymizedatausingconfigurationfiles#Through_...

Your entry should look like this:

[<spec>]
SEDCMD-FixTimestmapBeforeIndexing = s/\(:[0-9]\) /\10 /
0 Karma
Career Survey
First 500 qualified respondents will receive a $20 gift card! Tell us about your professional Splunk journey.

Can’t make it to .conf25? Join us online!

Get Updates on the Splunk Community!

Level Up Your .conf25: Splunk Arcade Comes to Boston

With .conf25 right around the corner in Boston, there’s a lot to look forward to — inspiring keynotes, ...

Manual Instrumentation with Splunk Observability Cloud: How to Instrument Frontend ...

Although it might seem daunting, as we’ve seen in this series, manual instrumentation can be straightforward ...

Take Action Automatically on Splunk Alerts with Red Hat Ansible Automation Platform

 Are you ready to revolutionize your IT operations? As digital transformation accelerates, the demand for ...