<?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 Keep specific events and discard the rest -Heavy Forwarder Setup in Splunk Dev</title>
    <link>https://community.splunk.com/t5/Splunk-Dev/Keep-specific-events-and-discard-the-rest-Heavy-Forwarder-Setup/m-p/404765#M6962</link>
    <description>&lt;P&gt;I am setting up a heavy forwarder to keep specific events and discard the rest.  My heavy forwarder is forwarding all of the events and not discarding anything. I am guessing I am either editing the incorrect files or my modifications are incorrect. The only events I would like to keep are Fatal and Warning events&lt;/P&gt;

&lt;P&gt;All of the documentation I have read says to update the transforms.conf and props.conf in /etc/system/local. I am on a windows machine so that directory structure does not exist. There are few different props.conf and transforms.conf.  I am editing the ones in c:\Program Files\Splunk\etc\apps\search\default. Are these the correct ones?  If so, then I must have a problem somewhere else. &lt;/P&gt;

&lt;P&gt;I have updated the transforms.conf and props.conf in c:\Program Files\Splunk\etc\apps\search\default as follows:&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;props.conf:&lt;/STRONG&gt;&lt;BR /&gt;
[source::C:\ProgramData\Folder1\Folder2\*.sts]&lt;BR /&gt;
TRANSFORMS-set= setnull,setparsing&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;transforms.conf:&lt;/STRONG&gt;&lt;BR /&gt;
[setnull]&lt;BR /&gt;
REGEX = .&lt;BR /&gt;
DEST_KEY = queue&lt;BR /&gt;
FORMAT = nullQueue&lt;/P&gt;

&lt;P&gt;[setparsing]&lt;BR /&gt;
REGEX = \[(Fatal|Warning)\]&lt;BR /&gt;
DEST_KEY = queue&lt;BR /&gt;
FORMAT = indexQueue&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;My Sample Data looks like this:&lt;/STRONG&gt;&lt;BR /&gt;
2019/01/14 14:29:36.356 - (47) [Informational] :  TEST File: SCHD_Scd.Cpp Line: 963&lt;BR /&gt;
    SCHD-S-Information (1860)  Releasing Locking logs...&lt;BR /&gt;
2019/01/14 14:29:36.231 - (47) [Informational] :  TEST File: SCHD_Scd.Cpp Line: 963&lt;BR /&gt;
    SCHD-S-Information (1860)  Cleaning up Locked logs...&lt;BR /&gt;
2019/01/14 14:29:36.106 - (47) [Informational] :  TEST File: SCHD_Scd.Cpp Line: 963&lt;BR /&gt;
    SCHD-S-Information (1860)  479 Loaded  225 Scheduled&lt;BR /&gt;
2019/01/14 14:29:35.950 - (47) [Informational] :  TEST File: SCHD_Scd.Cpp Line: 963&lt;BR /&gt;
    SCHD-S-Information (1860)  Releasing Locking logs...&lt;BR /&gt;
2019/01/14 14:29:35.263 - (126) [Fatal] :  TEST: c:\test\1\4\s\r\h\DB_Tran.Inl Line: 83&lt;BR /&gt;
    DB-F-RoutineFail (1272)  Failure occurred in Routine: [CCDbTransaction::Commit].&lt;BR /&gt;
2019/01/14 14:29:35.263 - (126) [Fatal] :  TEST: DB_Con.Cpp Line: 601&lt;BR /&gt;
    DB-F-RoutineFail (1272)  Failure occurred in Routine: [CCDbConnect::Execute].&lt;BR /&gt;
2019/01/14 14:29:35.263 - (126) [Fatal] :  TEST: DB_Con.Cpp Line: 598&lt;BR /&gt;
    DB-F-GeneralFailure (1272)  A General Failure Occurred In Routine [CCDbConnect::Execute]. COMMIT TRANSACTION;.&lt;/P&gt;

&lt;P&gt;The Source files that are being monitored by the universal forwarder and sent to the heavy forwarder are like this&lt;BR /&gt;
C:\ProgramData\Folder1\Folder2\Test1.sts&lt;BR /&gt;
C:\ProgramData\Folder1\Folder2\Test2.sts&lt;/P&gt;

