Getting Data In

How do I configure line breaking on the timestamp in my data?

tkwaller
Builder

Need to line break on timestamp in the following log record, but the underscore in the timestamp is throwing me off. Any help would be appreciated and thank you!

2015-07-28_09:51:02 INFO App=EXTRACT_HIT_DATA Message=::' Checking for backlog file/files to process '
2015-07-28_09:51:02 INFO App=EXTRACT_HIT_DATA Message=:' Number of backlog files : 48'
2015-07-28_09:51:02 INFO App=EXTRACT_HIT_DATA Message=:' Start processing all available backlog files '
2015-07-28_09:51:02 WARNING App=EXTRACT_HIT_DATA Message=:' File /nas/abc/myx/myarchive/omniture/feed/.../xyz.fin still not available, will try to process the file again during next run.'
2015-07-28_09:51:02 WARNING App=EXTRACT_HIT_DATA Message=:' File /nas/abc/myx/myarchive/omniture/feed/.../xyz.fin still not available, will try to process the file again during next run.'
2015-07-28_09:51:02 WARNING App=EXTRACT_HIT_DATA Message=:' File /nas/abc/myx/myarchive/omniture/feed/.../xyz.fin still not available, will try to process the file again during next run.'
Tags (2)
0 Karma
1 Solution

jnussbaum_splun
Splunk Employee
Splunk Employee

you'll want to create a props.conf file that sits with your inputs.conf file. - Change "yoursourcetype" to the sourcetype you've defined in inputs.conf
[yoursourcetype]
MAX_TIMESTAMP_LOOKAHEAD = 20
NO_BINARY_CHECK = true
SHOULD_LINEMERGE = false
TIME_FORMAT = %Y-%m-%d_%H:%M:%S
TIME_PREFIX = ^

View solution in original post

jnussbaum_splun
Splunk Employee
Splunk Employee

you'll want to create a props.conf file that sits with your inputs.conf file. - Change "yoursourcetype" to the sourcetype you've defined in inputs.conf
[yoursourcetype]
MAX_TIMESTAMP_LOOKAHEAD = 20
NO_BINARY_CHECK = true
SHOULD_LINEMERGE = false
TIME_FORMAT = %Y-%m-%d_%H:%M:%S
TIME_PREFIX = ^

tkwaller
Builder

Will that break at timestamp?
I think the lookahead and no linemerge would allow it to break properly is that correct?

0 Karma

wdsjon
Engager

Yep - Splunk will automatically break on the timestamp unless you manually define a line breaker.

0 Karma

bmacias84
Champion

Within your props.conf you need to specify the ** TIME_FORMAT**.

#props.conf
[mysource]
TIME_FORMAT =  < strptime >

Use this reference Configuretimestamprecognition

tkwaller
Builder

So what would that make LINE_BREAKER look like then or should I use it? Considering I need to break on timestamp.

0 Karma
Get Updates on the Splunk Community!

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

Take a look below to explore our upcoming Community Office Hours, Tech Talks, and Webinars this month. This ...

They're back! Join the SplunkTrust and MVP at .conf24

With our highly anticipated annual conference, .conf, comes the fez-wearers you can trust! The SplunkTrust, as ...

Enterprise Security Content Update (ESCU) | New Releases

Last month, the Splunk Threat Research Team had two releases of new security content via the Enterprise ...