<?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: Add 'static' field to all events from a source (syslogs) in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Add-static-field-to-all-events-from-a-source-syslogs/m-p/85099#M21704</link>
    <description>&lt;P&gt;Are you simply trying to insert a placeholder field which will be later defined by other query?&lt;/P&gt;</description>
    <pubDate>Wed, 20 Apr 2011 12:45:29 GMT</pubDate>
    <dc:creator>netwrkr</dc:creator>
    <dc:date>2011-04-20T12:45:29Z</dc:date>
    <item>
      <title>Add 'static' field to all events from a source (syslogs)</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Add-static-field-to-all-events-from-a-source-syslogs/m-p/85098#M21703</link>
      <description>&lt;P&gt;I have a dedicated index for syslogs that I would like to add a 'static field' to:&lt;/P&gt;

&lt;P&gt;MonFunc=sysmsgs   ### Add to &lt;STRONG&gt;all&lt;/STRONG&gt; events in this index&lt;/P&gt;

&lt;P&gt;I'm trying to merge this data with related info in another logging index (which has a field extract for various function errors, generating the MonFunc).  But, doing an aggregate table-based summary (from all indexes), grouped by MonFunc, has all the syslogs showing up as NULL.&lt;/P&gt;

&lt;P&gt;I know of one possible workaround (our monitor system has its own filter and log, adding its own msg before the actual syslog), but would prefer a 'simpler' solution than generating a custom syslog extractor.  It would also end up bypassing other data that may be useful long-term, which I'm trying to avoid.&lt;/P&gt;</description>
      <pubDate>Wed, 20 Apr 2011 11:48:03 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Add-static-field-to-all-events-from-a-source-syslogs/m-p/85098#M21703</guid>
      <dc:creator>tskimball</dc:creator>
      <dc:date>2011-04-20T11:48:03Z</dc:date>
    </item>
    <item>
      <title>Re: Add 'static' field to all events from a source (syslogs)</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Add-static-field-to-all-events-from-a-source-syslogs/m-p/85099#M21704</link>
      <description>&lt;P&gt;Are you simply trying to insert a placeholder field which will be later defined by other query?&lt;/P&gt;</description>
      <pubDate>Wed, 20 Apr 2011 12:45:29 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Add-static-field-to-all-events-from-a-source-syslogs/m-p/85099#M21704</guid>
      <dc:creator>netwrkr</dc:creator>
      <dc:date>2011-04-20T12:45:29Z</dc:date>
    </item>
    <item>
      <title>Re: Add 'static' field to all events from a source (syslogs)</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Add-static-field-to-all-events-from-a-source-syslogs/m-p/85100#M21705</link>
      <description>&lt;P&gt;To add a static kv pair to all events in an index I would recommend using a lookup table to map index-&amp;gt;MonFunc.  The trick is to use a global (no stanza) property unless you can scope to a particular source/sourcetype/host.  I didn't find the name of your index, so be sure to change "index_name" to reflect the name of the index you want to assign the kv pair to:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;## MonFunc.csv
index,MonFunc
index_name,sysmsgs

## transforms.conf
[MonFunc_lookup]
filename = MonFunc.csv

## props.conf
LOOKUP-MonFunc_for_index_name = MonFunc_lookup index OUTPUT MonFunc
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Wed, 20 Apr 2011 17:54:07 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Add-static-field-to-all-events-from-a-source-syslogs/m-p/85100#M21705</guid>
      <dc:creator>hazekamp</dc:creator>
      <dc:date>2011-04-20T17:54:07Z</dc:date>
    </item>
    <item>
      <title>Re: Add 'static' field to all events from a source (syslogs)</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Add-static-field-to-all-events-from-a-source-syslogs/m-p/85101#M21706</link>
      <description>&lt;P&gt;This is for adding an (already defined) field that shows what function the message came from.&lt;/P&gt;

&lt;P&gt;In the case of our monitoring app, all syslogs come from a function named 'sysmsgs.'  Setting that field for all incoming syslogs will help prevent confusion for our end users.&lt;/P&gt;</description>
      <pubDate>Thu, 21 Apr 2011 04:35:26 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Add-static-field-to-all-events-from-a-source-syslogs/m-p/85101#M21706</guid>
      <dc:creator>tskimball</dc:creator>
      <dc:date>2011-04-21T04:35:26Z</dc:date>
    </item>
    <item>
      <title>Re: Add 'static' field to all events from a source (syslogs)</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Add-static-field-to-all-events-from-a-source-syslogs/m-p/85102#M21707</link>
      <description>&lt;P&gt;Excellent, that worked.  Thanks.&lt;/P&gt;</description>
      <pubDate>Thu, 21 Apr 2011 04:42:44 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Add-static-field-to-all-events-from-a-source-syslogs/m-p/85102#M21707</guid>
      <dc:creator>tskimball</dc:creator>
      <dc:date>2011-04-21T04:42:44Z</dc:date>
    </item>
    <item>
      <title>Re: Add 'static' field to all events from a source (syslogs)</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Add-static-field-to-all-events-from-a-source-syslogs/m-p/85103#M21708</link>
      <description>&lt;P&gt;Devise a common sourcetype&lt;/P&gt;

&lt;P&gt;example lookup csv called myexample.csv&lt;/P&gt;

&lt;P&gt;sourcetype,SLA,NAME,VALUE&lt;BR /&gt;
foobar,99,TechnicalError,456&lt;/P&gt;

&lt;P&gt;transforms.conf:&lt;/P&gt;

&lt;P&gt;[myexamplelookup]&lt;BR /&gt;
filename=myexample.csv&lt;/P&gt;

&lt;P&gt;props.conf&lt;BR /&gt;
[foobar]&lt;BR /&gt;
LOOKUP-myexamplelookup = myexamplelookup sourcetype VALUE OUTPUT SLA NAME VALUE&lt;/P&gt;</description>
      <pubDate>Sat, 22 Sep 2012 03:06:21 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Add-static-field-to-all-events-from-a-source-syslogs/m-p/85103#M21708</guid>
      <dc:creator>davecroto</dc:creator>
      <dc:date>2012-09-22T03:06:21Z</dc:date>
    </item>
  </channel>
</rss>

