<?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: Unable to get the email alert ? Even when the alert condition is set to trigger when the number of  result is less then 0 ? in Alerting</title>
    <link>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248308#M12076</link>
    <description>&lt;P&gt;Hi Sekar, thanks  for your inputs on this. &lt;STRONG&gt;It worked&lt;/STRONG&gt;, It triggered email notification alerts to our mail id,  when an Splunk service went down. &lt;/P&gt;

&lt;P&gt;Yes I had already set the cron Job like what you had mentioned above.&lt;/P&gt;

&lt;P&gt;&lt;EM&gt;**/15 * * * *&lt;/EM&gt;*&lt;/P&gt;</description>
    <pubDate>Tue, 18 Oct 2016 14:45:39 GMT</pubDate>
    <dc:creator>Hemnaath</dc:creator>
    <dc:date>2016-10-18T14:45:39Z</dc:date>
    <item>
      <title>Unable to get the email alert ? Even when the alert condition is set to trigger when the number of  result is less then 0 ?</title>
      <link>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248300#M12068</link>
      <description>&lt;P&gt;Hi All,  I have used the below query to capture the &lt;STRONG&gt;splunk service status (Up or Down) via splunkd.log&lt;/STRONG&gt;. When executed with the time stamp as yesterday we are getting the output. But I want to configure an alert,  to run this  query for every 15 min and trigger an email alert with the output result. &lt;/P&gt;

&lt;P&gt;Query Details :&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;index=_internal host=hs* sourcetype=splunkd source="/opt/splunk/var/log/splunk/splunkd.log" "ShutdownHandler - shutting down level" OR "TailingProcessor -   Shutting down with*" | stats earliest(_time) AS Earliest, values(linecount) as Failures by host | convert ctime(Earliest)|addcoltotals label="Total" labelfield="Total_Number_of_Failures&lt;/STRONG&gt;&lt;/P&gt;

&lt;P&gt;Below are the configuration steps done to trigger an alert for every 15 min&lt;/P&gt;

&lt;P&gt;1) Set Alert type -&amp;gt; Scheduled &lt;BR /&gt;
2) Time Range --&amp;gt;  Run on Cron Scheduled &lt;BR /&gt;
3) Earliest --&amp;gt;  -15m &lt;BR /&gt;
4) Latest --&amp;gt; now&lt;BR /&gt;
5) Cron Expression --&amp;gt; */15 * * * *&lt;BR /&gt;
6) Trigger condition --&amp;gt;  Number of Results&lt;BR /&gt;
7) Trigger if number of results --&amp;gt; if less then 0 &lt;BR /&gt;
8) Email Action --&amp;gt; Send Email&lt;BR /&gt;
9) Include result --&amp;gt; inline&lt;BR /&gt;
10) Action option --&amp;gt; Once&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;Splunk version - 6.0.3&lt;/STRONG&gt; &lt;/P&gt;

&lt;P&gt;Kindly guide me on how to fix this problem to generate an alert for every 15 mins &lt;/P&gt;

&lt;P&gt;thanks in advance.&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 11:23:08 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248300#M12068</guid>
      <dc:creator>Hemnaath</dc:creator>
      <dc:date>2020-09-29T11:23:08Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to get the email alert ? Even when the alert condition is set to trigger when the number of  result is less then 0 ?</title>
      <link>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248301#M12069</link>
      <description>&lt;P&gt;the number of alerts can never be less than 0, so, it can never trigger the alert. &lt;/P&gt;

&lt;P&gt;Please set the condition as number of alerts if its greater than 0. &lt;/P&gt;

&lt;P&gt;6) Trigger condition --&amp;gt; Number of Results&lt;BR /&gt;
7) Trigger if number of results --&amp;gt; &lt;STRONG&gt;is greater than 0&lt;/STRONG&gt; &lt;/P&gt;</description>
      <pubDate>Fri, 14 Oct 2016 16:03:41 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248301#M12069</guid>
      <dc:creator>inventsekar</dc:creator>
      <dc:date>2016-10-14T16:03:41Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to get the email alert ? Even when the alert condition is set to trigger when the number of  result is less then 0 ?</title>
      <link>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248302#M12070</link>
      <description>&lt;P&gt;thanks sekar, Initially I had set the trigger condition as number of alerts if it greater than 0 and it did not work.  More over this condition will trigger an alert when there is an event generated.  So for testing purpose I had set the condition like this &lt;STRONG&gt;"Trigger if number of results --&amp;gt; if less then 0"&lt;/STRONG&gt; . So kindly let me know what  is going wrong ? why its not triggering the alert.&lt;/P&gt;

