<?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 Filtering Unwanted Events in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Filtering-Unwanted-Events/m-p/247481#M189128</link>
    <description>&lt;P&gt;I've been trying to filter unwanted events on a heavy forwarder from being sent to indexers. I followed the instructions which I found in here &lt;A href="http://docs.splunk.com/Documentation/Splunk/6.4.3/Forwarding/Routeandfilterdatad" target="_blank"&gt;http://docs.splunk.com/Documentation/Splunk/6.4.3/Forwarding/Routeandfilterdatad&lt;/A&gt;, more specifically, I followed this: &lt;/P&gt;

&lt;P&gt;Keep specific events and discard the rest&lt;BR /&gt;
This scenario is opposite to the previous scenario. In this example, you use two transforms to keep only the sshd events. One transform routes sshd events to indexQueue, while another routes all other events to nullQueue.&lt;/P&gt;

&lt;P&gt;Note: In this example, the order of the transforms in props.conf matters. The null queue transform must come first; if it comes later, it will invalidate the previous transform and route all events to the null queue.&lt;/P&gt;

&lt;OL&gt;
&lt;LI&gt;In props.conf:&lt;/LI&gt;
&lt;/OL&gt;

&lt;P&gt;[source::/var/log/messages]&lt;BR /&gt;
TRANSFORMS-set= setnull,setparsing&lt;BR /&gt;
2. In transforms.conf:&lt;/P&gt;

&lt;P&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 = [sshd]&lt;BR /&gt;
DEST_KEY = queue&lt;BR /&gt;
FORMAT = indexQueue&lt;BR /&gt;
 1. Restart Splunk Enterprise.&lt;/P&gt;

&lt;P&gt;But it doesn't work, can someone tell me where is the issue? This is my stanza: &lt;/P&gt;

&lt;P&gt;props.conf&lt;/P&gt;

&lt;P&gt;[source::/var/log/messages]&lt;BR /&gt;
TRANSFORMS-null = setnull, setparsing&lt;/P&gt;

&lt;P&gt;transforms.conf&lt;/P&gt;

&lt;P&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 = splunk_agent.py&lt;BR /&gt;
DEST_KEY = queue&lt;BR /&gt;
FORMAT = indexQueue&lt;/P&gt;</description>
    <pubDate>Tue, 29 Sep 2020 10:44:07 GMT</pubDate>
    <dc:creator>daniel_augustyn</dc:creator>
    <dc:date>2020-09-29T10:44:07Z</dc:date>
    <item>
      <title>Filtering Unwanted Events</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Filtering-Unwanted-Events/m-p/247481#M189128</link>
      <description>&lt;P&gt;I've been trying to filter unwanted events on a heavy forwarder from being sent to indexers. I followed the instructions which I found in here &lt;A href="http://docs.splunk.com/Documentation/Splunk/6.4.3/Forwarding/Routeandfilterdatad" target="_blank"&gt;http://docs.splunk.com/Documentation/Splunk/6.4.3/Forwarding/Routeandfilterdatad&lt;/A&gt;, more specifically, I followed this: &lt;/P&gt;

&lt;P&gt;Keep specific events and discard the rest&lt;BR /&gt;
This scenario is opposite to the previous scenario. In this example, you use two transforms to keep only the sshd events. One transform routes sshd events to indexQueue, while another routes all other events to nullQueue.&lt;/P&gt;

&lt;P&gt;Note: In this example, the order of the transforms in props.conf matters. The null queue transform must come first; if it comes later, it will invalidate the previous transform and route all events to the null queue.&lt;/P&gt;

&lt;OL&gt;
&lt;LI&gt;In props.conf:&lt;/LI&gt;
&lt;/OL&gt;

&lt;P&gt;[source::/var/log/messages]&lt;BR /&gt;
TRANSFORMS-set= setnull,setparsing&lt;BR /&gt;
2. In transforms.conf:&lt;/P&gt;

&lt;P&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 = [sshd]&lt;BR /&gt;
DEST_KEY = queue&lt;BR /&gt;
FORMAT = indexQueue&lt;BR /&gt;
 1. Restart Splunk Enterprise.&lt;/P&gt;

&lt;P&gt;But it doesn't work, can someone tell me where is the issue? This is my stanza: &lt;/P&gt;

&lt;P&gt;props.conf&lt;/P&gt;

&lt;P&gt;[source::/var/log/messages]&lt;BR /&gt;
TRANSFORMS-null = setnull, setparsing&lt;/P&gt;

&lt;P&gt;transforms.conf&lt;/P&gt;

&lt;P&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 = splunk_agent.py&lt;BR /&gt;
DEST_KEY = queue&lt;BR /&gt;
FORMAT = indexQueue&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 10:44:07 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Filtering-Unwanted-Events/m-p/247481#M189128</guid>
      <dc:creator>daniel_augustyn</dc:creator>
      <dc:date>2020-09-29T10:44:07Z</dc:date>
    </item>
    <item>
      <title>Re: Filtering Unwanted Events</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Filtering-Unwanted-Events/m-p/247482#M189129</link>
      <description>&lt;P&gt;Just a quick first guess, it looks like your REGEX is wrong for [setparsing].  The "." is a special character for regex, so you need to escape it like so:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;REGEX = splunk_agent\.py
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 25 Aug 2016 22:44:24 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Filtering-Unwanted-Events/m-p/247482#M189129</guid>
      <dc:creator>jconger</dc:creator>
      <dc:date>2016-08-25T22:44:24Z</dc:date>
    </item>
    <item>
      <title>Re: Filtering Unwanted Events</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Filtering-Unwanted-Events/m-p/247483#M189130</link>
      <description>&lt;P&gt;This should work (although you should escape the &lt;CODE&gt;.&lt;/CODE&gt; character as the other answer indicates.  This should be deployed to your Indexers and each splunk instance there has to be bounced.  Even so ONLY DATA THAT IS INDEXED AFTER THE BOUNCE will be correct.  The earlier data is already in and will not be effected.&lt;/P&gt;</description>
      <pubDate>Thu, 25 Aug 2016 23:48:01 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Filtering-Unwanted-Events/m-p/247483#M189130</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2016-08-25T23:48:01Z</dc:date>
    </item>
  </channel>
</rss>

