Skip to content

Commit

Permalink
chore: update sample dahsboard
Browse files Browse the repository at this point in the history
  • Loading branch information
bpetit committed Mar 20, 2023
1 parent baf1bca commit 1170985
Show file tree
Hide file tree
Showing 2 changed files with 145 additions and 23 deletions.
123 changes: 109 additions & 14 deletions docker-compose/dashboards/sample-dashboard.json
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,20 @@
"intervalFactor": 2,
"legendFormat": "{{instance}}",
"refId": "A"
},
{
"expr": "sum(scaph_process_power_consumption_microwatts) / 1000000",
"format": "time_series",
"intervalFactor": 2,
"legendFormat": "sum of processes power",
"refId": "B"
},
{
"expr": "sum(scaph_domain_power_microwatts) / 1000000",
"format": "time_series",
"intervalFactor": 2,
"legendFormat": "sum of rapl domains power",
"refId": "C"
}
],
"thresholds": [ ],
Expand Down Expand Up @@ -322,7 +336,7 @@
"repeat": null,
"seriesOverrides": [ ],
"spaceLength": 10,
"span": 4,
"span": 3,
"stack": false,
"steppedLine": false,
"targets": [
Expand Down Expand Up @@ -403,7 +417,88 @@
"repeat": null,
"seriesOverrides": [ ],
"spaceLength": 10,
"span": 4,
"span": 3,
"stack": false,
"steppedLine": false,
"targets": [
{
"expr": "scaph_domain_power_microwatts / 1000000",
"format": "time_series",
"intervalFactor": 2,
"legendFormat": "{{domain_name}}",
"refId": "A"
}
],
"thresholds": [ ],
"timeFrom": null,
"timeShift": null,
"title": "scaph_domain_power",
"tooltip": {
"shared": true,
"sort": 0,
"value_type": "individual"
},
"type": "graph",
"xaxis": {
"buckets": null,
"mode": "time",
"name": null,
"show": true,
"values": [ ]
},
"yaxes": [
{
"format": "W",
"label": null,
"logBase": 1,
"max": null,
"min": 0,
"show": true
},
{
"format": "W",
"label": null,
"logBase": 1,
"max": null,
"min": 0,
"show": true
}
]
},
{
"aliasColors": { },
"bars": false,
"dashLength": 10,
"dashes": false,
"datasource": "${PROMETHEUS_DS}",
"fill": 1,
"fillGradient": 0,
"gridPos": { },
"id": 7,
"legend": {
"alignAsTable": false,
"avg": false,
"current": false,
"max": false,
"min": false,
"rightSide": false,
"show": true,
"sideWidth": null,
"total": false,
"values": false
},
"lines": true,
"linewidth": 1,
"links": [ ],
"nullPointMode": "null",
"percentage": false,
"pointradius": 5,
"points": false,
"renderer": "flot",
"repeat": null,
"seriesOverrides": [ ],
"spaceLength": 10,
"span": 3,
"stack": false,
"steppedLine": false,
"targets": [
Expand Down Expand Up @@ -460,7 +555,7 @@
"fill": 1,
"fillGradient": 0,
"gridPos": { },
"id": 7,
"id": 8,
"legend": {
"alignAsTable": false,
"avg": false,
Expand All @@ -484,7 +579,7 @@
"repeat": null,
"seriesOverrides": [ ],
"spaceLength": 10,
"span": 4,
"span": 3,
"stack": false,
"steppedLine": false,
"targets": [
Expand All @@ -506,7 +601,7 @@
"thresholds": [ ],
"timeFrom": null,
"timeShift": null,
"title": "Socket power consumption",
"title": "scaph_self_mem",
"tooltip": {
"shared": true,
"sort": 0,
Expand Down Expand Up @@ -561,7 +656,7 @@
"fill": 1,
"fillGradient": 0,
"gridPos": { },
"id": 8,
"id": 9,
"legend": {
"alignAsTable": true,
"avg": false,
Expand Down Expand Up @@ -590,7 +685,7 @@
"steppedLine": false,
"targets": [
{
"expr": "scaph_process_power_consumption_microwatts{exe=~\".*${process_filter}.*\"}/1000000",
"expr": "scaph_process_power_consumption_microwatts{cmdline=~\".*${process_filter}.*\"}/1000000",
"format": "time_series",
"intervalFactor": 2,
"legendFormat": "{{ cmdline }}",
Expand All @@ -600,7 +695,7 @@
"thresholds": [ ],
"timeFrom": null,
"timeShift": null,
"title": "Filtered process (process_filter) power, by exe",
"title": "Filtered process (process_filter) power, by cmdline",
"tooltip": {
"shared": true,
"sort": 0,
Expand Down Expand Up @@ -642,7 +737,7 @@
"fill": 1,
"fillGradient": 0,
"gridPos": { },
"id": 9,
"id": 10,
"legend": {
"alignAsTable": true,
"avg": false,
Expand Down Expand Up @@ -671,7 +766,7 @@
"steppedLine": false,
"targets": [
{
"expr": "scaph_process_cpu_usage_percentage{exe=~\".*${process_filter}.*\"}",
"expr": "scaph_process_cpu_usage_percentage{cmdline=~\".*${process_filter}.*\"}",
"format": "time_series",
"intervalFactor": 2,
"legendFormat": "{{ cmdline }}",
Expand Down Expand Up @@ -723,7 +818,7 @@
"fill": 1,
"fillGradient": 0,
"gridPos": { },
"id": 10,
"id": 11,
"legend": {
"alignAsTable": true,
"avg": false,
Expand Down Expand Up @@ -752,7 +847,7 @@
"steppedLine": false,
"targets": [
{
"expr": "scaph_process_memory_bytes{exe=~\".*${process_filter}.*\"}",
"expr": "scaph_process_memory_bytes{cmdline=~\".*${process_filter}.*\"}",
"format": "time_series",
"intervalFactor": 2,
"legendFormat": "{{ cmdline }}",
Expand Down Expand Up @@ -804,7 +899,7 @@
"fill": 1,
"fillGradient": 0,
"gridPos": { },
"id": 11,
"id": 12,
"legend": {
"alignAsTable": true,
"avg": false,
Expand Down Expand Up @@ -833,7 +928,7 @@
"steppedLine": false,
"targets": [
{
"expr": "scaph_process_memory_virtual_bytes{exe=~\".*${process_filter}.*\"}",
"expr": "scaph_process_memory_virtual_bytes{cmdline=~\".*${process_filter}.*\"}",
"format": "time_series",
"intervalFactor": 2,
"legendFormat": "{{ cmdline }}",
Expand Down
45 changes: 36 additions & 9 deletions docker-compose/sample.jsonnet
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,18 @@ dashboard.new(
legendFormat='{{instance}}',
)
)
.addTarget(
grafana.prometheus.target(
'sum(scaph_process_power_consumption_microwatts) / 1000000',
legendFormat='sum of processes power',
)
)
.addTarget(
grafana.prometheus.target(
'sum(scaph_domain_power_microwatts) / 1000000',
legendFormat='sum of rapl domains power',
)
)
)
.addPanel(
grafana.graphPanel.new(
Expand Down Expand Up @@ -97,7 +109,7 @@ dashboard.new(
title='Socket power consumption',
datasource='${PROMETHEUS_DS}',
format='W',
span=4,
span=3,
min=0
)
.addTarget(
Expand All @@ -107,12 +119,27 @@ dashboard.new(
)
)
)
.addPanel(
grafana.graphPanel.new(
title='scaph_domain_power',
datasource='${PROMETHEUS_DS}',
format='W',
span=3,
min=0
)
.addTarget(
grafana.prometheus.target(
'scaph_domain_power_microwatts / 1000000',
legendFormat='{{domain_name}}',
)
)
)
.addPanel(
grafana.graphPanel.new(
title='scaph_self_cpu',
datasource='${PROMETHEUS_DS}',
format='%',
span=4,
span=3,
min=0
)
.addTarget(
Expand All @@ -124,10 +151,10 @@ dashboard.new(
)
.addPanel(
grafana.graphPanel.new(
title='Socket power consumption',
title='scaph_self_mem',
datasource='${PROMETHEUS_DS}',
format='Bytes',
span=4,
span=3,
min=0
)
.addTarget(
Expand All @@ -150,7 +177,7 @@ dashboard.new(
)
.addPanel(
grafana.graphPanel.new(
title='Filtered process (process_filter) power, by exe',
title='Filtered process (process_filter) power, by cmdline',
datasource='${PROMETHEUS_DS}',
span=3,
format='W',
Expand All @@ -162,7 +189,7 @@ dashboard.new(
)
.addTarget(
grafana.prometheus.target(
'scaph_process_power_consumption_microwatts{exe=~".*${process_filter}.*"}/1000000',
'scaph_process_power_consumption_microwatts{cmdline=~".*${process_filter}.*"}/1000000',
legendFormat='{{ cmdline }}',
)
)
Expand All @@ -181,7 +208,7 @@ dashboard.new(
)
.addTarget(
grafana.prometheus.target(
'scaph_process_cpu_usage_percentage{exe=~".*${process_filter}.*"}',
'scaph_process_cpu_usage_percentage{cmdline=~".*${process_filter}.*"}',
legendFormat='{{ cmdline }}',
)
)
Expand All @@ -200,7 +227,7 @@ dashboard.new(
)
.addTarget(
grafana.prometheus.target(
'scaph_process_memory_bytes{exe=~".*${process_filter}.*"}',
'scaph_process_memory_bytes{cmdline=~".*${process_filter}.*"}',
legendFormat='{{ cmdline }}',
)
)
Expand All @@ -219,7 +246,7 @@ dashboard.new(
)
.addTarget(
grafana.prometheus.target(
'scaph_process_memory_virtual_bytes{exe=~".*${process_filter}.*"}',
'scaph_process_memory_virtual_bytes{cmdline=~".*${process_filter}.*"}',
legendFormat='{{ cmdline }}',
)
)
Expand Down

0 comments on commit 1170985

Please sign in to comment.