<?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: Filter data in log files in Splunk Enterprise</title>
    <link>https://community.splunk.com/t5/Splunk-Enterprise/Filter-data-in-log-files/m-p/702595#M20595</link>
    <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/271073"&gt;@JagsP&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;P&gt;Please update the [stanza] regex as follows:&lt;/P&gt;&lt;P&gt;REGEX = successful\, returned exit code \'0\'&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Note:&lt;/STRONG&gt; Make sure to place the configurations correctly otherwise it will not work .&lt;BR /&gt;&lt;BR /&gt;For eg: If your data flow is UF-&amp;gt;HF-&amp;gt;Indexer, parsing occurs at the full enterprise instance, with the HF being the first layer where this takes place.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Additionally, here is the documentation for routing and filtering data, which will help you understand the core concepts.&lt;BR /&gt;&lt;A href="https://docs.splunk.com/Documentation/Splunk/9.3.1/Forwarding/Routeandfilterdatad" target="_blank" rel="noopener"&gt;https://docs.splunk.com/Documentation/Splunk/9.3.1/Forwarding/Routeandfilterdatad&lt;/A&gt;&lt;/P&gt;&lt;P&gt;For learning and writing regex for your data, you can use the platform&amp;nbsp;&amp;nbsp;&lt;A href="https://regex101.com/" target="_blank" rel="noopener"&gt;https://regex101.com/&lt;/A&gt;&lt;/P&gt;&lt;P&gt;If this resolves your issue, please accept and upvote the answers.&lt;/P&gt;&lt;P&gt;Happy Splunking!&lt;/P&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
    <pubDate>Wed, 23 Oct 2024 12:52:30 GMT</pubDate>
    <dc:creator>Bhumi</dc:creator>
    <dc:date>2024-10-23T12:52:30Z</dc:date>
    <item>
      <title>Filter data in log files</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/Filter-data-in-log-files/m-p/696925#M20013</link>
      <description>&lt;P&gt;Hello everyone ,&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I want to filter data for a specific keyword "Snapshot created successfully " from a log file but i am getting other events also along with the searched keywords. My entries in props.conf and transform.conf is as below :&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;props.conf
[sourcetype]
TRANSFORMS-filter = stanza

transforms.conf

[stanza]
REGEX = "Snapshot created successfully"
DEST_KEY = queue
FORMAT = indexqueue&lt;/LI-CODE&gt;
&lt;P&gt;Is there any issue here ?&lt;/P&gt;</description>
      <pubDate>Wed, 23 Oct 2024 23:36:30 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/Filter-data-in-log-files/m-p/696925#M20013</guid>
      <dc:creator>JagsP</dc:creator>
      <dc:date>2024-10-23T23:36:30Z</dc:date>
    </item>
    <item>
      <title>Re: Filter data in log files</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/Filter-data-in-log-files/m-p/696927#M20014</link>
      <description>&lt;P&gt;If you wanna filter out all other events please try&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;props.conf&lt;/SPAN&gt;&lt;/P&gt;&lt;PRE&gt;&lt;BR /&gt;&lt;SPAN&gt;[sourcetype]&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;TRANSFORMS-filter = setnull,stanza&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;transforms:&lt;/PRE&gt;&lt;PRE&gt;[setnull]
