<?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: Best methods for handling large events and multi-line parsing issue? in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/Best-methods-for-handling-large-events-and-multi-line-parsing/m-p/173565#M34926</link>
    <description>&lt;P&gt;The event is packed with hundreds of metrics that would be useful, and most of these metric descriptions are uniquely defined on a single line.. The example I provided is one of the more complex problems I've come across..  I've been able to extract this using a perl parse by capturing the various headers, concatenating them and then testing for a match using a "next unless" expression.  I'm just trying to figure out what the best method for doing this type of evaluation might be using Splunk.  I'm new to product.&lt;/P&gt;</description>
    <pubDate>Wed, 06 Aug 2014 21:34:25 GMT</pubDate>
    <dc:creator>ekrieser</dc:creator>
    <dc:date>2014-08-06T21:34:25Z</dc:date>
    <item>
      <title>Best methods for handling large events and multi-line parsing issue?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Best-methods-for-handling-large-events-and-multi-line-parsing/m-p/173563#M34924</link>
      <description>&lt;P&gt;This is two part question that deals with isolating metric data within a multi-line event where the metric identifier strings may be broken down into 2 different sections of a data sheet (log file)&lt;/P&gt;

&lt;P&gt;The Log&lt;/P&gt;

&lt;P&gt;The log file format includes a date/time stamp at the top of an event generation and procedes to dump information on the application in lines&lt;/P&gt;

&lt;P&gt;A single event can exceed 23 k lines and 700 k chars.  Here's a log with an isolated single event..&lt;/P&gt;

&lt;P&gt;(FYI, this a health.log dump from an HP NNMi management server)&lt;/P&gt;

&lt;P&gt;$wc -cl health.log&lt;/P&gt;

&lt;P&gt;23518  700343 health.log&lt;/P&gt;

&lt;P&gt;Here's a mock up of the problem.&lt;/P&gt;

&lt;HR /&gt;

&lt;P&gt;2014-06-17 10:22:13,795 INFO  &lt;A href="https://community.splunk.com/pool-1-thread-39"&gt;com.hp.ov.nms.health.log&lt;/A&gt; NNMi System Health Report&lt;BR /&gt;
  Hostname: somehost.com&lt;/P&gt;

&lt;P&gt;Date: 2014-06-17 10:22:11.572&lt;/P&gt;

&lt;P&gt;Overall Status: Normal&lt;/P&gt;

&lt;P&gt;StatePoller&lt;/P&gt;

&lt;P&gt;Collection Manager&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;Policy Count = 523
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;....&lt;/P&gt;

&lt;P&gt;CustomPoller&lt;/P&gt;

&lt;P&gt;Instance Discovery&lt;/P&gt;

&lt;P&gt;Collection Manager&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;Policy Count = 23
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;...&lt;/P&gt;

&lt;HR /&gt;

&lt;P&gt;Part 1) Large Event Issue&lt;/P&gt;

&lt;P&gt;I found in a post on the forum that you can modify the inputs.conf file with a 'maxchars' value so the events don't get cut.  Is this the best way to handle this, or would it be better to hack up the event?  My concern here is that an event is never guaranteed to be the same size and will almost always vary.&lt;/P&gt;

&lt;P&gt;Part 2) Multi-line Parsing Issue&lt;/P&gt;

&lt;P&gt;As you can see in the snippet above there are preceding headers that identify the metrics I'm trying to extract.  These headers are not contiguous and may, or may not have additional sub headers as identified above.&lt;/P&gt;

&lt;P&gt;StatePoller → Collection Manager → Policy Count&lt;/P&gt;

&lt;P&gt;CustomPoller→ Instance Discovery&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;              → Collection Manger → Policy Count
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;I'm trying to understand what the best method for parsing out these different method would be.&lt;/P&gt;

&lt;P&gt;Please let me know if I can provide any further detail.. I can send a sample log if needed.&lt;/P&gt;

&lt;P&gt;Thanks&lt;/P&gt;