&lt;P&gt;The universal forwarder inputs.conf has the following:&lt;BR /&gt;
[monitor://C:\ProgramData\Folder1\Folder2\*.sts]&lt;BR /&gt;
current_only = 1&lt;BR /&gt;
disabled = 0&lt;BR /&gt;
start_from = oldest&lt;BR /&gt;
sourcetype = stslog&lt;BR /&gt;
index = sts&lt;/P&gt;

&lt;P&gt;Any help would be appreciated! Thank you&lt;/P&gt;</description>
    <pubDate>Tue, 29 Sep 2020 22:45:46 GMT</pubDate>
    <dc:creator>kevinbullock</dc:creator>
    <dc:date>2020-09-29T22:45:46Z</dc:date>
    <item>
      <title>Keep specific events and discard the rest -Heavy Forwarder Setup</title>
      <link>https://community.splunk.com/t5/Splunk-Dev/Keep-specific-events-and-discard-the-rest-Heavy-Forwarder-Setup/m-p/404765#M6962</link>
      <description>&lt;P&gt;I am setting up a heavy forwarder to keep specific events and discard the rest.  My heavy forwarder is forwarding all of the events and not discarding anything. I am guessing I am either editing the incorrect files or my modifications are incorrect. The only events I would like to keep are Fatal and Warning events&lt;/P&gt;

&lt;P&gt;All of the documentation I have read says to update the transforms.conf and props.conf in /etc/system/local. I am on a windows machine so that directory structure does not exist. There are few different props.conf and transforms.conf.  I am editing the ones in c:\Program Files\Splunk\etc\apps\search\default. Are these the correct ones?  If so, then I must have a problem somewhere else. &lt;/P&gt;

&lt;P&gt;I have updated the transforms.conf and props.conf in c:\Program Files\Splunk\etc\apps\search\default as follows:&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;props.conf:&lt;/STRONG&gt;&lt;BR /&gt;
[source::C:\ProgramData\Folder1\Folder2\*.sts]&lt;BR /&gt;
TRANSFORMS-set= setnull,setparsing&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;transforms.conf:&lt;/STRONG&gt;&lt;BR /&gt;
[setnull]&lt;BR /&gt;
REGEX = .&lt;BR /&gt;
DEST_KEY = queue&lt;BR /&gt;
FORMAT = nullQueue&lt;/P&gt;

&lt;P&gt;[setparsing]&lt;BR /&gt;
REGEX = \[(Fatal|Warning)\]&lt;BR /&gt;
DEST_KEY = queue&lt;BR /&gt;
FORMAT = indexQueue&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;My Sample Data looks like this:&lt;/STRONG&gt;&lt;BR /&gt;
2019/01/14 14:29:36.356 - (47) [Informational] :  TEST File: SCHD_Scd.Cpp Line: 963&lt;BR /&gt;
    SCHD-S-Information (1860)  Releasing Locking logs...&lt;BR /&gt;
2019/01/14 14:29:36.231 - (47) [Informational] :  TEST File: SCHD_Scd.Cpp Line: 963&lt;BR /&gt;
    SCHD-S-Information (1860)  Cleaning up Locked logs...&lt;BR /&gt;
2019/01/14 14:29:36.106 - (47) [Informational] :  TEST File: SCHD_Scd.Cpp Line: 963&lt;BR /&gt;
    SCHD-S-Information (1860)  479 Loaded  225 Scheduled&lt;BR /&gt;
2019/01/14 14:29:35.950 - (47) [Informational] :  TEST File: SCHD_Scd.Cpp Line: 963&lt;BR /&gt;
    SCHD-S-Information (1860)  Releasing Locking logs...&lt;BR /&gt;
2019/01/14 14:29:35.263 - (126) [Fatal] :  TEST: c:\test\1\4\s\r\h\DB_Tran.Inl Line: 83&lt;BR /&gt;
    DB-F-RoutineFail (1272)  Failure occurred in Routine: [CCDbTransaction::Commit].&lt;BR /&gt;
2019/01/14 14:29:35.263 - (126) [Fatal] :  TEST: DB_Con.Cpp Line: 601&lt;BR /&gt;
    DB-F-RoutineFail (1272)  Failure occurred in Routine: [CCDbConnect::Execute].&lt;BR /&gt;
2019/01/14 14:29:35.263 - (126) [Fatal] :  TEST: DB_Con.Cpp Line: 598&lt;BR /&gt;
    DB-F-GeneralFailure (1272)  A General Failure Occurred In Routine [CCDbConnect::Execute]. COMMIT TRANSACTION;.&lt;/P&gt;

&lt;P&gt;The Source files that are being monitored by the universal forwarder and sent to the heavy forwarder are like this&lt;BR /&gt;
C:\ProgramData\Folder1\Folder2\Test1.sts&lt;BR /&gt;
C:\ProgramData\Folder1\Folder2\Test2.sts&lt;/P&gt;

&lt;P&gt;The universal forwarder inputs.conf has the following:&lt;BR /&gt;
[monitor://C:\ProgramData\Folder1\Folder2\*.sts]&lt;BR /&gt;
current_only = 1&lt;BR /&gt;
disabled = 0&lt;BR /&gt;
start_from = oldest&lt;BR /&gt;
sourcetype = stslog&lt;BR /&gt;
index = sts&lt;/P&gt;

&lt;P&gt;Any help would be appreciated! Thank you&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 22:45:46 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Dev/Keep-specific-events-and-discard-the-rest-Heavy-Forwarder-Setup/m-p/404765#M6962</guid>
      <dc:creator>kevinbullock</dc:creator>
      <dc:date>2020-09-29T22:45:46Z</dc:date>
    </item>
    <item>
      <title>Re: Keep specific events and discard the rest -Heavy Forwarder Setup</title>
      <link>https://community.splunk.com/t5/Splunk-Dev/Keep-specific-events-and-discard-the-rest-Heavy-Forwarder-Setup/m-p/404766#M6963</link>
      <description>&lt;P&gt;Hi,&lt;BR /&gt;
c:\Program Files\Splunk\etc\apps\search\default&lt;BR /&gt;
you should "never" edit &lt;CODE&gt;c:\Program Files\Splunk\etc\apps\search\default&lt;/CODE&gt; ... that is product release defaults, since it is a default app.&lt;/P&gt;

&lt;P&gt;In your case you should create and edit files in &lt;CODE&gt;c:\Program Files\Splunk\etc\apps\search\local&lt;/CODE&gt;. Splunk will "merge" the configs at runtime.&lt;BR /&gt;
&lt;A href="https://docs.splunk.com/Documentation/Splunk/7.2.1/Admin/Configurationfiledirectories"&gt;https://docs.splunk.com/Documentation/Splunk/7.2.1/Admin/Configurationfiledirectories&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;In order to debug your current runtime configuration it is very handy to use the &lt;CODE&gt;btool&lt;/CODE&gt;:&lt;BR /&gt;
&lt;A href="https://docs.splunk.com/Documentation/Splunk/7.2.3/Troubleshooting/Usebtooltotroubleshootconfigurations"&gt;https://docs.splunk.com/Documentation/Splunk/7.2.3/Troubleshooting/Usebtooltotroubleshootconfigurations&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;Note: If you want to &lt;CODE&gt;grep&lt;/CODE&gt; in Windows, use the PowerShell in the following way (example):&lt;BR /&gt;
&lt;CODE&gt;C:\Program Files\Splunk\bin&amp;gt; .\splunk.exe cmd btool outputs list --debug | Select-String -Pattern "&amp;lt;REGEX_PATTERN&amp;gt;&lt;/CODE&gt;&lt;/P&gt;

&lt;P&gt;Configuration should be described as here:&lt;BR /&gt;
&lt;A href="https://docs.splunk.com/Documentation/SplunkCloud/7.1.3/Forwarding/Routeandfilterdatad#Discard_specific_events_and_keep_the_rest"&gt;https://docs.splunk.com/Documentation/SplunkCloud/7.1.3/Forwarding/Routeandfilterdatad#Discard_specific_events_and_keep_the_rest&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;Hope that guides you a little.&lt;/P&gt;

&lt;P&gt;Cheerz - Björn&lt;/P&gt;</description>
      <pubDate>Tue, 15 Jan 2019 07:39:51 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Dev/Keep-specific-events-and-discard-the-rest-Heavy-Forwarder-Setup/m-p/404766#M6963</guid>
      <dc:creator>bjoernjensen</dc:creator>
      <dc:date>2019-01-15T07:39:51Z</dc:date>
    </item>
    <item>
      <title>Re: Keep specific events and discard the rest -Heavy Forwarder Setup</title>
      <link>https://community.splunk.com/t5/Splunk-Dev/Keep-specific-events-and-discard-the-rest-Heavy-Forwarder-Setup/m-p/404767#M6964</link>
      <description>&lt;P&gt;Björn, &lt;BR /&gt;
Thank you for the reply.  This was all very useful information.&lt;BR /&gt;
I tried populating C:\Program Files\Splunk\etc\apps\search\local with my settings for props.conf and transforms.conf, but that didn't work.&lt;BR /&gt;
I ended up populating the settings in C:\Program Files\Splunk\etc\system\local  for props.conf and transforms.conf. However, at first, this still didn't work.  &lt;/P&gt;

&lt;P&gt;The real problem was in Splunks documentation that I was using found here: &lt;A href="https://docs.splunk.com/Documentation/SplunkCloud/7.1.3/Forwarding/Routeandfilterdatad#Discard_specific_events_and_keep_the_rest"&gt;Forwarding Data&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;Under the section, &lt;STRONG&gt;Keep specific events and discard the rest&lt;/STRONG&gt;, I copied the this specific line for the profs.conf configuration:&lt;BR /&gt;
TRANSFORMS-set= setnull,setparsing&lt;/P&gt;

&lt;P&gt;The problem was that there needs to be a space inbetween the comma and "setparsing". This line should read like:&lt;BR /&gt;
TRANSFORMS-set = setnull, setparsing&lt;/P&gt;

&lt;P&gt;After adding the space, everything is working correctly now. I can't tell you how many hours I have spent trying to figure this out the last two days. &lt;/P&gt;

&lt;P&gt;Again, thank you for your help! It is greatly appreciated. &lt;/P&gt;</description>
      <pubDate>Tue, 15 Jan 2019 20:34:47 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Dev/Keep-specific-events-and-discard-the-rest-Heavy-Forwarder-Setup/m-p/404767#M6964</guid>
      <dc:creator>kevinbullock</dc:creator>
      <dc:date>2019-01-15T20:34:47Z</dc:date>
    </item>
  </channel>
</rss>

