<?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: Problem using multikv to parse tabular data in Monitoring Splunk</title>
    <link>https://community.splunk.com/t5/Monitoring-Splunk/Problem-using-multikv-to-parse-tabular-data/m-p/97933#M7455</link>
    <description>&lt;P&gt;Tested in v6.0.  &lt;/P&gt;

&lt;P&gt;multkv.conf is annoying. &lt;BR /&gt;
It is acting funny. We cannot trust the spec file.... sad. Examples do not work....&lt;/P&gt;

&lt;P&gt;Solution 1. Forget about multikv.conf and use general Field Extraction&lt;/P&gt;

&lt;UL&gt;
&lt;LI&gt;&lt;P&gt;props.conf&lt;/P&gt;

&lt;P&gt;[source::.../Log/test_multikv_table.log]&lt;BR /&gt;
REPORT-multikv = test_multikv_table_1 test_multikv_table_2&lt;/P&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;P&gt;transforms.conf&lt;/P&gt;

&lt;P&gt;[test_multikv_table_1]&lt;BR /&gt;
REGEX = ^((\d+)\s+(\S+)\s+(\S+)\s+(\S+)\s+(\S+)\s+(\S+)\s+(\S+))&lt;BR /&gt;
FORMAT = Row::$1 objectID::$2 volume::$3 aggregate::$4 storageServer::$5 dailyGrowthRate::$6 daysToFull::$7 growthRate::$8&lt;BR /&gt;
MV_ADD = true&lt;/P&gt;

&lt;P&gt;[test_multikv_table_2]&lt;BR /&gt;
REGEX = ^Totals\s+(\S+)&lt;BR /&gt;
FORMAT = Totals::$1&lt;/P&gt;&lt;/LI&gt;
&lt;/UL&gt;

&lt;P&gt;Solution 2. Stick with buggy multikv.conf&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;# Put multikv.conf in all of Splunk instance (Search Head and Peers)
- props.conf
[source::.../Log/test_multikv_table.log]
LINE_BREAKER = ([\n\r]+)Object ID
SHOULD_LINEMERGE = false
DATETIME_CONFIG  = CURRENT
KV_MODE = multi_volumeGrowthRates
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;UL&gt;
&lt;LI&gt;&lt;P&gt;multikv.conf &lt;/P&gt;

&lt;H1&gt;Bug: must be located in Search Peer's local directory, instead of bundle from SH&lt;/H1&gt;

&lt;P&gt;[volumeGrowthRates]&lt;/P&gt;

&lt;H1&gt;Not sure if "pre" is working&lt;/H1&gt;

&lt;P&gt;pre.start = "Object"&lt;BR /&gt;
pre.end = "----.*"&lt;/P&gt;

&lt;H1&gt;pre.linecount = 2&lt;/H1&gt;

&lt;P&gt;pre.ignore = &lt;EM&gt;all&lt;/EM&gt;&lt;/P&gt;

&lt;H1&gt;header setting&lt;/H1&gt;

&lt;P&gt;header.tokens = &lt;EM&gt;token_list&lt;/EM&gt;,"ObjectId","Volume","Aggregate","StorageServer","DailyGrowthRate","DaysToFull","DailyGrowthRatePct"&lt;/P&gt;

&lt;H1&gt;Body needs to set ignoring pre and post lines&lt;/H1&gt;

&lt;P&gt;body.tokens = &lt;EM&gt;tokenize&lt;/EM&gt;, 0, " "&lt;BR /&gt;
body.ignore = &lt;EM&gt;regex&lt;/EM&gt; "----|Totals"&lt;/P&gt;

&lt;H1&gt;Post... ignore is not working???&lt;/H1&gt;