REGEX = .
DEST_KEY = queue
FORMAT = nullQueue&lt;/PRE&gt;&lt;PRE&gt;&lt;BR /&gt;&lt;SPAN&gt;[stanza]&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;REGEX = "Snapshot created successfully"&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;DEST_KEY = queue&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;FORMAT = indexQueue&lt;/SPAN&gt;&lt;/PRE&gt;&lt;H6&gt;&amp;nbsp;&lt;/H6&gt;</description>
      <pubDate>Wed, 21 Aug 2024 07:58:18 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/Filter-data-in-log-files/m-p/696927#M20014</guid>
      <dc:creator>PaulPanther</dc:creator>
      <dc:date>2024-08-21T07:58:18Z</dc:date>
    </item>
    <item>
      <title>Re: Filter data in log files</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/Filter-data-in-log-files/m-p/697267#M20038</link>
      <description>&lt;P&gt;I am trying out this . I will let you know whether it worked ! Thanks .&lt;/P&gt;</description>
      <pubDate>Mon, 26 Aug 2024 09:59:26 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/Filter-data-in-log-files/m-p/697267#M20038</guid>
      <dc:creator>JagsP</dc:creator>
      <dc:date>2024-08-26T09:59:26Z</dc:date>
    </item>
    <item>
      <title>Re: Filter data in log files</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/Filter-data-in-log-files/m-p/701278#M20452</link>
      <description>&lt;P&gt;It did not work &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt; It is still giving all the events other than the expected one.&lt;/P&gt;</description>
      <pubDate>Tue, 08 Oct 2024 10:44:32 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/Filter-data-in-log-files/m-p/701278#M20452</guid>
      <dc:creator>JagsP</dc:creator>
      <dc:date>2024-10-08T10:44:32Z</dc:date>
    </item>
    <item>
      <title>Re: Filter data in log files</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/Filter-data-in-log-files/m-p/701294#M20454</link>
      <description>&lt;P&gt;Where have youe configured these settings? And how do you pull/push the data to your indexer? Are there any HeavyForwarders involved?&lt;/P&gt;&lt;P&gt;Feel free to share an sample event with us.&lt;/P&gt;</description>
      <pubDate>Tue, 08 Oct 2024 13:16:26 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/Filter-data-in-log-files/m-p/701294#M20454</guid>
      <dc:creator>PaulPanther</dc:creator>
      <dc:date>2024-10-08T13:16:26Z</dc:date>
    </item>
    <item>
      <title>Re: Filter data in log files</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/Filter-data-in-log-files/m-p/702491#M20585</link>
      <description>&lt;P&gt;This is my error string "&amp;nbsp;&lt;SPAN&gt;&lt;SPAN class=""&gt;successful, returned exit code '0'" but apart from this error , other events are also getting returned. Please help in creating the regex for this as i am new to Regex and also how can we create or take help from where to create regex?&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 22 Oct 2024 11:09:42 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/Filter-data-in-log-files/m-p/702491#M20585</guid>
      <dc:creator>JagsP</dc:creator>
      <dc:date>2024-10-22T11:09:42Z</dc:date>
    </item>
    <item>
      <title>Re: Filter data in log files</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/Filter-data-in-log-files/m-p/702565#M20587</link>
      <description>&lt;P&gt;Yes , Heavy forwarders are being used but how it will impact the data filtration ?&lt;/P&gt;</description>
      <pubDate>Wed, 23 Oct 2024 06:07:19 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/Filter-data-in-log-files/m-p/702565#M20587</guid>
      <dc:creator>JagsP</dc:creator>
      <dc:date>2024-10-23T06:07:19Z</dc:date>
    </item>
    <item>
      <title>Re: Filter data in log files</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/Filter-data-in-log-files/m-p/702570#M20588</link>
      <description>&lt;P&gt;It is important where you put your settings.&lt;/P&gt;&lt;P&gt;Parsing is done on the first "heavy" component in event's path to indexers. So if you have a HF as an intermediate forwarder, you need to put your props/transforms there.&lt;/P&gt;&lt;P&gt;Of course you will still be getting already indexed events during searching index-time transforms are applied only for the new events.&lt;/P&gt;</description>
      <pubDate>Wed, 23 Oct 2024 07:18:24 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/Filter-data-in-log-files/m-p/702570#M20588</guid>
      <dc:creator>PickleRick</dc:creator>
      <dc:date>2024-10-23T07:18:24Z</dc:date>
    </item>
    <item>
      <title>Re: Filter data in log files</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/Filter-data-in-log-files/m-p/702579#M20591</link>
      <description>&lt;P&gt;Is there any issue with the below settings ? Also is the Regex wrong here ?&lt;/P&gt;&lt;PRE&gt;&lt;SPAN&gt;[sourcetype]&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;TRANSFORMS-filter = setnull,stanza&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;transforms:&lt;/PRE&gt;&lt;PRE&gt;[setnull]