&lt;P&gt;thanks in advance. &lt;/P&gt;</description>
      <pubDate>Fri, 14 Oct 2016 17:04:17 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248302#M12070</guid>
      <dc:creator>Hemnaath</dc:creator>
      <dc:date>2016-10-14T17:04:17Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to get the email alert ? Even when the alert condition is set to trigger when the number of  result is less then 0 ?</title>
      <link>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248303#M12071</link>
      <description>&lt;OL&gt;
&lt;LI&gt;when you run this query, do you get results?!?!&lt;/LI&gt;
&lt;LI&gt;From other splunk alerts, do you receive email alerts? I mean, pls make sure the email notifications are working fine &lt;/LI&gt;
&lt;LI&gt;Do you have splunk admin access or user access&lt;/LI&gt;
&lt;/OL&gt;</description>
      <pubDate>Fri, 14 Oct 2016 17:14:01 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248303#M12071</guid>
      <dc:creator>inventsekar</dc:creator>
      <dc:date>2016-10-14T17:14:01Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to get the email alert ? Even when the alert condition is set to trigger when the number of  result is less then 0 ?</title>
      <link>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248304#M12072</link>
      <description>&lt;P&gt;yes, I am able to get the result while executing the query and even I was getting the email alerts, when &lt;STRONG&gt;Cron Expression&lt;/STRONG&gt;  alone was set to this value &lt;EM&gt;/15 * * * * but not getting the latest output. &lt;BR /&gt;
 so when I include **Time Range --&amp;gt; Earliest= -15m Latest=now&lt;/EM&gt;*, i am not getting the email alert.&lt;/P&gt;

&lt;P&gt;my requirement is to monitor the splunk services status for every 15 mins and should alert in case of failure of the service ( by capturing the splunkd.log) by executing the above query. But i am not whether the problem is with the splunk query or with the splunk configuration. &lt;/P&gt;

&lt;P&gt;Kindly guide me to fix this issue. thanks in advance.&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 11:23:39 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248304#M12072</guid>
      <dc:creator>Hemnaath</dc:creator>
      <dc:date>2020-09-29T11:23:39Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to get the email alert ? Even when the alert condition is set to trigger when the number of  result is less then 0 ?</title>
      <link>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248305#M12073</link>
      <description>&lt;P&gt;If that's the case, run the query from the command line and choose the past 15 minutes. Do you get results? &lt;/P&gt;</description>
      <pubDate>Sat, 15 Oct 2016 18:41:04 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248305#M12073</guid>
      <dc:creator>ddrillic</dc:creator>
      <dc:date>2016-10-15T18:41:04Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to get the email alert ? Even when the alert condition is set to trigger when the number of  result is less then 0 ?</title>
      <link>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248306#M12074</link>
      <description>&lt;P&gt;thanks all for throwing some lights on this issue. I am getting an email alert when I had set the following time range as we had some splunk service failure on last weekend. &lt;/P&gt;

&lt;P&gt;Time Range --&amp;gt; Earliest= -3d Latest=now. &lt;/P&gt;

&lt;P&gt;But when I had set the time range to -15m and latest=now, I am not getting any alert, so waiting for some failure to happen, so that I can validate the query.&lt;/P&gt;</description>
      <pubDate>Tue, 18 Oct 2016 12:05:24 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248306#M12074</guid>
      <dc:creator>Hemnaath</dc:creator>
      <dc:date>2016-10-18T12:05:24Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to get the email alert ? Even when the alert condition is set to trigger when the number of  result is less then 0 ?</title>
      <link>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248307#M12075</link>
      <description>&lt;P&gt;Hi Hemnaath, &lt;BR /&gt;
