<?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: Time periods for query and alert in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Time-periods-for-query-and-alert/m-p/486012#M141568</link>
    <description>&lt;P&gt;Yes. Query will run for last 24 hours irrespective of Time Range set.&lt;/P&gt;</description>
    <pubDate>Thu, 05 Mar 2020 10:00:33 GMT</pubDate>
    <dc:creator>manjunathmeti</dc:creator>
    <dc:date>2020-03-05T10:00:33Z</dc:date>
    <item>
      <title>Time periods for query and alert</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Time-periods-for-query-and-alert/m-p/486009#M141565</link>
      <description>&lt;P&gt;Hi there!&lt;BR /&gt;I'm running this query &lt;CODE&gt;index="staging" |eval raw_len=len(_raw) | eval raw_len_gb = raw_len/1024/1024/1024 | stats sum(raw_len_gb) as GB by kubernetes_namespace |  where GB &amp;gt; 0.5&lt;/CODE&gt;&lt;BR /&gt;When I'm running this query in "Search", I choose "For the last 24 hours".&lt;BR /&gt;I want to save this query as alert, and the alert will run let's say once a hour.&lt;BR /&gt;The question is - will it run this query like I run it in search (last 24 hours)? Or I need to specify it inside a query (last 24 hours)?&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;
&lt;P&gt;Aleksei&lt;/P&gt;</description>
      <pubDate>Wed, 24 Jun 2020 18:35:15 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Time-periods-for-query-and-alert/m-p/486009#M141565</guid>
      <dc:creator>alekseisaiko</dc:creator>
      <dc:date>2020-06-24T18:35:15Z</dc:date>
    </item>
    <item>
      <title>Re: Time periods for query and alert</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Time-periods-for-query-and-alert/m-p/486010#M141566</link>
      <description>&lt;P&gt;Once you run the search for last 24 hours and save it as an alert. Then alert runs search for for last 24 hours. You don't need to specify earliest and latest in search query.&lt;/P&gt;

&lt;P&gt;You can also check &lt;STRONG&gt;Time Range&lt;/STRONG&gt; in &lt;STRONG&gt;Edit Alert&lt;/STRONG&gt; page.&lt;/P&gt;

&lt;P&gt;Alert configuration in savedsearches.conf are stored as below:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[alert_name]
search = &amp;lt;search_query&amp;gt;
dispatch.earliest_time = -24h@h
dispatch.latest_time = now
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Wed, 04 Mar 2020 21:48:12 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Time-periods-for-query-and-alert/m-p/486010#M141566</guid>
      <dc:creator>manjunathmeti</dc:creator>
      <dc:date>2020-03-04T21:48:12Z</dc:date>
    </item>
    <item>
      <title>Re: Time periods for query and alert</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Time-periods-for-query-and-alert/m-p/486011#M141567</link>
      <description>&lt;P&gt;Thanks,&lt;/P&gt;

&lt;P&gt;And what i I will add &lt;CODE&gt;earliest=-24h&lt;/CODE&gt; to the query as well? It will always run the query and give results for the last 24 hours?&lt;/P&gt;</description>
      <pubDate>Thu, 05 Mar 2020 09:52:50 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Time-periods-for-query-and-alert/m-p/486011#M141567</guid>
      <dc:creator>alekseisaiko</dc:creator>
      <dc:date>2020-03-05T09:52:50Z</dc:date>
    </item>
    <item>
      <title>Re: Time periods for query and alert</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Time-periods-for-query-and-alert/m-p/486012#M141568</link>
      <description>&lt;P&gt;Yes. Query will run for last 24 hours irrespective of Time Range set.&lt;/P&gt;</description>
      <pubDate>Thu, 05 Mar 2020 10:00:33 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Time-periods-for-query-and-alert/m-p/486012#M141568</guid>
      <dc:creator>manjunathmeti</dc:creator>
      <dc:date>2020-03-05T10:00:33Z</dc:date>
    </item>
    <item>
      <title>Re: Time periods for query and alert</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Time-periods-for-query-and-alert/m-p/486013#M141569</link>
      <description>&lt;P&gt;Got it, thanks a lot for your answer!&lt;/P&gt;</description>
      <pubDate>Thu, 05 Mar 2020 10:06:12 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Time-periods-for-query-and-alert/m-p/486013#M141569</guid>
      <dc:creator>alekseisaiko</dc:creator>
      <dc:date>2020-03-05T10:06:12Z</dc:date>
    </item>
    <item>
      <title>Re: Time periods for query and alert</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Time-periods-for-query-and-alert/m-p/486014#M141570</link>
      <description>&lt;P&gt;you're welcome.&lt;/P&gt;</description>
      <pubDate>Fri, 06 Mar 2020 08:16:04 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Time-periods-for-query-and-alert/m-p/486014#M141570</guid>
      <dc:creator>manjunathmeti</dc:creator>
      <dc:date>2020-03-06T08:16:04Z</dc:date>
    </item>
  </channel>
</rss>

