Drilldowns using dashboard variables

Dashboard variables allow you to pass variables to another dashboard, so you can create your own drilldown dashboard to show further data detail. Dashboard variables are available for SolarWinds, Prometheus and VMware integrations (DS v7.1 and above).

How do dashboard variables work?

Create your own variable name and add it to the link in the tile configuration on your top-level dashboard.

When the visualization is clicked the link takes you to the drilldown dashboard and the variable is passed to the tiles which have been configured to use that variable.

  1. Configure the top-level dashboard:
    • In the tile link paste in the GUID URL for the drilldown dashboard.
    • Add the variable name(s) and dynamic variable value(s) to the URL.
  2. Configure the drilldown dashboard tile:
    • Set Use Variables to ON.
    • Configure the tile(s) to use the variables.

For VMware, variable values can be used in the Scope and Metrics panels of tiles on the drilldown dashboard. For Prometheus and SolarWinds, variable values can be passed to the drilldown dashboard to be used in the query panels.

For example, you could pass one or more VM IDs to show more details about the VMs, such as on a Grid or as Status blocks.

Or, you could pass VM IDs and metric names to a performance graph. When you click on a data line you see that data in more detail, and if you click on the graph background you see all data lines.

What do I need to consider regarding data security?

Drilldown dashboards should be placed in Team Folders with the appropriate access restrictions, so you can restrict access to trusted users.

Users can edit the URL parameter value, so do not expose drilldown dashboards to untrusted users.

How do I configure dashboard variables?

Here we are going to create a simple top-level dashboard, with one tile, that passes a variable to a simple drilldown dashboard that shows more detailed data.

You can, of course, add more than one tile to the top-level dashboard and the drilldown dashboard later.

Configure the top-level dashboard

  1. Create the top-level dashboard.
    Add one or more SolarWinds, Prometheus or VMware tiles, using any of the visualizations.
    For example, for VMware you might add a Donut visualization to show hosts.
  2. Create the drilldown dashboard.
    Just create, name and publish the dashboard for now, so we can use the sharing URL in the configuration of the top-level dashboard.
  3. Configure the top-level dashboard.
    Return to your top-level dashboard, edit the tile, and locate the link option. For most tiles the link is in the Link Options panel. For Grid visualizations it is Grid Options > Row Link and for Web Content tiles it is Content > URL
    1. Enter the path to the drilldown dashboard:
      You can get the path by opening the drilldown dashboard and clicking the Share this dashboard button when you're not in Edit mode.

      It's best to use the GUID URL of the drilldown dashboard, as this won't change. If you use the friendly name this will change if the dashboard is renamed.


      Copy the normal sharing link and paste it into the link box in your tile.
    2. Variable name:
      Decide on a variable name, and after the GUID URL type:
      ?var-<VariableName>

      Variable names are case sensitive and cannot contain whitespace.

    3. Insert the variable dynamic value:
      Type = and then click on the Insert dynamic value button, and select the property to be added to the URL.

      The completed path will use the following format:
      https://SquaredUpServer/Instance/page/<GUID>?var-<variable name>=<dynamic variable value>
      For example:
      https://Server1/SquaredUp/page/1033c2bb-0056-48ac-963d-8571adaec119?var-VMvariable={{properties.id}}

      If your drilldown dashboard is using the variable in the scope then the property must be an ID that can be used by the scope. If the drilldown dashboard is showing metrics then the variable must be a metric. You can pass both scope and metric variables.


      See also How do I pass more than one variable?

Configure the drilldown dashboard

  1. Open the drilldown dashboard you created earlier, and add a SolarWinds, Prometheus or VMware tile to show the data detail when you click on a visualization on your top-level dashboard. You might like to start with a Grid or Line graph visualization, but you can change this later. For example, for VMware you could add a Grid visualization.
  2. Configure the drilldown dashboard.
    1. Set Use Variables to ON.
      Edit the tile and at the top of the tile toggle Use Variables to ON.
    2. Configure the scope.
      Configure the scope of the tile to show data of the type being passed from the top-level dashboard.
      For example, for VMware set the Object type to Virtual Machine, and select Objects.
    3. Configure the variables.
      VMware

      Variable values can be used in the Scope and Metric panels. In the Scope panel tick Use variable for this input. If the tile uses metrics you can either configure the metric, or tick Use variable for this input in the Metric panel to use a metric passed down from the top-level dashboard.For example, for a VMware Grid visualization you would only tick Use variable for this input in the Scope panel.
      Enter the variable name used in the top-level dashboard tile.
      SolarWinds and Prometheus
      Variable values can be used in the Query panel of the tile configuration. Click on the Insert variable button, and select the variable to be added to the query.
      See examples of how variables can be used with Prometheus and SolarWinds.
    4. Enter default values for the variables.
      Click the Variables button to set the default variables that will be used if the dashboard is browsed to, rather than drilled down to. This means the dashboard will show data, for example for one or several objects, as a default, rather than being blank.

