Getting Data In

Splunk automatically splits a event into two, because of two dates

sre_sl
New Member

Hi All

I tried a solution suggested online for a similar issue, but it didn't fix the problem

The below extract from the log is a single event

 2019-03-26 12:03:28.753 +0000 INFO  [zzz] [yyy] [] [] [rrId:] []  Message
----------------------------
ID: 7
Response-Code: 200
Encoding: UTF-8
Content-Type: text/xml;charset=utf-8
Headers: {Connection=[close], Content-Type=[text/xml;charset=utf-8], Date=[Tue, 26 Mar 2019 12:03:28 GMT],
Show less

but it results like this

 2019-03-26 12:03:28.753 +0000 INFO  [zzz] [yyy] [] [] [rrId:] []  Message
 ----------------------------
 ID: 7
 Response-Code: 200
 Encoding: UTF-8
 Content-Type: text/xml;charset=utf-8

In 2 lines

Headers: {Connection=[close], Content-Type=[text/xml;charset=utf-8], Date=[Tue, 26 Mar 2019 12:03:28 GMT],
         Show less

We have a cluster environment so I updated the props here - opt/splunk/etc/master-apps/_cluster/local/props.conf with the below
[log4j]

MAX_TIMESTAMP_LOOKAHEAD = 19

I pushed the change to the peers and restarted all the indexers

Any thoughts to fix this issue please?

Thanks

0 Karma
1 Solution

somesoni2
Revered Legend

Try this for your props.conf (sourcetype definition)

[log4j]
SHOULD_LINEMBER=false
LINE_BREAKER=([\r\n]+)(?=\d{4}-\d{2}-\d{2})
TIME_PREFIX=^
TIME_FORMAT=%Y-%m-%d %H:%M:%S.%3N %z
MAX_TIMESTAMP_LOOKAHEAD=29

View solution in original post

0 Karma

somesoni2
Revered Legend

Try this for your props.conf (sourcetype definition)

[log4j]
SHOULD_LINEMBER=false
LINE_BREAKER=([\r\n]+)(?=\d{4}-\d{2}-\d{2})
TIME_PREFIX=^
TIME_FORMAT=%Y-%m-%d %H:%M:%S.%3N %z
MAX_TIMESTAMP_LOOKAHEAD=29
0 Karma

sre_sl
New Member

Thanks.

It works partially but creates another issue.

The below shows as one event

2019-04-08 09:51:11.791 +0000 INFO   INFO  [[zzz] [yyy] [] [] [rrId:] []  Message In
----------------------------
ID: 3
Response-Code: 200
Encoding: UTF-8
Content-Type: text/xml;charset=utf-8
Headers: {Connection=[close], Content-Type=[text/xml;charset=utf-8], Date=[Mon, 08 Apr 2019 09:51:11 GMT]

But what happens is the next message is also in the same event, which should be a separate event

2019-04-08 09:51:11.727 +0000 INFO [[zzz] [yyy] [] [] [rrId:] []  Message Out

ID: 3
Address: xxxx
Encoding: UTF-8
Http-Method: POST
Content-Type: text/xml
Headers: {Accept=[/], Connection=[close], SOAPAction=[""]}

2019-04-08 09:51:11.791 +0000 INFO INFO [[zzz] [yyy] [] [] [rrId:] []  Message In

ID: 3
Response-Code: 200
Encoding: UTF-8
Content-Type: text/xml;charset=utf-8
Headers: {Connection=[close], Content-Type=[text/xml;charset=utf-8], Date=[Mon, 08 Apr 2019 09:51:11 GMT]

0 Karma

somesoni2
Revered Legend

Give this a try

[log4j]
 SHOULD_LINEMBER=false
 LINE_BREAKER=([\r\n]+)(?=\s*\d{4}-\d{2}-\d{2}\s*\d+)
 TIME_PREFIX=^
 TIME_FORMAT=%Y-%m-%d %H:%M:%S.%3N %z
 MAX_TIMESTAMP_LOOKAHEAD=29
0 Karma
Got questions? Get answers!

Join the Splunk Community Slack to learn, troubleshoot, and make connections with fellow Splunk practitioners in real time!

Meet up IRL or virtually!

Join Splunk User Groups to connect and learn in-person by region or remotely by topic or industry.

Get Updates on the Splunk Community!

SOK it to Me: Top 3 Benefits of Using Splunk Operator on Kubernetes that’ll Make ...

    Thursday, July 9, 2026  |  11:00AM–12:00PM PDT Duration: 1 hour (includes Q&A) Managing can feel like a ...

Upgrade Prep for 10.4, Network Observability Deep Dives, and More from Splunk Lantern

Splunk Lantern is Splunk’s customer success center that provides practical guidance from Splunk experts on key ...

Splunk Developer Day announcements: AI agents, MCP tools, Forecasting, and Custom ...

Splunk Developer Day was packed with product and platform updates for developers building in the AI ...