<?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: Stats by hour in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Stats-by-hour/m-p/74013#M18593</link>
    <description>&lt;P&gt;Thx for the reply and info. Added various sourcetypes in different queries and sometimes I see no results for the avg count, yet I see events. &lt;/P&gt;

&lt;P&gt;For one particular query I see 373k events, yet nothing is returned in the statistics tab even though the the days are being listed for the following query: index=myindex sourcetype=myindex | timechart span=1d avg(count)&lt;/P&gt;

&lt;P&gt;Thx&lt;/P&gt;</description>
    <pubDate>Fri, 16 Jan 2015 13:44:20 GMT</pubDate>
    <dc:creator>jwalzerpitt</dc:creator>
    <dc:date>2015-01-16T13:44:20Z</dc:date>
    <item>
      <title>Stats by hour</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Stats-by-hour/m-p/74007#M18587</link>
      <description>&lt;P&gt;I would like to create a table of count metrics based on hour of the day. So average hits at 1AM, 2AM, etc.&lt;/P&gt;

&lt;P&gt;stats min by date_hour, avg by date_hour, max by date_hour &lt;/P&gt;

&lt;P&gt;I can not figure out why this does not work.&lt;/P&gt;

&lt;P&gt;Here is the matrix I am trying to return. Assume 30 days of log data so 30 samples per each date_hour&lt;/P&gt;

&lt;P&gt;date_hour     count                  min                                                      ...&lt;BR /&gt;
1             (total for 1AM hour)  (min for 1AM hour; count for day with lowest hits at 1AM) &lt;BR /&gt;
2             (total for 2AM hour)  (min for 2AM hour; count for day with lowest hits at 2AM)&lt;BR /&gt;
3&lt;BR /&gt;
4&lt;BR /&gt;
...&lt;/P&gt;

&lt;P&gt;Would like to do max and percentiles as well to help understand typical and atypical hits at different times of day.&lt;/P&gt;</description>
      <pubDate>Mon, 28 Sep 2020 14:09:49 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Stats-by-hour/m-p/74007#M18587</guid>
      <dc:creator>motobeats</dc:creator>
      <dc:date>2020-09-28T14:09:49Z</dc:date>
    </item>
    <item>
      <title>Re: Stats by hour</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Stats-by-hour/m-p/74008#M18588</link>
      <description>&lt;UL&gt;
&lt;LI&gt;| timechart span=1h avg(count) ?&lt;/LI&gt;
&lt;/UL&gt;</description>
      <pubDate>Mon, 24 Jun 2013 22:39:03 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Stats-by-hour/m-p/74008#M18588</guid>
      <dc:creator>the_wolverine</dc:creator>
      <dc:date>2013-06-24T22:39:03Z</dc:date>
    </item>
    <item>
      <title>Re: Stats by hour</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Stats-by-hour/m-p/74009#M18589</link>
      <description>&lt;P&gt;What's wrong about this answer?&lt;/P&gt;</description>
      <pubDate>Tue, 25 Jun 2013 07:22:37 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Stats-by-hour/m-p/74009#M18589</guid>
      <dc:creator>Ayn</dc:creator>
      <dc:date>2013-06-25T07:22:37Z</dc:date>
    </item>
    <item>
      <title>Re: Stats by hour</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Stats-by-hour/m-p/74010#M18590</link>
      <description>&lt;P&gt;This gave me what I was looking for:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;bucket _time span=1h|stats count by _time date_hour|stats min(count), p25(count), p50(count), p75(count), max(count) by date_hour
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 25 Jun 2013 07:47:26 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Stats-by-hour/m-p/74010#M18590</guid>
      <dc:creator>motobeats</dc:creator>
      <dc:date>2013-06-25T07:47:26Z</dc:date>
    </item>
    <item>
      <title>Re: Stats by hour</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Stats-by-hour/m-p/74011#M18591</link>
      <description>&lt;P&gt;When I run the  | timechart span=1h avg(count) query, no stats are being returned and I can't figure out why&lt;/P&gt;</description>
      <pubDate>Thu, 15 Jan 2015 21:16:17 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Stats-by-hour/m-p/74011#M18591</guid>
      <dc:creator>jwalzerpitt</dc:creator>
      <dc:date>2015-01-15T21:16:17Z</dc:date>
    </item>
    <item>
      <title>Re: Stats by hour</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Stats-by-hour/m-p/74012#M18592</link>
      <description>&lt;P&gt;You would need to add some base search something like this (runanywhere query)&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=_internal sourcetype=splunkd | timechart span=1h avg(count)
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 15 Jan 2015 22:47:21 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Stats-by-hour/m-p/74012#M18592</guid>
      <dc:creator>somesoni2</dc:creator>
      <dc:date>2015-01-15T22:47:21Z</dc:date>
    </item>
    <item>
      <title>Re: Stats by hour</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Stats-by-hour/m-p/74013#M18593</link>
      <description>&lt;P&gt;Thx for the reply and info. Added various sourcetypes in different queries and sometimes I see no results for the avg count, yet I see events. &lt;/P&gt;

&lt;P&gt;For one particular query I see 373k events, yet nothing is returned in the statistics tab even though the the days are being listed for the following query: index=myindex sourcetype=myindex | timechart span=1d avg(count)&lt;/P&gt;

&lt;P&gt;Thx&lt;/P&gt;</description>
      <pubDate>Fri, 16 Jan 2015 13:44:20 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Stats-by-hour/m-p/74013#M18593</guid>
      <dc:creator>jwalzerpitt</dc:creator>
      <dc:date>2015-01-16T13:44:20Z</dc:date>
    </item>
    <item>
      <title>Re: Stats by hour</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Stats-by-hour/m-p/74014#M18594</link>
      <description>&lt;P&gt;What is it averaging? Count. Why? Why not take count without averaging it?&lt;/P&gt;</description>
      <pubDate>Thu, 11 Apr 2019 21:24:57 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Stats-by-hour/m-p/74014#M18594</guid>
      <dc:creator>MTravisVolker</dc:creator>
      <dc:date>2019-04-11T21:24:57Z</dc:date>
    </item>
    <item>
      <title>Re: Stats by hour</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Stats-by-hour/m-p/74015#M18595</link>
      <description>&lt;P&gt;For a very similar problem I had I solved it this way: &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index="my_Index" host="my:host" sourcetype="my:sourcetype"
| timechart count span=60m
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 11 Apr 2019 21:29:20 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Stats-by-hour/m-p/74015#M18595</guid>
      <dc:creator>MTravisVolker</dc:creator>
      <dc:date>2019-04-11T21:29:20Z</dc:date>
    </item>
    <item>
      <title>Re: Stats by hour</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Stats-by-hour/m-p/517531#M145533</link>
      <description>&lt;P&gt;This was my solution to an hourly count issue. I've sanitized it. But I created this for a dashboard which watches inbound firewall traffic by country ($token_value$) per hour. Both Allowed and Dropped traffic.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;index=firewall sourcetype=traffic action=* location=$token_value$ earliest=-1d@d latest=@d &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;| eval date_hour=strftime(_time, "%H") &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;| stats count as "Hourly Count" by action, location, date_hour &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;| sort date_hour by ascending&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 02 Sep 2020 16:06:15 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Stats-by-hour/m-p/517531#M145533</guid>
      <dc:creator>mosaicjwb</dc:creator>
      <dc:date>2020-09-02T16:06:15Z</dc:date>
    </item>
  </channel>
</rss>