How do I pass more than one variable?

You can use normal URL query formatting to pass more than one parameter. The question mark (?) indicates that query parameters are to follow, and multiple parameters are separated by ampersands (&).

?var-VariableName={{property}}&var-VariableName={{property}}

For example, for a VMware line graph:

https://Server1/SquaredUp/page/1033c2bb-0056-48ac-963d-8571adaec119?var-TestID={{id}}&var-TestMetric={{properties.label}}

You can of course have several tiles on the top-level dashboard, and each tile can link to the same or different drilldown dashboards.

Configuring default variables

Default variable values are used when the dashboard is opened directly (not via drilldown). If the URL passes a variable, the URL value overrides the default.

If the dashboard is browsed to, there won't be any variables passed down to it, as there would if the user had clicked on a visualization on your top-level dashboard. So that the drilldown dashboard isn't blank in this situation, you can configure some default dashboard variables, by clicking the Variables button at the top of the page.

Variable name

Variable names are case sensitive and cannot contain whitespace.

The Variable name specified in the link of the tiles on the top-level dashboard must match the variable name specified in the tile configuration Use variable for this input, var-VariableName of the drilldown dashboard, and optionally in the Default Variables panel of the drilldown dashboard.

Default value

This is the value that the dashboard will use for the variable if no value is passed to it, i.e. a default value. Multi-value variable values should be separated by a comma.

If a dashboard URL passes in the same variable, but with a different value, then the URL’s value will override the default value.

The Open Access view of a drilldown dashboard does not accept URL parameters for dashboard variables, and will only use default variable values if present.

VMware example

For VMware you can either pass the VM ID (mostly {{properties.id}}, but {{id}} for Grid visualizations) or a Metric to the drilldown dashboard, because the tiles on the drilldown page can only use variables for scope and/or metric. Only the VM ID {{properties.id}} can be used, not the VM name property for example, because the scope of VMware tiles uses {{properties.id}}, and other properties are not recognized.

Example:

Top-level dashboard

VMware Line graph

Scope: Virtual Machine > Folders > host

Metric: L1 > Memory / Host consumed % / average / %

Link Options > Item Link: https://SquaredUpServer/Instance/page/<GUID>?var-TestVM={{id}}&var-TestMetric={{properties.label}}

Drilldown dashboard

(Sharing URL https://SquaredUpServer/Instance/page/<GUID>)

VMware Line graph with Use Variables set to ON.

Scope: Virtual Machine > Objects> Use variable for this input > var-TestVM

Metric: L1 > Use variable for this input > var-TestMetric

Prometheus example

Top-level dashboard

Prometheus Grid tile

Query:

up{job="automation"}

Configure the Row Link:
https://SquaredUpServer/Instance/page/<GUID>?var-prometheusScope={{instance}}

Drilldown dashboard

Prometheus Bar graph with Use Variables set to ON.

Query:

100 - (avg by (instance) (
  rate(windows_cpu_time_total{mode="idle",
       instance=~"{{variables.prometheusScope}}"
       }[5m])
) * 100)

SolarWinds example

Top-level dashboard

SolarWinds Grid tile

Query:

SELECT
    N.NodeID,
    N.Caption,
    N.IPAddress,
    N.Vendor,
    N.MachineType,
    N.Status,
    N.StatusDescription,
    N.EngineID,
    N.LastBoot
FROM Orion.Nodes N
WHERE N.Caption LIKE '%-Core%'
ORDER BY N.Caption

Configure the Row Link:

https://SquaredUpServer/Instance/page/<GUID>?var-solarwindsScope={{NodeID}}

Drilldown dashboard

SolarWinds Column graph with Use Variables set to ON.

Query:

SELECT N.Caption, RT.DateTime, RT.AvgResponseTime, RT.PercentLoss 
FROM Orion.ResponseTime RT 
JOIN Orion.Nodes N ON N.NodeID = RT.NodeID
WHERE N.NodeID = {{variables.solarwindsScope}}

Was this article helpful?


Have more questions or facing an issue?