Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PMM-1676 Parse error in Grafana dashboards due to removed count_scalar #71

Merged
merged 2 commits into from
Dec 21, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion dashboards/MySQL_Overview.json
Original file line number Diff line number Diff line change
Expand Up @@ -3685,7 +3685,7 @@
"calculatedInterval": "2s",
"datasourceErrors": {},
"errors": {},
"expr": "sum(rate(node_cpu{instance=\"$host\"}[$interval])) by (mode) * 100 / count_scalar(node_cpu{mode=\"user\", instance=\"$host\"}) or sum(irate(node_cpu{instance=\"$host\"}[5m])) by (mode) * 100 / count_scalar(node_cpu{mode=\"user\", instance=\"$host\"})",
"expr": "sum(rate(node_cpu{instance=\"$host\"}[$interval])) by (mode) * 100 / scalar(count(node_cpu{mode=\"user\", instance=\"$host\"})) or sum(irate(node_cpu{instance=\"$host\"}[5m])) by (mode) * 100 / scalar(count(node_cpu{mode=\"user\", instance=\"$host\"}))",
"interval": "$interval",
"intervalFactor": 1,
"legendFormat": "{{ mode }}",
Expand Down
2 changes: 1 addition & 1 deletion dashboards/ProxySQL_Overview.json
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@
"calculatedInterval": "2m",
"datasourceErrors": {},
"errors": {},
"expr": "count_scalar(proxysql_connection_pool_status{instance=\"$proxysql\", hostgroup=\"$hostgroup\"})",
"expr": "scalar(count(proxysql_connection_pool_status{instance=\"$proxysql\", hostgroup=\"$hostgroup\"}))",
"interval": "$interval",
"intervalFactor": 1,
"legendFormat": "Size",
Expand Down
2 changes: 1 addition & 1 deletion dashboards/Summary_Dashboard.json
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@
"calculatedInterval": "2s",
"datasourceErrors": {},
"errors": {},
"expr": "sum(rate(node_cpu{instance=\"$host\", mode!=\"idle\"}[$interval])) by (mode) * 100 / count_scalar(node_cpu{mode=\"user\", instance=\"$host\"}) or sum(irate(node_cpu{instance=\"$host\", mode!=\"idle\"}[5m])) by (mode) * 100 / count_scalar(node_cpu{mode=\"user\", instance=\"$host\"})",
"expr": "sum(rate(node_cpu{instance=\"$host\", mode!=\"idle\"}[$interval])) by (mode) * 100 / scalar(count(node_cpu{mode=\"user\", instance=\"$host\"})) or sum(irate(node_cpu{instance=\"$host\", mode!=\"idle\"}[5m])) by (mode) * 100 / scalar(count(node_cpu{mode=\"user\", instance=\"$host\"}))",
"interval": "$interval",
"intervalFactor": 1,
"legendFormat": "{{ mode }}",
Expand Down
6 changes: 3 additions & 3 deletions dashboards/System_Overview.json
Original file line number Diff line number Diff line change
Expand Up @@ -684,7 +684,7 @@
"calculatedInterval": "2s",
"datasourceErrors": {},
"errors": {},
"expr": "sum(rate(node_cpu{instance=\"$host\", mode!=\"idle\"}[$interval])) by (mode)* 100 / count_scalar(node_cpu{mode=\"user\", instance=\"$host\"}) or sum(irate(node_cpu{instance=\"$host\", mode!=\"idle\"}[5m])) by (mode) * 100 / count_scalar(node_cpu{mode=\"user\", instance=\"$host\"})",
"expr": "sum(rate(node_cpu{instance=\"$host\", mode!=\"idle\"}[$interval])) by (mode)* 100 / scalar(count(node_cpu{mode=\"user\", instance=\"$host\"})) or sum(irate(node_cpu{instance=\"$host\", mode!=\"idle\"}[5m])) by (mode) * 100 / scalar(count(node_cpu{mode=\"user\", instance=\"$host\"}))",
"interval": "$interval",
"intervalFactor": 1,
"legendFormat": "{{ mode }}",
Expand Down Expand Up @@ -921,7 +921,7 @@
"calculatedInterval": "2s",
"datasourceErrors": {},
"errors": {},
"expr": "(avg_over_time(node_procs_running{instance=\"$host\"}[$interval])-1) / count_scalar(node_cpu{mode=\"user\", instance=\"$host\"})",
"expr": "(avg_over_time(node_procs_running{instance=\"$host\"}[$interval])-1) / scalar(count(node_cpu{mode=\"user\", instance=\"$host\"}))",
"interval": "$interval",
"intervalFactor": 1,
"legendFormat": "Normalized CPU Load",
Expand Down Expand Up @@ -1555,7 +1555,7 @@
"target": ""
},
{
"expr": "(rate(node_context_switches{instance=\"$host\"}[$interval]) or irate(node_context_switches{instance=\"$host\"}[5m])) / count_scalar(node_cpu{mode=\"user\", instance=\"$host\"})",
"expr": "(rate(node_context_switches{instance=\"$host\"}[$interval]) or irate(node_context_switches{instance=\"$host\"}[5m])) / scalar(count(node_cpu{mode=\"user\", instance=\"$host\"}))",
"format": "time_series",
"intervalFactor": 1,
"legendFormat": "Context Switches per Virtual CPU",
Expand Down