REGEX = .
DEST_KEY = queue
FORMAT = nullQueue&lt;/PRE&gt;&lt;PRE&gt;&lt;BR /&gt;&lt;SPAN&gt;[stanza]&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;REGEX = "Snapshot created successfully"&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;DEST_KEY = queue&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;FORMAT = indexQueue&lt;/SPAN&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;A&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 23 Oct 2024 08:14:25 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/Filter-data-in-log-files/m-p/702579#M20591</guid>
      <dc:creator>JagsP</dc:creator>
      <dc:date>2024-10-23T08:14:25Z</dc:date>
    </item>
    <item>
      <title>Re: Filter data in log files</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/Filter-data-in-log-files/m-p/702584#M20593</link>
      <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/271073"&gt;@JagsP&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;1. What is the dataflow ? For Eg: UF-&amp;gt;HF-&amp;gt;Indexer and where have you placed your configurations.&amp;nbsp;&lt;/P&gt;&lt;P&gt;2. Also, share the sample event , so accordingly I can help you with regex part.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 23 Oct 2024 10:21:06 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/Filter-data-in-log-files/m-p/702584#M20593</guid>
      <dc:creator>Bhumi</dc:creator>
      <dc:date>2024-10-23T10:21:06Z</dc:date>
    </item>
    <item>
      <title>Re: Filter data in log files</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/Filter-data-in-log-files/m-p/702587#M20594</link>
      <description>&lt;LI-CODE lang="markup"&gt;props.conf :

[sap_failure]
TRANSFORMS-filter = setnull,stanza



transform.conf :

[setnull]
REGEX = .
DEST_KEY = queue
FORMAT = nullQueue



[stanza]
REGEX = "successful, returned exit code '0'"
DEST_KEY = queue
FORMAT = indexQueue&lt;/LI-CODE&gt;
&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;Content:&lt;/P&gt;
&lt;P&gt;[16/Sep/2024:02:00:36 -05:00] INFO : [PID:0185317:Backup:360] [1] successful, returned exit code '0'&lt;BR /&gt;[16/Sep/2024:02:00:36 -05:00] DEBUG: [PID:0185317:SAPHANA:648] SQLSTRING: 'BACKUP DATA FOR FULL SYSTEM CLOSE SNAPSHOT BACKUP_ID 1726470003540 SUCCESSFUL 'hana_data_FHL__2024-09-16T070003-1779190Z''&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Here in content if you see i have other events which is not having the desired text string . I need to filter all other events .&lt;/P&gt;
&lt;P class="lia-align-left"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;has context menu&lt;/P&gt;</description>
      <pubDate>Wed, 23 Oct 2024 23:36:05 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/Filter-data-in-log-files/m-p/702587#M20594</guid>
      <dc:creator>JagsP</dc:creator>
      <dc:date>2024-10-23T23:36:05Z</dc:date>
    </item>
    <item>
      <title>Re: Filter data in log files</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/Filter-data-in-log-files/m-p/702595#M20595</link>
      <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/271073"&gt;@JagsP&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;P&gt;Please update the [stanza] regex as follows:&lt;/P&gt;&lt;P&gt;REGEX = successful\, returned exit code \'0\'&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Note:&lt;/STRONG&gt; Make sure to place the configurations correctly otherwise it will not work .&lt;BR /&gt;&lt;BR /&gt;For eg: If your data flow is UF-&amp;gt;HF-&amp;gt;Indexer, parsing occurs at the full enterprise instance, with the HF being the first layer where this takes place.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Additionally, here is the documentation for routing and filtering data, which will help you understand the core concepts.&lt;BR /&gt;&lt;A href="https://docs.splunk.com/Documentation/Splunk/9.3.1/Forwarding/Routeandfilterdatad" target="_blank" rel="noopener"&gt;https://docs.splunk.com/Documentation/Splunk/9.3.1/Forwarding/Routeandfilterdatad&lt;/A&gt;&lt;/P&gt;&lt;P&gt;For learning and writing regex for your data, you can use the platform&amp;nbsp;&amp;nbsp;&lt;A href="https://regex101.com/" target="_blank" rel="noopener"&gt;https://regex101.com/&lt;/A&gt;&lt;/P&gt;&lt;P&gt;If this resolves your issue, please accept and upvote the answers.&lt;/P&gt;&lt;P&gt;Happy Splunking!&lt;/P&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Wed, 23 Oct 2024 12:52:30 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/Filter-data-in-log-files/m-p/702595#M20595</guid>
      <dc:creator>Bhumi</dc:creator>
      <dc:date>2024-10-23T12:52:30Z</dc:date>
    </item>
    <item>
      <title>Re: Filter data in log files</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/Filter-data-in-log-files/m-p/702631#M20596</link>
      <description>&lt;P&gt;Wait a second. Does your raw data contain the string in quotes or without them?&lt;/P&gt;</description>
      <pubDate>Wed, 23 Oct 2024 20:31:07 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/Filter-data-in-log-files/m-p/702631#M20596</guid>
      <dc:creator>PickleRick</dc:creator>
      <dc:date>2024-10-23T20:31:07Z</dc:date>
    </item>
  </channel>
</rss>

