Getting Data In

How to edit props.conf for proper line breaking of a log file that does not have YYYY-MM-DD in the timestamp?

mbksplunk
Explorer

Events are not breaking up correctly for this particular log file that does not have YYYY-MM-DD in the timestamp. Here is the log from one of the apsp that was not so greatly written. I say this because the log does not have YYYY-MM-DD as part of the timestamp.

Log file:

16:35:34,985 INFO  604682869 [  FailureHandlerBean] Scena startTime=Wed Oct 19 16:35:25 EST 2016]
16:35:34,988 INFO  604682869 [         LockHandler] Invalidated lock Tool.
16:35:34,998 INFO  604682869 [      PFMInterceptor] Executed in Engine 9313ms
16:35:35,002 INFO  604681893 [     JmsQueueMonitor] Current message count in EventQueue: 34

props.conf

[server_log]
NO_BINARY_CHECK = 1
SHOULD_LINEMERGE = false
LINE_BREAKER = ([\r\n]+)\d{2}:\d{2}:\d{2},\d{3}
pulldown_type = 1

Any idea? Thanks in advance.

0 Karma

ibob0304
Communicator

Try this

[server_log]
NO_BINARY_CHECK = 1
pulldown_type = 1
BREAK_ONLY_BEFORE = \d{2}\:\d{2}\:\d{2}\,\d{3}
SHOULD_LINEMERGE = true
0 Karma

lguinn2
Legend

If each line of the file is a separate event, you do not need the LINE_BREAKER at all. For log files containing single-line events, SHOULD_LINEMERGE = false is all you need.

Get Updates on the Splunk Community!

Introducing the Splunk Community Dashboard Challenge!

Welcome to Splunk Community Dashboard Challenge! This is your chance to showcase your skills in creating ...

Built-in Service Level Objectives Management to Bridge the Gap Between Service & ...

Wednesday, May 29, 2024  |  11AM PST / 2PM ESTRegister now and join us to learn more about how you can ...

Get Your Exclusive Splunk Certified Cybersecurity Defense Engineer Certification at ...

We’re excited to announce a new Splunk certification exam being released at .conf24! If you’re headed to Vegas ...