&lt;P&gt;post.start = "Totals"&lt;BR /&gt;
post.linecount = 1&lt;BR /&gt;
post.ignore = &lt;EM&gt;all&lt;/EM&gt;&lt;/P&gt;&lt;/LI&gt;
&lt;/UL&gt;</description>
    <pubDate>Mon, 28 Sep 2020 15:50:10 GMT</pubDate>
    <dc:creator>Masa</dc:creator>
    <dc:date>2020-09-28T15:50:10Z</dc:date>
    <item>
      <title>Problem using multikv to parse tabular data</title>
      <link>https://community.splunk.com/t5/Monitoring-Splunk/Problem-using-multikv-to-parse-tabular-data/m-p/97932#M7454</link>
      <description>&lt;P&gt;Hello!&lt;/P&gt;

&lt;P&gt;I'm trying to create a custom multikv.conf stanza for the first time, and am having trouble getting it working.  Here is an example of the events I'm working with:&lt;/P&gt;

&lt;PRE&gt;
Object ID Volume                    Aggregate     Storage Server          Daily Growth Rate   Days To Full Daily Growth Rate (%)
--------- ------------------------- ------------- ----------------------  ------------------- ------------ ---------------------
36906     volume_1                  aggr1_vmw_sas nas-vmw-prod02.foo.com           1074009984            1                  10.0
25031     volume_2                  aggr2_vmw_sas nas-vmw-prod03.foo.com             29670000           75                   0.6
25033     volume_3                  aggr2_vmw_sas nas-vmw-prod03.foo.com             23464000          146                   0.4
5430      volume_4                  aggr1_vmw_sas nas-vmw-prod02.foo.com             22181400          273                   0.3
Totals                                                                             1249102095&lt;/PRE&gt;

The multikv.conf stanza I created is as follows:

&lt;PRE&gt;[volume_growth_rates]

#ignore the first two lines, as getting proper tokens with the spaces and % will be problematic
pre.start = "Object"
pre.linecount = 2
pre.ignore = _all_

#Manually define the header tokens
header.tokens = _token_list_, ObjectId, Volume, Aggregate, StorageServer, DailyGrowthRate, DaysToFull, DailyGrowthRatePct

#tokenize with space separators
body.end = "Totals"
body.tokens = _tokenize_, 0, " "

#ignore the 'Totals' line, as it doesn't really contain useful data.
post.start = "Totals"
post.linecount = 1
post.ignore = _all_
&lt;/PRE&gt;

&lt;P&gt;When I try to use this in search, nothing happens.  Trying both:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;... | multikv
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;and&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;... | multkv conf=volume_growth_rates
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Any ideas on what I'm missing here?&lt;/P&gt;

&lt;P&gt;Thanks!&lt;/P&gt;</description>
      <pubDate>Mon, 14 Oct 2013 20:32:17 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Monitoring-Splunk/Problem-using-multikv-to-parse-tabular-data/m-p/97932#M7454</guid>
      <dc:creator>emiller42</dc:creator>
      <dc:date>2013-10-14T20:32:17Z</dc:date>
    </item>
    <item>
      <title>Re: Problem using multikv to parse tabular data</title>
      <link>https://community.splunk.com/t5/Monitoring-Splunk/Problem-using-multikv-to-parse-tabular-data/m-p/97933#M7455</link>
      <description>&lt;P&gt;Tested in v6.0.  &lt;/P&gt;

&lt;P&gt;multkv.conf is annoying. &lt;BR /&gt;
It is acting funny. We cannot trust the spec file.... sad. Examples do not work....&lt;/P&gt;

&lt;P&gt;Solution 1. Forget about multikv.conf and use general Field Extraction&lt;/P&gt;

&lt;UL&gt;
&lt;LI&gt;&lt;P&gt;props.conf&lt;/P&gt;

&lt;P&gt;[source::.../Log/test_multikv_table.log]&lt;BR /&gt;
REPORT-multikv = test_multikv_table_1 test_multikv_table_2&lt;/P&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;P&gt;transforms.conf&lt;/P&gt;

&lt;P&gt;[test_multikv_table_1]&lt;BR /&gt;
REGEX = ^((\d+)\s+(\S+)\s+(\S+)\s+(\S+)\s+(\S+)\s+(\S+)\s+(\S+))&lt;BR /&gt;
FORMAT = Row::$1 objectID::$2 volume::$3 aggregate::$4 storageServer::$5 dailyGrowthRate::$6 daysToFull::$7 growthRate::$8&lt;BR /&gt;
MV_ADD = true&lt;/P&gt;