for cron schedule, did you set it like this - &lt;BR /&gt;
&lt;CODE&gt;*/15 * * * *&lt;/CODE&gt;&lt;BR /&gt;
if you have set it as "/15 *", please update it as above. &lt;/P&gt;</description>
      <pubDate>Tue, 18 Oct 2016 12:10:29 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248307#M12075</guid>
      <dc:creator>inventsekar</dc:creator>
      <dc:date>2016-10-18T12:10:29Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to get the email alert ? Even when the alert condition is set to trigger when the number of  result is less then 0 ?</title>
      <link>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248308#M12076</link>
      <description>&lt;P&gt;Hi Sekar, thanks  for your inputs on this. &lt;STRONG&gt;It worked&lt;/STRONG&gt;, It triggered email notification alerts to our mail id,  when an Splunk service went down. &lt;/P&gt;

&lt;P&gt;Yes I had already set the cron Job like what you had mentioned above.&lt;/P&gt;

&lt;P&gt;&lt;EM&gt;**/15 * * * *&lt;/EM&gt;*&lt;/P&gt;</description>
      <pubDate>Tue, 18 Oct 2016 14:45:39 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248308#M12076</guid>
      <dc:creator>Hemnaath</dc:creator>
      <dc:date>2016-10-18T14:45:39Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to get the email alert ? Even when the alert condition is set to trigger when the number of  result is less then 0 ?</title>
      <link>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248309#M12077</link>
      <description>&lt;P&gt;Great..nice to know that it worked. Can you please mark it as an accepted answer. &lt;/P&gt;</description>
      <pubDate>Tue, 18 Oct 2016 15:09:03 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248309#M12077</guid>
      <dc:creator>inventsekar</dc:creator>
      <dc:date>2016-10-18T15:09:03Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to get the email alert ? Even when the alert condition is set to trigger when the number of  result is less then 0 ?</title>
      <link>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248310#M12078</link>
      <description>&lt;P&gt;hey can you tell me where/how to check whether the saved search job is running or not in splunk. As I had set an saved search report to execute the query for every 2 hours but I had not set a email notification for the same. In this case how/where to check. &lt;/P&gt;

&lt;P&gt;thanks in advance. &lt;/P&gt;</description>
      <pubDate>Wed, 19 Oct 2016 09:44:42 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248310#M12078</guid>
      <dc:creator>Hemnaath</dc:creator>
      <dc:date>2016-10-19T09:44:42Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to get the email alert ? Even when the alert condition is set to trigger when the number of  result is less then 0 ?</title>
      <link>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248311#M12079</link>
      <description>&lt;P&gt;on your splunk, settings--&amp;gt; Searches, reports, and alerts, then find your saved search. &lt;BR /&gt;
on your saved search, under "actions" row, you can see "View recent | Run | Advanced edit | Clone | Move | Delete".  click "View recent".&lt;/P&gt;</description>
      <pubDate>Wed, 19 Oct 2016 10:16:17 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248311#M12079</guid>
      <dc:creator>inventsekar</dc:creator>
      <dc:date>2016-10-19T10:16:17Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to get the email alert ? Even when the alert condition is set to trigger when the number of  result is less then 0 ?</title>
      <link>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248312#M12080</link>
      <description>&lt;P&gt;thanks sekar, I need to set the cron job to execute the script every two hours and I have set the cron job but not sure why its not triggering the alert. Kindly guide we whether cron job is set correctly or not .&lt;/P&gt;

&lt;P&gt;Schedule Job for every two hours in a day. &lt;BR /&gt;
  00 &lt;EM&gt;/2 *&lt;/EM&gt;**&lt;/P&gt;

&lt;P&gt;thanks in advance. &lt;/P&gt;</description>
      <pubDate>Thu, 20 Oct 2016 15:19:31 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248312#M12080</guid>
      <dc:creator>Hemnaath</dc:creator>
      <dc:date>2016-10-20T15:19:31Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to get the email alert ? Even when the alert condition is set to trigger when the number of  result is less then 0 ?</title>
      <link>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248313#M12081</link>
      <description>&lt;P&gt;to schedule Job for every two hours in a day - &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;0 */2 * * *
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;The cron parameters, &lt;BR /&gt;
* * * * *, correspond to "minute" "hour" "day-of-month" "month" "day-of-week"&lt;/P&gt;

