<?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 with filtering events prior to indexing in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/Problem-with-filtering-events-prior-to-indexing/m-p/187499#M37458</link>
    <description>&lt;P&gt;Thanks Luke!&lt;BR /&gt;
Since I followed the docs and some other posts here and it didn't work for me, thus those try&amp;amp;error steps :]&lt;/P&gt;

&lt;OL&gt;
&lt;LI&gt;This is the first location I was adding the files. Not resolved.&lt;/LI&gt;
&lt;LI&gt;Yup, the source name comes from searches. In the particular example &lt;CODE&gt;source&lt;/CODE&gt; is identical to &lt;CODE&gt;sourcetype&lt;/CODE&gt;.&lt;/LI&gt;
&lt;LI&gt;For some crazy reason cant edit the post (captcha failes every time). The 5156|104 is in reality going also to &lt;CODE&gt;nullQueue&lt;/CODE&gt; . Yes, I want to filter them out, not in.&lt;/LI&gt;
&lt;LI&gt;Correct, restarted, each time waiting for new logs to get indexed to see if worked.&lt;/LI&gt;
&lt;/OL&gt;</description>
    <pubDate>Sun, 22 Dec 2013 13:21:06 GMT</pubDate>
    <dc:creator>ferdydek</dc:creator>
    <dc:date>2013-12-22T13:21:06Z</dc:date>
    <item>
      <title>Problem with filtering events prior to indexing</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Problem-with-filtering-events-prior-to-indexing/m-p/187497#M37456</link>
      <description>&lt;P&gt;I need to drop "Filtering Platform Connections", I also want to drop most of "Audit File System" events from windows servers. I do not have control over source servers, those only have universal-forwarder. I can only manipulate the indexer-all-in-one Splunk server.&lt;/P&gt;

&lt;P&gt;I followed &lt;CODE&gt;&lt;A href="http://docs.splunk.com/Documentation/Splunk/5.0.6/Deploy/Routeandfilterdatad" target="_blank"&gt;http://docs.splunk.com/Documentation/Splunk/5.0.6/Deploy/Routeandfilterdatad&lt;/A&gt;&lt;/CODE&gt; and some posts on answers and was testing the following:&lt;/P&gt;

&lt;P&gt;in ../etc/system/local/&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;props.conf&lt;/STRONG&gt;&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[WinEventLog:Security]
TRANSFORMS-wmi = NullEvents-null, WinSecEvents-null
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;&lt;STRONG&gt;transforms.conf&lt;/STRONG&gt;&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[NullEvents-null]
REGEX = .
DEST_KEY = queue
FORMAT = nullQueue

[WinSecEvents-null]
REGEX=(?msi)^EventCode=(5156|104)\D
DEST_KEY = queue
FORMAT = indexQueue
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Unfortunately the filtered events still show up.&lt;BR /&gt;
What I did so far:&lt;/P&gt;

&lt;UL&gt;
&lt;LI&gt;tested the regex on search in splunk - works,&lt;/LI&gt;
&lt;LI&gt;tried adding the files to &lt;CODE&gt; /etc/apps/windows/ /etc/apps/Splunk_TA_Windows /splunk/app/Splunk_for_Exchange &lt;/CODE&gt; as those were the files that &lt;CODE&gt;./splunk cmd btool&lt;/CODE&gt; and &lt;CODE&gt; grep &lt;/CODE&gt; came up with,&lt;/LI&gt;
&lt;LI&gt;tried several source names &lt;CODE&gt; [WMI:WinEventLog:Security] [source::WinEventLog:Security] [source::WMI:WinEventLog:Security] [source::main] [WMI:WinEventLog:Security]&lt;/CODE&gt;&lt;/LI&gt;
&lt;LI&gt;rebooting after each test (ofc),&lt;/LI&gt;
&lt;LI&gt;created a case with splunk and gave them the dump file, but this is not solved yet.&lt;/LI&gt;
&lt;/UL&gt;

&lt;P&gt;I'm wondering if I'm putting the files in proper place (folder), if I'm using the correct [source] ? &lt;/P&gt;

&lt;P&gt;++ I'm on 5.0.6. ++ I'm fresh to Splunk configurations ++ I'm abusing my license as I cant filter the events, so the issue is urgent ++&lt;/P&gt;</description>
      <pubDate>Mon, 28 Sep 2020 15:31:59 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Problem-with-filtering-events-prior-to-indexing/m-p/187497#M37456</guid>
      <dc:creator>ferdydek</dc:creator>
      <dc:date>2020-09-28T15:31:59Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with filtering events prior to indexing</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Problem-with-filtering-events-prior-to-indexing/m-p/187498#M37457</link>
      <description>&lt;P&gt;A few things to help troubleshooting.&lt;BR /&gt;&lt;BR /&gt;
