<?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 extracting field from a field in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Problem-extracting-field-from-a-field/m-p/156109#M43931</link>
    <description>&lt;P&gt;Thank you, changing the class name did the trick.&lt;/P&gt;</description>
    <pubDate>Thu, 11 Dec 2014 15:21:22 GMT</pubDate>
    <dc:creator>chengka</dc:creator>
    <dc:date>2014-12-11T15:21:22Z</dc:date>
    <item>
      <title>Problem extracting field from a field</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Problem-extracting-field-from-a-field/m-p/156103#M43925</link>
      <description>&lt;P&gt;Splunk 6.2&lt;BR /&gt;
I used the Field Extractor app to extract a field from an previous field.  The resulting extraction tested perfectly from with the app.  Here is an excerpt from the sourcetype stanza of props.conf.&lt;/P&gt;

&lt;P&gt;EXTRACT-ErrorMessageText = (?ims)^\w+.+AMQ\d\d\d\d:(?P.+)EXPLANATION&lt;BR /&gt;
EXTRACT-ErrorMessageChannel = [cC]hannel[\s']+(?P[\w\d.]+) in ErrorMessageText&lt;/P&gt;

&lt;P&gt;The problem is the field ErrorMessageChannel field never appears in the field list for an event.  The 6.2 field extractor does not even list it as an Existing Field (ErrorMessageText is listed).  The new field IS listed in the Settings Field Extractions. &lt;/P&gt;

&lt;P&gt;Example event:&lt;/P&gt;

&lt;P&gt;&lt;EM&gt;12/10/2014 03:54:45 PM -    Process(5136.740878) User(mqm)    Program(amqrmppa)&lt;BR /&gt;
                   Host(hostname) Installation(Installation_2)&lt;BR /&gt;
                   VRMF(7.5.0.3) QMgr(abcdef)&lt;BR /&gt;
                   AMQ9999: Channel 'ABCD.EFG' to host 'xxx-xxx    (10.1.1.1)' ended abnormally.    EXPLANATION: The channel program    running under process ID 5136 for    channel 'ABCD.EFG' ended abnormally.    The host name is 'xxx-xxx    (10.1.1.1)'; in some cases the host    name cannot be determined and so is    shown as '????'. ACTION: Look at    previous error messages for the    channel program in the error logs to    determine the cause of the failure.    Note that this message can be    excluded completely or suppressed by    tuning the "ExcludeMessage" or    "SuppressMessage" attributes under    the "QMErrorLog" stanza in qm.ini.    Further information can be found in    the System Administration Guide.&lt;/EM&gt;&lt;/P&gt;

&lt;P&gt;The &lt;STRONG&gt;ErrorMessageText&lt;/STRONG&gt; works properly and resolves to &lt;BR /&gt;
"&lt;EM&gt;AMQ9999: Channel 'ABCD.EFG' to host 'xxx-xxx (10.1.1.1)'&lt;BR /&gt;
ended abnormally&lt;/EM&gt;."&lt;/P&gt;

&lt;P&gt;The regex for &lt;STRONG&gt;ErrorMessageChannel&lt;/STRONG&gt; works fine with the Field Extractor app as well. For this event the ErrorMessageText would be "&lt;EM&gt;ABCD.EFG&lt;/EM&gt;"&lt;/P&gt;

&lt;P&gt;What am I missing here?&lt;/P&gt;</description>
      <pubDate>Wed, 10 Dec 2014 20:10:12 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Problem-extracting-field-from-a-field/m-p/156103#M43925</guid>
      <dc:creator>chengka</dc:creator>
      <dc:date>2014-12-10T20:10:12Z</dc:date>
    </item>
    <item>
      <title>Re: Problem extracting field from a field</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Problem-extracting-field-from-a-field/m-p/156104#M43926</link>
      <description>&lt;P&gt;Can you provide a sample event?  If it is listed in the Field Extractions settings that means Splunk knows it is defined...but if you're not seeing it within the Existing Field list on the left of your search results there might be some other issue in your RegEx that isn't working right so nothing ever gets extracted.&lt;/P&gt;

&lt;P&gt;As a side note, it looks like maybe the less-than and greater-than portions of your field extractions got left out by the website - you might want to try editing it and markup your EXTRACT lines as blocks of code.&lt;/P&gt;</description>
      <pubDate>Wed, 10 Dec 2014 20:15:50 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Problem-extracting-field-from-a-field/m-p/156104#M43926</guid>
      <dc:creator>jhupka</dc:creator>
      <dc:date>2014-12-10T20:15:50Z</dc:date>
    </item>
    <item>
      <title>Re: Problem extracting field from a field</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Problem-extracting-field-from-a-field/m-p/156105#M43927</link>
      <description>&lt;P&gt;Try adding "| extract reload=t" at the end of your search. Also, see if restarting your search head is an option and try doing that.&lt;/P&gt;</description>
      <pubDate>Wed, 10 Dec 2014 20:38:30 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Problem-extracting-field-from-a-field/m-p/156105#M43927</guid>
      <dc:creator>somesoni2</dc:creator>
      <dc:date>2014-12-10T20:38:30Z</dc:date>
    </item>
    <item>
      <title>Re: Problem extracting field from a field</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Problem-extracting-field-from-a-field/m-p/156106#M43928</link>
      <description>&lt;P&gt;I think this is your problem: when you specify the &lt;CODE&gt;EXTRACT&lt;/CODE&gt;, Splunk uses the &lt;CODE&gt;class&lt;/CODE&gt; that you provide to sequence the order of evaluation. This is particularly important when you consider that Splunk merges all the &lt;CODE&gt;props.conf&lt;/CODE&gt; files into one run-time specification.&lt;/P&gt;

&lt;P&gt;Since &lt;CODE&gt;ErrorMessageChannel&lt;/CODE&gt; precedes &lt;CODE&gt;ErrorMessageText&lt;/CODE&gt;, it is performed first and extracts nothing.&lt;/P&gt;

&lt;P&gt;Do this instead:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt; EXTRACT-e1 = (?ims)^\w+.+AMQ\d\d\d\d:(?P&amp;lt;ErrorMessageText&amp;gt;.+)EXPLANATION
 EXTRACT-e2 = [cC]hannel[\s']+(?P[\w\d.]+) in ErrorMessageTex
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;and I think it will work. BTW, the &lt;CODE&gt;class&lt;/CODE&gt; name is not at all related to the field name.&lt;/P&gt;</description>
      <pubDate>Wed, 10 Dec 2014 22:11:08 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Problem-extracting-field-from-a-field/m-p/156106#M43928</guid>
      <dc:creator>lguinn2</dc:creator>
      <dc:date>2014-12-10T22:11:08Z</dc:date>
    </item>
    <item>
      <title>Re: Problem extracting field from a field</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Problem-extracting-field-from-a-field/m-p/156107#M43929</link>
      <description>&lt;P&gt;I can see the field when I add  "| extract reload=t".   When I remove it, the field disappears.  Also I adding ErrorMessageChannel=* or any of the Top 10 values returns nothing. &lt;/P&gt;</description>
      <pubDate>Wed, 10 Dec 2014 22:18:35 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Problem-extracting-field-from-a-field/m-p/156107#M43929</guid>
      <dc:creator>chengka</dc:creator>
      <dc:date>2014-12-10T22:18:35Z</dc:date>
    </item>
    <item>
      <title>Re: Problem extracting field from a field</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Problem-extracting-field-from-a-field/m-p/156108#M43930</link>
      <description>&lt;P&gt;If it was actually a reload problem, then you should only need to run this (by itself, not at the end of a search) &lt;EM&gt;one time&lt;/EM&gt;&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| reload extract=t
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Can you show us the actual search, not just the &lt;CODE&gt;props.conf&lt;/CODE&gt; entries?&lt;/P&gt;</description>
      <pubDate>Wed, 10 Dec 2014 22:41:32 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Problem-extracting-field-from-a-field/m-p/156108#M43930</guid>
      <dc:creator>lguinn2</dc:creator>
      <dc:date>2014-12-10T22:41:32Z</dc:date>
    </item>
    <item>
      <title>Re: Problem extracting field from a field</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Problem-extracting-field-from-a-field/m-p/156109#M43931</link>
      <description>&lt;P&gt;Thank you, changing the class name did the trick.&lt;/P&gt;</description>
      <pubDate>Thu, 11 Dec 2014 15:21:22 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Problem-extracting-field-from-a-field/m-p/156109#M43931</guid>
      <dc:creator>chengka</dc:creator>
      <dc:date>2014-12-11T15:21:22Z</dc:date>
    </item>
  </channel>
</rss>

