<?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: Confused with Trigger Conditions - Confused by Documentation in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Confused-with-Trigger-Conditions-Confused-by-Documentation/m-p/390434#M168769</link>
    <description>&lt;P&gt;Look at the very last paragraph of each section.&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;THE FIRST ONE&lt;/STRONG&gt; &lt;/P&gt;

&lt;BLOCKQUOTE&gt;
&lt;P&gt;In this scenario, the original search&lt;BR /&gt;
results detail the count for all log&lt;BR /&gt;
levels, but the alert triggers only&lt;BR /&gt;
when the log_level counts are greater&lt;BR /&gt;
than ten. This means that all&lt;BR /&gt;
log_level counts are available to use&lt;BR /&gt;
as part of an alert notification.&lt;/P&gt;
&lt;/BLOCKQUOTE&gt;

&lt;P&gt;&lt;STRONG&gt;THE SECOND ONE&lt;/STRONG&gt;&lt;/P&gt;

&lt;BLOCKQUOTE&gt;
&lt;P&gt;In this case, the search results&lt;BR /&gt;
include only &lt;CODE&gt;log_level&lt;/CODE&gt; values that&lt;BR /&gt;
are greater than ten. By comparison,&lt;BR /&gt;
using a search with conditional&lt;BR /&gt;
triggering in the previous example&lt;BR /&gt;
means that results include counts for&lt;BR /&gt;
all log level fields.&lt;/P&gt;
&lt;/BLOCKQUOTE&gt;

&lt;HR /&gt;

&lt;P&gt;To reiterate:&lt;/P&gt;

&lt;P&gt;In the first version, the search includes all results, regardless of the count.  If there is any single result that triggers the alert, then the alert will include all results.&lt;/P&gt;

&lt;P&gt;In the second version, only the particular results that trigger the alert will be sent.&lt;/P&gt;</description>
    <pubDate>Tue, 29 Sep 2020 20:02:57 GMT</pubDate>
    <dc:creator>DalJeanis</dc:creator>
    <dc:date>2020-09-29T20:02:57Z</dc:date>
    <item>
      <title>Confused with Trigger Conditions - Confused by Documentation</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Confused-with-Trigger-Conditions-Confused-by-Documentation/m-p/390433#M168768</link>
      <description>&lt;P&gt;I am reading the documentation at the following page: &lt;A href="http://docs.splunk.com/Documentation/Splunk/7.1.1/Alert/AlertTriggerConditions" target="_blank"&gt;http://docs.splunk.com/Documentation/Splunk/7.1.1/Alert/AlertTriggerConditions&lt;/A&gt; &lt;/P&gt;

&lt;P&gt;The parts that do not make sense to me are, "Using a search with custom trigger condition" and then the next section of the webpage, "Using a search without a trigger condition". Both of these searches look the same. What is the difference between these two searches?  Could someone please point out what is the trigger condition? &lt;/P&gt;

&lt;P&gt;Here are the searches. The first one is the search with the custom trigger condition: &lt;STRONG&gt;index=_internal (log_level=ERROR OR log_level=FATAL OR log_level=CRITICAL) | stats count by log_level&lt;/STRONG&gt;&lt;/P&gt;

&lt;P&gt;The next search is the one without the custom trigger condition: &lt;BR /&gt;
&lt;STRONG&gt;log_level=ERROR OR log_level=FATAL OR log_level=CRITICAL) | stats count by log_level | search count &amp;gt; 10&lt;/STRONG&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 20:02:52 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Confused-with-Trigger-Conditions-Confused-by-Documentation/m-p/390433#M168768</guid>
      <dc:creator>rogue_carrot</dc:creator>
      <dc:date>2020-09-29T20:02:52Z</dc:date>
    </item>
    <item>
      <title>Re: Confused with Trigger Conditions - Confused by Documentation</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Confused-with-Trigger-Conditions-Confused-by-Documentation/m-p/390434#M168769</link>
      <description>&lt;P&gt;Look at the very last paragraph of each section.&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;THE FIRST ONE&lt;/STRONG&gt; &lt;/P&gt;

