<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Logging delay causes a line to get split in two. How to configure line breaking in Splunk to prevent this? in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/Logging-delay-causes-a-line-to-get-split-in-two-How-to-configure/m-p/253431#M48683</link>
    <description>&lt;P&gt;You need to increase your &lt;CODE&gt;TIME_BEFORE_CLOSE&lt;/CODE&gt; value in &lt;CODE&gt;inputs.conf&lt;/CODE&gt;:&lt;/P&gt;

&lt;P&gt;time_before_close = &lt;BR /&gt;
* Modtime delta required before Splunk can close a file on EOF.&lt;BR /&gt;
* Tells the system not to close files that have been updated in past  seconds.&lt;BR /&gt;
* Defaults to 3.&lt;/P&gt;</description>
    <pubDate>Tue, 29 Sep 2020 09:43:36 GMT</pubDate>
    <dc:creator>woodcock</dc:creator>
    <dc:date>2020-09-29T09:43:36Z</dc:date>
    <item>
      <title>Logging delay causes a line to get split in two. How to configure line breaking in Splunk to prevent this?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Logging-delay-causes-a-line-to-get-split-in-two-How-to-configure/m-p/253430#M48682</link>
      <description>&lt;P&gt;Hi, &lt;/P&gt;

&lt;P&gt;I'm trying to log Full GC events which look like this in the GC log:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;109897.407: [Full GC 109897.407: [CMS: 8807279K-&amp;gt;8606400K(31073920K), 11.1930580 secs] 9069543K-&amp;gt;8606400K(31418944K), [CMS Perm : 77354K-&amp;gt;77350K(262144K)], 11.1931520 secs] [Times: user=11.20 sys=0.00, real=11.19 secs] 
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;My props.conf has this stanza:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[sun_jvm]
SHOULD_LINEMERGE = false
DATETIME_CONFIG = CURRENT
BREAK_ONLY_BEFORE = ^\d+\.\d+:
category = Custom
disabled = false
pulldown_type = true
EXTRACT-file = (?P&amp;lt;service_name&amp;gt;[^\/\\]*)$ in source
EXTRACT-PAR = ^(?P&amp;lt;TIME_GC_TIMESTAMP&amp;gt;[^ ]*?)\s?(?P&amp;lt;relative_time&amp;gt;\d+\.\d+):\s\[GC.*\]\s(?P&amp;lt;before_gc&amp;gt;\d+)K-&amp;gt;(?P&amp;lt;after_gc&amp;gt;\d+)K\((?P&amp;lt;max_gc&amp;gt;\d+).*real=(?P&amp;lt;par_new_duration&amp;gt;\d+\.\d+)\s
EXTRACT-FGC = ^(?P&amp;lt;TIME_GC_TIMESTAMP&amp;gt;[^ ]*?)\s?(?P&amp;lt;relative_time&amp;gt;\d+\.\d+):\s\[Full GC.*\]\s(?P&amp;lt;before_gc&amp;gt;\d+)K-&amp;gt;(?P&amp;lt;after_gc&amp;gt;\d+)K\((?P&amp;lt;max_gc&amp;gt;\d+)K.*\s(?P&amp;lt;full_gc_duration&amp;gt;\d+\.\d+) secs\]
EXTRACT-CMS = ^(?P&amp;lt;TIME_GC_TIMESTAMP&amp;gt;[^ ]*?)\s?(?P&amp;lt;relative_time&amp;gt;\d+\.\d+):\s\[CMS-concurrent-sweep:\s.*real=(?P&amp;lt;cms_duration&amp;gt;\d+\.\d+)\s
EXTRACT-CMS-MARK = ^(?P&amp;lt;TIME_GC_TIMESTAMP&amp;gt;[^ ]*?)\s?(?P&amp;lt;relative_time&amp;gt;\d+\.\d+):\s.*\[1\sCMS-initial-mark:[^,]+,\s(?P&amp;lt;cms_init_mark_duration&amp;gt;\d+\.\d+) secs\]
EXTRACT-CMS-REMARK = ^(?P&amp;lt;TIME_GC_TIMESTAMP&amp;gt;[^ ]*?)\s?(?P&amp;lt;relative_time&amp;gt;\d+\.\d+):\s.*\[1\sCMS-remark:[^,]+,\s(?P&amp;lt;cms_remark_duration&amp;gt;\d+\.\d+) secs\]
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;This works for quick GCs, but sometimes the GC takes a bit of time, so the first part of the line comes a few seconds before the rest. Namely, this appears first:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;109897.407: [Full GC 109897.407: [CMS
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Then a few seconds later it gets finished.&lt;/P&gt;

&lt;P&gt;The trouble is, Splunk interprets this first bit as an event in its own right, and then puts the rest in a second event:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;: 8807279K-&amp;gt;8606400K(31073920K), 11.1930580 secs] 9069543K-&amp;gt;8606400K(31418944K), [CMS Perm : 77354K-&amp;gt;77350K(262144K)], 11.1931520 secs] [Times: user=11.20 sys=0.00, real=11.19 secs]
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;This screws up my graph, because it's no longer recognized as a Full GC.&lt;/P&gt;

&lt;P&gt;Is there any way to tell Splunk to wait until the whole line has been written?&lt;/P&gt;

&lt;P&gt;Thanks!&lt;BR /&gt;
John&lt;/P&gt;</description>
      <pubDate>Wed, 18 May 2016 16:12:31 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Logging-delay-causes-a-line-to-get-split-in-two-How-to-configure/m-p/253430#M48682</guid>
      <dc:creator>johnraftery</dc:creator>
      <dc:date>2016-05-18T16:12:31Z</dc:date>
    </item>
    <item>
      <title>Re: Logging delay causes a line to get split in two. How to configure line breaking in Splunk to prevent this?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Logging-delay-causes-a-line-to-get-split-in-two-How-to-configure/m-p/253431#M48683</link>
      <description>&lt;P&gt;You need to increase your &lt;CODE&gt;TIME_BEFORE_CLOSE&lt;/CODE&gt; value in &lt;CODE&gt;inputs.conf&lt;/CODE&gt;:&lt;/P&gt;

&lt;P&gt;time_before_close = &lt;BR /&gt;
* Modtime delta required before Splunk can close a file on EOF.&lt;BR /&gt;
* Tells the system not to close files that have been updated in past  seconds.&lt;BR /&gt;
* Defaults to 3.&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 09:43:36 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Logging-delay-causes-a-line-to-get-split-in-two-How-to-configure/m-p/253431#M48683</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2020-09-29T09:43:36Z</dc:date>
    </item>
    <item>
      <title>Re: Logging delay causes a line to get split in two. How to configure line breaking in Splunk to prevent this?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Logging-delay-causes-a-line-to-get-split-in-two-How-to-configure/m-p/253432#M48684</link>
      <description>&lt;P&gt;Ok, so I should modify the stanza in inputs.conf like this?&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[monitor://PERF_TEST/logs/.../*]
disabled = false
host = PHASE4 
index = mlc_live
sourcetype = sun_jvm
whitelist = .*gc\.log$
time_before_close = 15
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 19 May 2016 08:22:16 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Logging-delay-causes-a-line-to-get-split-in-two-How-to-configure/m-p/253432#M48684</guid>
      <dc:creator>johnraftery</dc:creator>
      <dc:date>2016-05-19T08:22:16Z</dc:date>
    </item>
    <item>
      <title>Re: Logging delay causes a line to get split in two. How to configure line breaking in Splunk to prevent this?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Logging-delay-causes-a-line-to-get-split-in-two-How-to-configure/m-p/253433#M48685</link>
      <description>&lt;P&gt;Seems to have done the trick, thanks very much!&lt;/P&gt;</description>
      <pubDate>Thu, 19 May 2016 10:29:12 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Logging-delay-causes-a-line-to-get-split-in-two-How-to-configure/m-p/253433#M48685</guid>
      <dc:creator>johnraftery</dc:creator>
      <dc:date>2016-05-19T10:29:12Z</dc:date>
    </item>
  </channel>
</rss>