&lt;P&gt;Eric&lt;/P&gt;</description>
      <pubDate>Wed, 06 Aug 2014 20:58:51 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Best-methods-for-handling-large-events-and-multi-line-parsing/m-p/173563#M34924</guid>
      <dc:creator>ekrieser</dc:creator>
      <dc:date>2014-08-06T20:58:51Z</dc:date>
    </item>
    <item>
      <title>Re: Best methods for handling large events and multi-line parsing issue?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Best-methods-for-handling-large-events-and-multi-line-parsing/m-p/173564#M34925</link>
      <description>&lt;P&gt;The values for allowing very large events are in props.conf:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;TRUNCATE = max length of an event (default 10000)
MAX_EVENTS = max lines in an event (default 256)
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;As for parsing your data, you'll likely need more or less complex regular expressions.&lt;BR /&gt;
Do you only need a few values from that large event, or do you need the entire event in Splunk?&lt;/P&gt;</description>
      <pubDate>Wed, 06 Aug 2014 21:22:50 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Best-methods-for-handling-large-events-and-multi-line-parsing/m-p/173564#M34925</guid>
      <dc:creator>martin_mueller</dc:creator>
      <dc:date>2014-08-06T21:22:50Z</dc:date>
    </item>
    <item>
      <title>Re: Best methods for handling large events and multi-line parsing issue?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Best-methods-for-handling-large-events-and-multi-line-parsing/m-p/173565#M34926</link>
      <description>&lt;P&gt;The event is packed with hundreds of metrics that would be useful, and most of these metric descriptions are uniquely defined on a single line.. The example I provided is one of the more complex problems I've come across..  I've been able to extract this using a perl parse by capturing the various headers, concatenating them and then testing for a match using a "next unless" expression.  I'm just trying to figure out what the best method for doing this type of evaluation might be using Splunk.  I'm new to product.&lt;/P&gt;</description>
      <pubDate>Wed, 06 Aug 2014 21:34:25 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Best-methods-for-handling-large-events-and-multi-line-parsing/m-p/173565#M34926</guid>
      <dc:creator>ekrieser</dc:creator>
      <dc:date>2014-08-06T21:34:25Z</dc:date>
    </item>
    <item>
      <title>Re: Best methods for handling large events and multi-line parsing issue?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Best-methods-for-handling-large-events-and-multi-line-parsing/m-p/173566#M34927</link>
      <description>&lt;P&gt;You can use line breaks within a field extraction regex, e.g. like this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;CustomPoller[\n\r]+Instance Discovery[\n\r]+Collection Manager[\n\r]+Policy Count = (?&amp;lt;fieldname&amp;gt;\d+)
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 07 Aug 2014 21:22:29 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Best-methods-for-handling-large-events-and-multi-line-parsing/m-p/173566#M34927</guid>
      <dc:creator>martin_mueller</dc:creator>
      <dc:date>2014-08-07T21:22:29Z</dc:date>
    </item>
    <item>
      <title>Re: Best methods for handling large events and multi-line parsing issue?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Best-methods-for-handling-large-events-and-multi-line-parsing/m-p/173567#M34928</link>
      <description>&lt;P&gt;Thanks Martin.  I think that's what I'm looking for.&lt;/P&gt;</description>
      <pubDate>Fri, 08 Aug 2014 22:16:30 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Best-methods-for-handling-large-events-and-multi-line-parsing/m-p/173567#M34928</guid>
      <dc:creator>ekrieser</dc:creator>
      <dc:date>2014-08-08T22:16:30Z</dc:date>
    </item>
    <item>
      <title>Re: Best methods for handling large events and multi-line parsing issue?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Best-methods-for-handling-large-events-and-multi-line-parsing/m-p/173568#M34929</link>
      <description>&lt;P&gt;Great. I've converted this into an answer so you can mark it as solved.&lt;/P&gt;</description>
      <pubDate>Sat, 09 Aug 2014 08:20:00 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Best-methods-for-handling-large-events-and-multi-line-parsing/m-p/173568#M34929</guid>
      <dc:creator>martin_mueller</dc:creator>
      <dc:date>2014-08-09T08:20:00Z</dc:date>
    </item>
  </channel>
</rss>