&lt;BLOCKQUOTE&gt;
&lt;P&gt;In this scenario, the original search&lt;BR /&gt;
results detail the count for all log&lt;BR /&gt;
levels, but the alert triggers only&lt;BR /&gt;
when the log_level counts are greater&lt;BR /&gt;
than ten. This means that all&lt;BR /&gt;
log_level counts are available to use&lt;BR /&gt;
as part of an alert notification.&lt;/P&gt;
&lt;/BLOCKQUOTE&gt;

&lt;P&gt;&lt;STRONG&gt;THE SECOND ONE&lt;/STRONG&gt;&lt;/P&gt;

&lt;BLOCKQUOTE&gt;
&lt;P&gt;In this case, the search results&lt;BR /&gt;
include only &lt;CODE&gt;log_level&lt;/CODE&gt; values that&lt;BR /&gt;
are greater than ten. By comparison,&lt;BR /&gt;
using a search with conditional&lt;BR /&gt;
triggering in the previous example&lt;BR /&gt;
means that results include counts for&lt;BR /&gt;
all log level fields.&lt;/P&gt;
&lt;/BLOCKQUOTE&gt;

&lt;HR /&gt;

&lt;P&gt;To reiterate:&lt;/P&gt;

&lt;P&gt;In the first version, the search includes all results, regardless of the count.  If there is any single result that triggers the alert, then the alert will include all results.&lt;/P&gt;

&lt;P&gt;In the second version, only the particular results that trigger the alert will be sent.&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 20:02:57 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Confused-with-Trigger-Conditions-Confused-by-Documentation/m-p/390434#M168769</guid>
      <dc:creator>DalJeanis</dc:creator>
      <dc:date>2020-09-29T20:02:57Z</dc:date>
    </item>
    <item>
      <title>Re: Confused with Trigger Conditions - Confused by Documentation</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Confused-with-Trigger-Conditions-Confused-by-Documentation/m-p/390435#M168770</link>
      <description>&lt;P&gt;Thank-you for the reply DalJeanis. Could you please explicitly point out the trigger condition also? &lt;/P&gt;</description>
      <pubDate>Wed, 20 Jun 2018 23:19:20 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Confused-with-Trigger-Conditions-Confused-by-Documentation/m-p/390435#M168770</guid>
      <dc:creator>rogue_carrot</dc:creator>
      <dc:date>2018-06-20T23:19:20Z</dc:date>
    </item>
    <item>
      <title>Re: Confused with Trigger Conditions - Confused by Documentation</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Confused-with-Trigger-Conditions-Confused-by-Documentation/m-p/390436#M168771</link>
      <description>&lt;P&gt;Forgive me for not answering your question but let me give you some advice that will eliminate the need for an answer.  It is a best practice to never use the &lt;CODE&gt;savedsearches.conf&lt;/CODE&gt; threshold settings.  The threshold conditions should &lt;EM&gt;always&lt;/EM&gt; be contained in the search SPL.  Here is why.  The people who will be handling the search alert will &lt;EM&gt;first&lt;/EM&gt; receive the email and you need for them to be able to see what the threshold actually was.  If this is the last part of the search SPL, they will be able to see it.  Some of these people will not even have access to Splunk to go to the search definition and most that do will not understand that they need to.  So KISS and put the "real" threshold into the search SPL and then always use a &lt;CODE&gt;savedsearches.conf&lt;/CODE&gt; trigger setting of &lt;CODE&gt;if number of events &amp;gt; 0&lt;/CODE&gt;.&lt;/P&gt;</description>
      <pubDate>Sat, 30 Jun 2018 23:21:22 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Confused-with-Trigger-Conditions-Confused-by-Documentation/m-p/390436#M168771</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2018-06-30T23:21:22Z</dc:date>
    </item>
  </channel>
</rss>

