<?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: How to specify a time range inside a search in Dashboards &amp; Visualizations</title>
    <link>https://community.splunk.com/t5/Dashboards-Visualizations/Status-indicators-and-uptime-calculation/m-p/543794#M37288</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/161352"&gt;@gcusello&lt;/a&gt;&amp;nbsp;, Thanks for your reply.&amp;nbsp;&lt;/P&gt;&lt;P&gt;But it is not working. not sure how to get the duration&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 15 Mar 2021 09:13:32 GMT</pubDate>
    <dc:creator>mariamathewtel</dc:creator>
    <dc:date>2021-03-15T09:13:32Z</dc:date>
    <item>
      <title>Status indicators and uptime calculation</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/Status-indicators-and-uptime-calculation/m-p/543784#M37285</link>
      <description>&lt;P&gt;Hi, I am trying to build a dashboard with some status indicators and uptime gauges.&amp;nbsp; Below are the few sample logs.&lt;/P&gt;&lt;P&gt;&lt;EM&gt;2021-02-21 13:48:42,744 (DEBUG) Thread_^[OP].* BATCH ID(31673) response (Internal Server Error, 500)&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;2021-02-21 13:48:42,741 (DEBUG) Thread_^[KL].* BATCH ID(62422) response (Internal Server Error, 500)&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;2021-02-21 13:48:31,620 (DEBUG) Thread_^[UV].* BATCH ID(40284) response (OK, 200)&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;2021-02-21 13:47:41,991 (DEBUG) Thread_^[OP].* BATCH ID(31672) response (OK, 200)&lt;/EM&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Created a status indicator for last 10 minutes as in the below query.&lt;/P&gt;&lt;P&gt;&lt;EM&gt;index="abc"&amp;nbsp;&lt;/EM&gt;&lt;EM&gt;| eval Indicator=if(Response=="(OK, 200)", "UP", "DOWN")&lt;BR /&gt;| stats&lt;BR /&gt;count(eval(if(Indicator="UP", 1, null()))) as UP_count&lt;BR /&gt;count(eval(if(Indicator="DOWN", 1, null()))) as DOWN_count&lt;BR /&gt;count(Indicator) as "TotalCount"&lt;BR /&gt;| eval SI = case(UP_count&amp;gt;0,"UP", UP_count==0,"DOWN")&lt;BR /&gt;|&amp;nbsp;table SI&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;Result will be either UP or DOWN.&lt;/P&gt;&lt;P&gt;Now I am trying to create a uptime gauge which will display the time from which the value of SI is UP.&lt;/P&gt;&lt;P&gt;For example, if the value of SI&amp;nbsp; was DOWN for sometime and the connection restored and SI = UP from last 2 days, the uptime will be like&amp;nbsp;&lt;BR /&gt;&lt;EM&gt;2 days, 30 minutes, 40 seconds&lt;/EM&gt;&lt;BR /&gt;Can anyone please help me with this.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 16 Mar 2021 05:04:39 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/Status-indicators-and-uptime-calculation/m-p/543784#M37285</guid>
      <dc:creator>mariamathewtel</dc:creator>
      <dc:date>2021-03-16T05:04:39Z</dc:date>
    </item>
    <item>
      <title>Re: How to specify a time range inside a search</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/Status-indicators-and-uptime-calculation/m-p/543786#M37286</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/34184"&gt;@mariamathewtel&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;you can solve your problem in two ways:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;using transpose (it's easier but less performant),&lt;/LI&gt;&lt;LI&gt;using stats (more complex but more performant).&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;using transpose.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;index="abc" | eval Indicator=if(Response=="(OK, 200)", "UP", "DOWN")
| transpose startswith="Internal Server Error" endswith="OK,200"
| table duration
| eval duration=tostring("duration")&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Ciao.&lt;/P&gt;&lt;P&gt;Giuseppe&lt;/P&gt;</description>
      <pubDate>Mon, 15 Mar 2021 07:40:23 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/Status-indicators-and-uptime-calculation/m-p/543786#M37286</guid>
      <dc:creator>gcusello</dc:creator>
      <dc:date>2021-03-15T07:40:23Z</dc:date>
    </item>
    <item>
      <title>Re: How to specify a time range inside a search</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/Status-indicators-and-uptime-calculation/m-p/543794#M37288</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/161352"&gt;@gcusello&lt;/a&gt;&amp;nbsp;, Thanks for your reply.&amp;nbsp;&lt;/P&gt;&lt;P&gt;But it is not working. not sure how to get the duration&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 15 Mar 2021 09:13:32 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/Status-indicators-and-uptime-calculation/m-p/543794#M37288</guid>
      <dc:creator>mariamathewtel</dc:creator>
      <dc:date>2021-03-15T09:13:32Z</dc:date>
    </item>
    <item>
      <title>Re: How to specify a time range inside a search</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/Status-indicators-and-uptime-calculation/m-p/543809#M37290</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/34184"&gt;@mariamathewtel&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;check if the transpose correlates the events; if yes, the duration is automatically calculated.&lt;/P&gt;&lt;P&gt;Ciao.&lt;/P&gt;&lt;P&gt;Giuseppe&lt;/P&gt;</description>
      <pubDate>Mon, 15 Mar 2021 10:09:40 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/Status-indicators-and-uptime-calculation/m-p/543809#M37290</guid>
      <dc:creator>gcusello</dc:creator>
      <dc:date>2021-03-15T10:09:40Z</dc:date>
    </item>
    <item>
      <title>Re: How to specify a time range inside a search</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/Status-indicators-and-uptime-calculation/m-p/543814#M37293</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/161352"&gt;@gcusello&lt;/a&gt;&amp;nbsp;,&lt;BR /&gt;For transpose command , i am getting an error like below&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Error in 'transpose' command: Numerical limit expected.&lt;/EM&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 15 Mar 2021 10:27:55 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/Status-indicators-and-uptime-calculation/m-p/543814#M37293</guid>
      <dc:creator>mariamathewtel</dc:creator>
      <dc:date>2021-03-15T10:27:55Z</dc:date>
    </item>
  </channel>
</rss>

