How to add a dropdown menu in Grafana?

19.3k Views Asked by At

I need a way to add a Dropdown menu ( or similar solution ) to show the metrics for only one cpu ( cpu 1 or cpu 0 ). Is this possible? The metric is node_cpu_seconds_total

enter image description here

1

There are 1 best solutions below

3
On BEST ANSWER
  1. Create a custom variable named "cpu" with values 0 and 1 in Dashboard settings > Variables > New

enter image description here

  1. Create the graph panel using the cpu variable (use the ":pipe" suffix to enable the use of 0 and 1 options at the same time)

enter image description here

  1. The CPU can be selected in the dropdown menu

enter image description here