&lt;P&gt;Example expressions&lt;BR /&gt;
Here are some example cron expressions.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;*/5 * * * *       Every 5 minutes.
*/30 * * * *      Every 30 minutes.
0 */12 * * *      Every 12 hours, on the hour.
*/20  * * * 1-5   Every 20 minutes, Monday through Friday.
0 9 1-7 * 1       First Monday of each month, at 9am.
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 20 Oct 2016 15:29:50 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248313#M12081</guid>
      <dc:creator>inventsekar</dc:creator>
      <dc:date>2016-10-20T15:29:50Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to get the email alert ? Even when the alert condition is set to trigger when the number of  result is less then 0 ?</title>
      <link>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248314#M12082</link>
      <description>&lt;P&gt;thanks sekar, but I am having few doubts on scheduled saved searches ?&lt;BR /&gt;
1) where / how to find out whether the scheduled query had fetched the results.&lt;BR /&gt;
2) I want to schedule a cron job to execute every 2 hours and I had seen your above comments, based on that I had scheduled the cron like this.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;++/2 +++   Every 2 hours, on all days of the weeks /months 
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Note - Instead of star symbol I have used + to describe cron set up as I am unable to use star symbol in comments.&lt;/P&gt;

&lt;P&gt;But it seems it taking it has every 2 min, so kindly correct me on this too if this is not right way to configure the cron job for 2 hours.&lt;/P&gt;

&lt;P&gt;thanks in advance. &lt;/P&gt;</description>
      <pubDate>Fri, 21 Oct 2016 17:44:45 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248314#M12082</guid>
      <dc:creator>Hemnaath</dc:creator>
      <dc:date>2016-10-21T17:44:45Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to get the email alert ? Even when the alert condition is set to trigger when the number of  result is less then 0 ?</title>
      <link>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248315#M12083</link>
      <description>&lt;P&gt;Hi All, Can any one clarify my doubts on Splunk scheduled reports. &lt;/P&gt;

&lt;P&gt;1) where/how to find out whether the scheduled query had fetched the results after executing the query.&lt;/P&gt;

&lt;P&gt;2) I  had configured to schedule a cron job to execute every 2 hours and based on the above comments,  like this&lt;/P&gt;

&lt;P&gt;++/2 +++     Every 2 hours, on all days of the weeks /months.&lt;BR /&gt;
Kindly correct me if this not the right way to schedule the cron job.&lt;BR /&gt;
Note - Instead of star symbol I have used + to describe cron set up as I am unable to use star symbol in comments.&lt;BR /&gt;
 thanks in advance. &lt;/P&gt;</description>
      <pubDate>Mon, 24 Oct 2016 14:31:20 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248315#M12083</guid>
      <dc:creator>Hemnaath</dc:creator>
      <dc:date>2016-10-24T14:31:20Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to get the email alert ? Even when the alert condition is set to trigger when the number of  result is less then 0 ?</title>
      <link>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248316#M12084</link>
      <description>&lt;P&gt;Hi Hemnaath, &lt;BR /&gt;
1. on your splunk, settings--&amp;gt; Searches, reports, and alerts, then find your saved search. &lt;BR /&gt;
on your saved search, under "actions" row, you can see "View recent | Run | Advanced edit | Clone | Move | Delete". click "View recent". &lt;BR /&gt;
on this "Searches, reports, and alerts" page, you can see a column "Alerts", which says the alerts count. when you click View Recent, you can see how many events was fetched from your scheduled search. &lt;/P&gt;

&lt;OL&gt;
&lt;LI&gt; &lt;CODE&gt;0 */2 * * *&lt;/CODE&gt;      Every 2 hours, at the 0th min. 
&lt;CODE&gt;* */2 * * *&lt;/CODE&gt;  - i am not sure whether we can have a "*" for min.&lt;/LI&gt;
&lt;/OL&gt;</description>
      <pubDate>Fri, 28 Oct 2016 09:27:59 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248316#M12084</guid>
      <dc:creator>inventsekar</dc:creator>
      <dc:date>2016-10-28T09:27:59Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to get the email alert ? Even when the alert condition is set to trigger when the number of  result is less then 0 ?</title>
      <link>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248317#M12085</link>
      <description>&lt;P&gt;thanks sekar. &lt;/P&gt;</description>
      <pubDate>Thu, 03 Nov 2016 09:25:24 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/Unable-to-get-the-email-alert-Even-when-the-alert-condition-is/m-p/248317#M12085</guid>
      <dc:creator>Hemnaath</dc:creator>
      <dc:date>2016-11-03T09:25:24Z</dc:date>
    </item>
  </channel>
</rss>

