Splunk Search

Stats table drilldown help

codedtech
Path Finder

I want to create a drill down that will go from a value on a stats table a time chart for the clicked pool name in a new tab, I've been at this for a few hours now and I can't seem to get it to work.

Here is the current XML:

<panel>
 <table>
 <title>Pool Stats</title>
    <search>
      <query>index=Stuff| SERVER_NAME="$SERVER_NAME$"|dedup POOL_NAME|stats avg(eval(if(PCT_UTILIZED==0,null(),PCT_UTILIZED))) as Used by POOL_NAME|sort -Used | head 10</query>
      <earliest>0</earliest>
      <latest></latest>
    </search>
    <option name="drilldown">row</option>
  </table>    

Thanks in advance.

0 Karma

gcusello
SplunkTrust
SplunkTrust

Hi codedtech,
you have to use the web interface or to add thes lines to your source after the option tag:

 <panel>
  <table>
  <title>Pool Stats</title>
     <search>
       <query>index=Stuff| SERVER_NAME="$SERVER_NAME$"|dedup POOL_NAME|stats avg(eval(if(PCT_UTILIZED==0,null(),PCT_UTILIZED))) as Used by POOL_NAME|sort -Used | head 10</query>
       <earliest>0</earliest>
       <latest></latest>
     </search>
     <option name="drilldown">row</option>
     <drilldown>
          <link target="_blank">/app/imy_app/drilldown_dashboard?POOL_NAME=$row.POOL_NAME$</link>
     </drilldown>
     </table> 

in this way, in the new dashboard you have to use the token named "POOL_NAME".
If you want to pass also the time borders of your search use the following.

 <drilldown>
      <link target="_blank">/app/imy_app/drilldown_dashboard?TimeFrom=$Time.earliest$&TimeTo=$Time.latest$&POOL_NAME=$row.POOL_NAME$</link>
 </drilldown>

In this case, you have to manage in the second dashboard three tokens.

Remember that for a problem on the editor the "&" char must be translated into "&".

As a guide, you can see the Splunk Dashboard Examples App ( https://splunkbase.splunk.com/app/1603/ ).

Bye.
Giuseppe

0 Karma
Career Survey
First 500 qualified respondents will receive a $20 gift card! Tell us about your professional Splunk journey.

Can’t make it to .conf25? Join us online!

Get Updates on the Splunk Community!

Community Content Calendar, September edition

Welcome to another insightful post from our Community Content Calendar! We're thrilled to continue bringing ...

Splunkbase Unveils New App Listing Management Public Preview

Splunkbase Unveils New App Listing Management Public PreviewWe're thrilled to announce the public preview of ...

Leveraging Automated Threat Analysis Across the Splunk Ecosystem

Are you leveraging automation to its fullest potential in your threat detection strategy?Our upcoming Security ...