Questions tagged [grafana-variable]
245 questions
1
vote
0 answers
How to sort alerts from Prometheus correctly in the Grafana panel
We have several alerts from Prometheus, we would like to visualize them in tables on the Grafana dashboard in the alert list. We would like to sort the alerts by severity and later by environment.
So the severities…

BranoBar
- 11
- 3
1
vote
1 answer
Creating a Grafana query variable based on a manipulated version of another one
I have a grafana dashboard that I want to filter by 2 variables:
Kubernetes namespace (which I can easily get from Prometheus)
AWS SQS Queue - get only the queues whose names are contained in the namespace from #1
This is relatively easy - I…

KidCrippler
- 1,633
- 2
- 19
- 34
1
vote
1 answer
Grafana for a variable, get values from multiple labels for one metric
I hope you're having a nice day.
To create a variable in Grafana for a dashboard I need to get values from multiple labels from a metric :
dbinstance_identifier & dbcluster_identifier
To get the values in my variable i use the function…

A.Jean
- 25
- 3
1
vote
0 answers
Variable - MySQL Query - Timestamp Converted To Unixtime
I am using Grafana 8.3.4
In the Dashboard Settings->Variables, I am using MySQL query as the data source.
Even though the values are stored in datetime format in database, it is getting converted to unixtime in variables.
For eg: values in the…

user3198755
- 477
- 2
- 10
- 21
1
vote
1 answer
Dependent variable in grafana
I have a custom variable in grafana $var, which has values ["option1", "option2", "option3"]. I would like to have another custom (hidden) variable $auxvar where the value is entirely dependent on the value of $var, e.g.:
"option1" ->…

mfd
- 58
- 1
- 6
1
vote
1 answer
Select value from custom key/value variable in Grafana
I want dome devices connected to a Grafana dashboard. Each device has a name. I wanted to "attatch" an IP to each device, but I can't modify the database, so I figured I could use custom variables.
The name of the device is saved on the "name"…

JCAguilera
- 944
- 1
- 13
- 32
1
vote
1 answer
Grafana: Is a dashboard-wide constant map/dictionary possible?
I have a Grafana dashboard which has 3 different global variables for the user to choose from: cloud(aws, azure, gcp), environment(dev, stage, prod), location(eastus2, westus2, westeurope, northeurope, etc..)
The user can choose a specific dashboard…

Ken Tsoi
- 1,195
- 1
- 17
- 37
1
vote
1 answer
Grafana 8.1.1 - Postgresql Exception :- long series must be sorted ascending by time to be converted
I am trying to fetch metrics from postgresql (timeseries) database in Grafana (Ver 8) using below query .
Just wondering its throwing below exception :-
failed to convert long to wide series when converting from dataframe: long series must be…

Pravek
- 11
- 1
- 3
1
vote
0 answers
How to add search box in a grafana dashboard for a table pannel?
I have a table view in grafana with multiple data inside it like IP , HOSTNAME etc. How can i add a search box to enter IP in that box and it will retrive data from that table and show .
(Working with varibale feature but have to search IP and then…

Gaurav Kumar
- 21
- 3
1
vote
1 answer
Display weekday on x axis instead of date on Grafana
Hi is there a way to display the day of the week on a Grafana plot eg Monday, Tuesday, Wednesday on the x axis instead of the date eg 05/27, 05/28, 05/29 etc?

Phil Anselmo
- 11
- 1
- 2
1
vote
0 answers
How to groupby unique values from elasticsearch with grafana
Info:
Grafana 7.5.7
Elastic 7.11
Linux OS
I would like to know how can I get unique values from elasticsearch with Grafana’s query editor.
My Query's Data is the following:
Query: $snort
Metric: Count
Groupby: Terms -> event.sms -> Top 10, OrderBy:…

javi-ur96
- 55
- 6
1
vote
1 answer
Grafana variable of a Prometheus __name__ filter metric and one graph for each
in prometheus I can list the metrics like this:
{__name__=~".+_count$", class=~"OracleCustomerDao$", application="access-registration-service"}
And in Grafana I have lots of the graphs where only the name…

MortenB
- 2,749
- 1
- 31
- 35
1
vote
1 answer
Connecting Grafana to MySQL show query failed, why?
I'm trying to connect Grafana with MySQL.
I pulled grafana to docker and ran it. MySQL is not in container.
I created user with all privileges, created database and table. Set from 127.0.0.1 to 0.0.0.0.
When i trying to connect to MySQL in Grafana,…

Tomáš Mejzr
- 357
- 1
- 5
- 11
1
vote
1 answer
Using Grafana textbox panel variable in query where clause
Is there any way to use a textbox panel variable in a where clause for a state panel query?
My Dashboard has a panel variable (type Textbox) variable for current month ($CURRENT_MONTH) with a value of Feb 2021
That variable is used to update the…

dungan1103
- 23
- 1
- 5
1
vote
1 answer
Grant access to dashboard with only one specific variable
I got a dashboard, which contains some variables (in this case: category and URLs):
{
"templating": {
"list": [
{
"allValue": null,
"current": {
"selected": false,
"text": "default",
"value":…

SPQRInc
- 162
- 4
- 23
- 64