<?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: Splunk regex ignore fields before match in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Splunk-regex-ignore-fields-before-match/m-p/580155#M202151</link>
    <description>&lt;P&gt;I can't change the props level, it would have to be in the search itself.&lt;/P&gt;</description>
    <pubDate>Thu, 06 Jan 2022 19:05:25 GMT</pubDate>
    <dc:creator>leandromatperei</dc:creator>
    <dc:date>2022-01-06T19:05:25Z</dc:date>
    <item>
      <title>Splunk regex ignore fields before match</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Splunk-regex-ignore-fields-before-match/m-p/580149#M202148</link>
      <description>&lt;P&gt;I need to extract the contents of the message field into a json log, but the first strings must be ignored until 'stdout F', I can only get the one in front, the second timestamp&lt;BR /&gt;Any ideas how to do this?&lt;/P&gt;&lt;P&gt;Examples:&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;{ 
   app: app01
   message: 2022-01-06T17:57:25.799919642Z stdout F [2022-01-06 09:00:00,799]  INFO - INFO
   region: southamerica-east1
}

{ 
   app: app02
   message: 2022-01-06T17:57:25.799919642Z stdout F [2022-01-06 10:20:25,799]  ERROR - APIAuthenticationHandler API authentication failure
   region: southamerica-east1
}

{ 
   app: app03
   message: 2022-01-06T17:57:25.799919642Z stdout F [2022-01-06 12:57:00,799]  WARN - failure due to Invalid Credentials
   region: southamerica-east1
}

{ 
   app: app04
   message: 2022-01-06T17:57:25.799919642Z stdout F [2022-01-06 14:57:25,799]  WARN - APIAuthenticationHandler API authentication
   region: southamerica-east1
}&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 06 Jan 2022 18:26:57 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Splunk-regex-ignore-fields-before-match/m-p/580149#M202148</guid>
      <dc:creator>leandromatperei</dc:creator>
      <dc:date>2022-01-06T18:26:57Z</dc:date>
    </item>
    <item>
      <title>Re: Splunk regex ignore fields before match</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Splunk-regex-ignore-fields-before-match/m-p/580152#M202149</link>
      <description>&lt;P&gt;Are you trying to set indexing-time extraction? &amp;nbsp;You can force timestamp format in Splunk Web or TIME_FORMAT in props.conf for that sourcetype; the format would be "[%Y-%m-%d %H:%M:%S,%3N]" in your case.&lt;/P&gt;</description>
      <pubDate>Thu, 06 Jan 2022 18:52:16 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Splunk-regex-ignore-fields-before-match/m-p/580152#M202149</guid>
      <dc:creator>yuanliu</dc:creator>
      <dc:date>2022-01-06T18:52:16Z</dc:date>
    </item>
    <item>
      <title>Re: Splunk regex ignore fields before match</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Splunk-regex-ignore-fields-before-match/m-p/580155#M202151</link>
      <description>&lt;P&gt;I can't change the props level, it would have to be in the search itself.&lt;/P&gt;</description>
      <pubDate>Thu, 06 Jan 2022 19:05:25 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Splunk-regex-ignore-fields-before-match/m-p/580155#M202151</guid>
      <dc:creator>leandromatperei</dc:creator>
      <dc:date>2022-01-06T19:05:25Z</dc:date>
    </item>
    <item>
      <title>Re: Splunk regex ignore fields before match</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Splunk-regex-ignore-fields-before-match/m-p/580228#M202172</link>
      <description>&lt;P&gt;Try this&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| rex "message.*stdout F (?&amp;lt;message&amp;gt;.*)"&lt;/LI-CODE&gt;</description>
      <pubDate>Fri, 07 Jan 2022 08:08:16 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Splunk-regex-ignore-fields-before-match/m-p/580228#M202172</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2022-01-07T08:08:16Z</dc:date>
    </item>
    <item>
      <title>Re: Splunk regex ignore fields before match</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Splunk-regex-ignore-fields-before-match/m-p/580230#M202174</link>
      <description>&lt;P&gt;In this case, this should work&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| rex field=message "stdout F \[(?&amp;lt;time2&amp;gt;[^\]]+)"
| convert timeformat="%Y-%m-%d %H:%M:%S,%3N" mktime(time2)&lt;/LI-CODE&gt;&lt;P&gt;After convert, time2 will now contain epoch value. &amp;nbsp;If your intention is to use it as event _time, you can do&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| rex field=message "stdout F \[(?&amp;lt;time2&amp;gt;[^\]]+)"
| convert timeformat="%Y-%m-%d %H:%M:%S,%3N" mktime(time2) as _time&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 07 Jan 2022 08:17:37 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Splunk-regex-ignore-fields-before-match/m-p/580230#M202174</guid>
      <dc:creator>yuanliu</dc:creator>
      <dc:date>2022-01-07T08:17:37Z</dc:date>
    </item>
  </channel>
</rss>