1) Put the props and transforms in etc//system//local.  This directory has the highest precedence for index time extractions.&lt;BR /&gt;&lt;BR /&gt;
2) Use the source as opposed to the sourcetype.  Extractions for the source will take precedence over extractions for sourcetype, so if there is a conflict it will only be with source.&lt;BR /&gt;&lt;BR /&gt;
3) You should not guess at the source.  Run a search on the data and verify the source from the source field, and use it exactly preceded by &lt;CODE&gt;[source::&amp;lt;yoursourcehere&amp;gt;]&lt;/CODE&gt;.&lt;BR /&gt;&lt;BR /&gt;
4) If you want to keep &lt;CODE&gt;EventCode=(5156|104)\D&lt;/CODE&gt;, then why call them null?&lt;BR /&gt;
5) The transform requires an indexer restart to take effect and will only affect newly indexed logs.&lt;/P&gt;

&lt;P&gt;Update: config to drop two event codes and keep everything else.&lt;/P&gt;

&lt;P&gt;Have you tried this?&lt;/P&gt;

&lt;P&gt;Make sure the source is correct, then in ../etc/system/local/&lt;/P&gt;

&lt;P&gt;props.conf&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[WinEventLog:Security]
TRANSFORMS-wmi = WinSecEvents-null

transforms.conf

[WinSecEvents-null]
REGEX=(?msi)^EventCode=(5156|104)\D
DEST_KEY = queue
FORMAT = nullQueue
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Sun, 22 Dec 2013 12:21:37 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Problem-with-filtering-events-prior-to-indexing/m-p/187498#M37457</guid>
      <dc:creator>lukejadamec</dc:creator>
      <dc:date>2013-12-22T12:21:37Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with filtering events prior to indexing</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Problem-with-filtering-events-prior-to-indexing/m-p/187499#M37458</link>
      <description>&lt;P&gt;Thanks Luke!&lt;BR /&gt;
Since I followed the docs and some other posts here and it didn't work for me, thus those try&amp;amp;error steps :]&lt;/P&gt;

&lt;OL&gt;
&lt;LI&gt;This is the first location I was adding the files. Not resolved.&lt;/LI&gt;
&lt;LI&gt;Yup, the source name comes from searches. In the particular example &lt;CODE&gt;source&lt;/CODE&gt; is identical to &lt;CODE&gt;sourcetype&lt;/CODE&gt;.&lt;/LI&gt;
&lt;LI&gt;For some crazy reason cant edit the post (captcha failes every time). The 5156|104 is in reality going also to &lt;CODE&gt;nullQueue&lt;/CODE&gt; . Yes, I want to filter them out, not in.&lt;/LI&gt;
&lt;LI&gt;Correct, restarted, each time waiting for new logs to get indexed to see if worked.&lt;/LI&gt;
&lt;/OL&gt;</description>
      <pubDate>Sun, 22 Dec 2013 13:21:06 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Problem-with-filtering-events-prior-to-indexing/m-p/187499#M37458</guid>
      <dc:creator>ferdydek</dc:creator>
      <dc:date>2013-12-22T13:21:06Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with filtering events prior to indexing</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Problem-with-filtering-events-prior-to-indexing/m-p/187500#M37459</link>
      <description>&lt;P&gt;If that is the case, then your config is off the mark.&lt;/P&gt;

&lt;P&gt;When I want to drop particular Windows events in Splunk 5, I use just one stanza.  Try dropping all reference and stanzas to NullEvents-null, and keep only WinSecEvents-null.&lt;/P&gt;

&lt;P&gt;My guess is the config you have posted would drop everything except those two events even though you named it -null.&lt;/P&gt;</description>
      <pubDate>Mon, 23 Dec 2013 18:26:31 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Problem-with-filtering-events-prior-to-indexing/m-p/187500#M37459</guid>
      <dc:creator>lukejadamec</dc:creator>
      <dc:date>2013-12-23T18:26:31Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with filtering events prior to indexing</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Problem-with-filtering-events-prior-to-indexing/m-p/187501#M37460</link>
      <description>&lt;P&gt;I do want to drop those 2 events, thus they go to nullQueue. I'm pretty confident this is how it should be.&lt;/P&gt;

&lt;P&gt;I also forgot to mention - splunk is running as a "splunk" user, and yes, all config files are owned by "splunk" user.&lt;/P&gt;</description>
      <pubDate>Thu, 26 Dec 2013 11:32:07 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Problem-with-filtering-events-prior-to-indexing/m-p/187501#M37460</guid>
      <dc:creator>ferdydek</dc:creator>
      <dc:date>2013-12-26T11:32:07Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with filtering events prior to indexing</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Problem-with-filtering-events-prior-to-indexing/m-p/187502#M37461</link>
      <description>&lt;P&gt;The configs you posted won't do what you want.  I know you said you could not edit them, but when you say "I pretty confident this is how it should be" it is kind of confusing - what do you mean by 'this'?&lt;BR /&gt;
I updated my answer to remove the first nullQueue stanza and changed to indexQueue to nullQueue for the events you want to drop.&lt;/P&gt;</description>
      <pubDate>Thu, 26 Dec 2013 12:51:34 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Problem-with-filtering-events-prior-to-indexing/m-p/187502#M37461</guid>
      <dc:creator>lukejadamec</dc:creator>
      <dc:date>2013-12-26T12:51:34Z</dc:date>
    </item>
  </channel>
</rss>