&lt;P&gt;[test_multikv_table_2]&lt;BR /&gt;
REGEX = ^Totals\s+(\S+)&lt;BR /&gt;
FORMAT = Totals::$1&lt;/P&gt;&lt;/LI&gt;
&lt;/UL&gt;

&lt;P&gt;Solution 2. Stick with buggy multikv.conf&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;# Put multikv.conf in all of Splunk instance (Search Head and Peers)
- props.conf
[source::.../Log/test_multikv_table.log]
LINE_BREAKER = ([\n\r]+)Object ID
SHOULD_LINEMERGE = false
DATETIME_CONFIG  = CURRENT
KV_MODE = multi_volumeGrowthRates
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;UL&gt;
&lt;LI&gt;&lt;P&gt;multikv.conf &lt;/P&gt;

&lt;H1&gt;Bug: must be located in Search Peer's local directory, instead of bundle from SH&lt;/H1&gt;

&lt;P&gt;[volumeGrowthRates]&lt;/P&gt;

&lt;H1&gt;Not sure if "pre" is working&lt;/H1&gt;

&lt;P&gt;pre.start = "Object"&lt;BR /&gt;
pre.end = "----.*"&lt;/P&gt;

&lt;H1&gt;pre.linecount = 2&lt;/H1&gt;

&lt;P&gt;pre.ignore = &lt;EM&gt;all&lt;/EM&gt;&lt;/P&gt;

&lt;H1&gt;header setting&lt;/H1&gt;

&lt;P&gt;header.tokens = &lt;EM&gt;token_list&lt;/EM&gt;,"ObjectId","Volume","Aggregate","StorageServer","DailyGrowthRate","DaysToFull","DailyGrowthRatePct"&lt;/P&gt;

&lt;H1&gt;Body needs to set ignoring pre and post lines&lt;/H1&gt;

&lt;P&gt;body.tokens = &lt;EM&gt;tokenize&lt;/EM&gt;, 0, " "&lt;BR /&gt;
body.ignore = &lt;EM&gt;regex&lt;/EM&gt; "----|Totals"&lt;/P&gt;

&lt;H1&gt;Post... ignore is not working???&lt;/H1&gt;

&lt;P&gt;post.start = "Totals"&lt;BR /&gt;
post.linecount = 1&lt;BR /&gt;
post.ignore = &lt;EM&gt;all&lt;/EM&gt;&lt;/P&gt;&lt;/LI&gt;
&lt;/UL&gt;</description>
      <pubDate>Mon, 28 Sep 2020 15:50:10 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Monitoring-Splunk/Problem-using-multikv-to-parse-tabular-data/m-p/97933#M7455</guid>
      <dc:creator>Masa</dc:creator>
      <dc:date>2020-09-28T15:50:10Z</dc:date>
    </item>
    <item>
      <title>Re: Problem using multikv to parse tabular data</title>
      <link>https://community.splunk.com/t5/Monitoring-Splunk/Problem-using-multikv-to-parse-tabular-data/m-p/97934#M7456</link>
      <description>&lt;P&gt;Maybe it is issue with identifying the header?&lt;/P&gt;

&lt;P&gt;How does SPLUNk know when to ignore the header here?&lt;/P&gt;

&lt;P&gt;example with the manual approach of assigning headers, we specify start of header &amp;amp; linecount:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;# specify table header location and processing 
header.start = "Object ID" 
header.linecount = 1 
header.tokens = _tokenize_, -1," "
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 03 Aug 2015 10:00:36 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Monitoring-Splunk/Problem-using-multikv-to-parse-tabular-data/m-p/97934#M7456</guid>
      <dc:creator>stanwin</dc:creator>
      <dc:date>2015-08-03T10:00:36Z</dc:date>
    </item>
  </channel>
</rss>

