Grafana dashboard: Demo upload dashbỏad
Description: abc

demo

{
  "__inputs": [
    {
      "name": "DS_PROMETHEUS",
      "label": "Prometheus",
      "description": "",
      "type": "datasource",
      "pluginId": "prometheus",
      "pluginName": "Prometheus"
    }
  ],
  "__requires": [
    {
      "type": "grafana",
      "id": "grafana",
      "name": "Grafana",
      "version": "7.0.3"
    },
    {
      "type": "panel",
      "id": "grafana-polystat-panel",
      "name": "Polystat",
      "version": "1.2.2"
    },
    {
      "type": "panel",
      "id": "graph",
      "name": "Graph",
      "version": ""
    },
    {
      "type": "datasource",
      "id": "prometheus",
      "name": "Prometheus",
      "version": "1.0.0"
    },
    {
      "type": "panel",
      "id": "table",
      "name": "Table",
      "version": ""
    }
  ],
  "annotations": {
    "list": [
      {
        "builtIn": 1,
        "datasource": "-- Grafana --",
        "enable": true,
        "hide": true,
        "iconColor": "rgba(0, 211, 255, 1)",
        "limit": 100,
        "name": "Annotations & Alerts",
        "showIn": 0,
        "type": "dashboard"
      }
    ]
  },
  "editable": true,
  "gnetId": 13264,
  "graphTooltip": 2,
  "id": null,
  "iteration": 1603535638484,
  "links": [
    {
      "$$hashKey": "object:598",
      "asDropdown": false,
      "icon": "external link",
      "tags": [
        "Docker Services"
      ],
      "type": "dashboards"
    }
  ],
  "panels": [
    {
      "colors": [
        "#299c46",
        "rgba(237, 129, 40, 0.89)",
        "#d44a3a",
        "#4040a0"
      ],
      "datasource": "${DS_PROMETHEUS}",
      "fieldConfig": {
        "defaults": {
          "custom": {}
        },
        "overrides": []
      },
      "gridPos": {
        "h": 22,
        "w": 12,
        "x": 0,
        "y": 0
      },
      "id": 12,
      "mappingType": 1,
      "mappingTypes": [
        {
          "name": "value to text",
          "value": 1
        },
        {
          "name": "range to text",
          "value": 2
        }
      ],
      "polystat": {
        "animationSpeed": 2500,
        "columnAutoSize": true,
        "columns": "",
        "defaultClickThrough": "",
        "defaultClickThroughNewTab": false,
        "defaultClickThroughSanitize": false,
        "displayLimit": 200,
        "fontAutoColor": true,
        "fontAutoScale": true,
        "fontColor": "",
        "fontSize": 12,
        "fontType": "Roboto",
        "globalDecimals": 2,
        "globalDisplayMode": "all",
        "globalDisplayTextTriggeredEmpty": "OK",
        "globalOperatorName": "avg",
        "globalUnitFormat": "short",
        "gradientEnabled": false,
        "hexagonSortByDirection": 1,
        "hexagonSortByField": "thresholdLevel",
        "maxMetrics": 0,
        "polygonBorderColor": "black",
        "polygonBorderSize": 5,
        "polygonGlobalFillColor": "#817f7f",
        "radius": "",
        "radiusAutoSize": true,
        "rowAutoSize": true,
        "rows": "",
        "shape": "hexagon_pointed_top",
        "tooltipDisplayMode": "all",
        "tooltipDisplayTextTriggeredEmpty": "OK",
        "tooltipFontSize": 12,
        "tooltipFontType": "Roboto",
        "tooltipPrimarySortDirection": 1,
        "tooltipPrimarySortField": "value",
        "tooltipSecondarySortDirection": 1,
        "tooltipSecondarySortField": "name",
        "tooltipTimestampEnabled": false,
        "valueEnabled": false
      },
      "rangeMaps": [
        {
          "from": "null",
          "text": "N/A",
          "to": "null"
        }
      ],
      "repeat": null,
      "repeatDirection": "v",
      "savedComposites": [],
      "savedOverrides": [
        {
          "clickThrough": "",
          "colors": [
            "#299c46",
            "#e5ac0e",
            "#bf1b00",
            "#ffffff"
          ],
          "decimals": "",
          "enabled": true,
          "label": "OVERRIDE 1",
          "metricName": ".*",
          "newTabEnabled": true,
          "operatorName": "avg",
          "prefix": "",
          "sanitizeURLEnabled": false,
          "scaledDecimals": null,
          "suffix": "",
          "thresholds": [
            {
              "color": "#E02F44",
              "state": 0,
              "value": 0
            },
            {
              "color": "#56A64B",
              "state": 0,
              "value": 1
            }
          ],
          "unitFormat": "short"
        }
      ],
      "targets": [
        {
          "expr": "up{job=\"hosts\", customer=~\"$customer\", target=~\"$target\"}",
          "hide": false,
          "instant": false,
          "interval": "",
          "legendFormat": "{{customer}}_{{target}}_{{instance}}",
          "refId": "A"
        }
      ],
      "timeFrom": null,
      "timeShift": null,
      "title": "Customers",
      "transformations": [],
      "transparent": true,
      "type": "grafana-polystat-panel",
      "valueMaps": [
        {
          "op": "=",
          "text": "N/A",
          "value": "null"
        }
      ]
    },
    {
      "datasource": "${DS_PROMETHEUS}",
      "description": "",
      "fieldConfig": {
        "defaults": {
          "custom": {
            "align": null,
            "displayMode": "gradient-gauge"
          },
          "mappings": [],
          "thresholds": {
            "mode": "absolute",
            "steps": [
              {
                "color": "green",
                "value": null
              },
              {
                "color": "semi-dark-orange",
                "value": 70
              },
              {
                "color": "semi-dark-blue",
                "value": 80
              },
              {
                "color": "semi-dark-purple",
                "value": 90
              }
            ]
          },
          "unit": "percent"
        },
        "overrides": [
          {
            "matcher": {
              "id": "byName",
              "options": "Mean"
            },
            "properties": [
              {
                "id": "custom.displayMode",
                "value": "gradient-gauge"
              },
              {
                "id": "thresholds",
                "value": {
                  "mode": "absolute",
                  "steps": [
                    {
                      "color": "green",
                      "value": null
                    },
                    {
                      "color": "semi-dark-orange",
                      "value": 70
                    },
                    {
                      "color": "semi-dark-blue",
                      "value": 80
                    },
                    {
                      "color": "dark-purple",
                      "value": 90
                    }
                  ]
                }
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "Field"
            },
            "properties": [
              {
                "id": "custom.displayMode",
                "value": "auto"
              }
            ]
          }
        ]
      },
      "gridPos": {
        "h": 7,
        "w": 12,
        "x": 12,
        "y": 0
      },
      "id": 14,
      "options": {
        "showHeader": false,
        "sortBy": [
          {
            "desc": true,
            "displayName": "Mean"
          }
        ]
      },
      "pluginVersion": "7.0.3",
      "targets": [
        {
          "expr": "record_node_storage_used{customer=~\"$customer\", target=~\"$target\"}",
          "interval": "",
          "legendFormat": "{{customer}} - {{target}} - {{instance}}",
          "refId": "A"
        }
      ],
      "timeFrom": null,
      "timeShift": null,
      "title": "HDD used",
      "transformations": [
        {
          "id": "reduce",
          "options": {
            "reducers": [
              "mean"
            ]
          }
        }
      ],
      "type": "table"
    },
    {
      "aliasColors": {},
      "bars": false,
      "dashLength": 10,
      "dashes": false,
      "datasource": "${DS_PROMETHEUS}",
      "description": "",
      "fieldConfig": {
        "defaults": {
          "custom": {}
        },
        "overrides": []
      },
      "fill": 0,
      "fillGradient": 0,
      "gridPos": {
        "h": 7,
        "w": 12,
        "x": 12,
        "y": 7
      },
      "hiddenSeries": false,
      "id": 16,
      "legend": {
        "alignAsTable": true,
        "avg": false,
        "current": true,
        "hideEmpty": false,
        "max": false,
        "min": false,
        "rightSide": true,
        "show": true,
        "total": false,
        "values": true
      },
      "lines": true,
      "linewidth": 1,
      "maxPerRow": 3,
      "nullPointMode": "null",
      "options": {
        "dataLinks": []
      },
      "percentage": false,
      "pointradius": 0.5,
      "points": false,
      "renderer": "flot",
      "repeat": null,
      "repeatDirection": "h",
      "seriesOverrides": [
        {}
      ],
      "spaceLength": 10,
      "stack": false,
      "steppedLine": false,
      "targets": [
        {
          "expr": "record_node_memory_used{customer=~\"$customer\", target=~\"$target\"}",
          "interval": "",
          "legendFormat": "{{customer}}_{{target}}_{{instance}}",
          "refId": "A"
        }
      ],
      "thresholds": [],
      "timeFrom": null,
      "timeRegions": [],
      "timeShift": null,
      "title": "RAM used",
      "tooltip": {
        "shared": true,
        "sort": 0,
        "value_type": "individual"
      },
      "transformations": [],
      "type": "graph",
      "xaxis": {
        "buckets": null,
        "mode": "time",
        "name": null,
        "show": true,
        "values": []
      },
      "yaxes": [
        {
          "format": "percent",
          "label": "",
          "logBase": 1,
          "max": null,
          "min": null,
          "show": true
        },
        {
          "format": "short",
          "label": null,
          "logBase": 1,
          "max": null,
          "min": null,
          "show": true
        }
      ],
      "yaxis": {
        "align": false,
        "alignLevel": null
      }
    },
    {
      "aliasColors": {},
      "bars": false,
      "dashLength": 10,
      "dashes": false,
      "datasource": "${DS_PROMETHEUS}",
      "description": "avg cpu value in 5 minute",
      "fieldConfig": {
        "defaults": {
          "custom": {}
        },
        "overrides": []
      },
      "fill": 0,
      "fillGradient": 0,
      "gridPos": {
        "h": 7,
        "w": 12,
        "x": 12,
        "y": 14
      },
      "hiddenSeries": false,
      "id": 18,
      "legend": {
        "alignAsTable": true,
        "avg": false,
        "current": true,
        "max": false,
        "min": false,
        "rightSide": true,
        "show": true,
        "total": false,
        "values": true
      },
      "lines": true,
      "linewidth": 1,
      "nullPointMode": "null",
      "options": {
        "dataLinks": []
      },
      "percentage": true,
      "pointradius": 2,
      "points": false,
      "renderer": "flot",
      "seriesOverrides": [],
      "spaceLength": 10,
      "stack": false,
      "steppedLine": false,
      "targets": [
        {
          "expr": "record_node_cpu_used:range_5m{customer=~\"$customer\", target=~\"$target\"}",
          "format": "time_series",
          "interval": "",
          "legendFormat": "{{customer}}__{{target}}__{{instance}}",
          "refId": "A"
        }
      ],
      "thresholds": [
        {
          "colorMode": "critical",
          "fill": false,
          "line": true,
          "op": "gt",
          "value": 90,
          "yaxis": "left"
        }
      ],
      "timeFrom": null,
      "timeRegions": [],
      "timeShift": null,
      "title": "CPU used (avg:5m)",
      "tooltip": {
        "shared": true,
        "sort": 2,
        "value_type": "individual"
      },
      "type": "graph",
      "xaxis": {
        "buckets": null,
        "mode": "time",
        "name": null,
        "show": true,
        "values": []
      },
      "yaxes": [
        {
          "format": "percent",
          "label": null,
          "logBase": 1,
          "max": null,
          "min": null,
          "show": true
        },
        {
          "format": "short",
          "label": null,
          "logBase": 1,
          "max": null,
          "min": null,
          "show": true
        }
      ],
      "yaxis": {
        "align": false,
        "alignLevel": null
      }
    }
  ],
  "refresh": "1m",
  "schemaVersion": 25,
  "style": "dark",
  "tags": [],
  "templating": {
    "list": [
      {
        "allValue": null,
        "current": {},
        "datasource": "${DS_PROMETHEUS}",
        "definition": "label_values(up{job=\"hosts\"}, customer)",
        "hide": 0,
        "includeAll": true,
        "label": "Customers",
        "multi": true,
        "name": "customer",
        "options": [],
        "query": "label_values(up{job=\"hosts\"}, customer)",
        "refresh": 2,
        "regex": "",
        "skipUrlSync": false,
        "sort": 0,
        "tagValuesQuery": "",
        "tags": [],
        "tagsQuery": "",
        "type": "query",
        "useTags": false
      },
      {
        "allValue": null,
        "current": {},
        "datasource": "${DS_PROMETHEUS}",
        "definition": "label_values(up{job=\"hosts\"}, target)",
        "hide": 0,
        "includeAll": true,
        "label": "Targets",
        "multi": true,
        "name": "target",
        "options": [],
        "query": "label_values(up{job=\"hosts\"}, target)",
        "refresh": 2,
        "regex": "",
        "skipUrlSync": false,
        "sort": 0,
        "tagValuesQuery": "",
        "tags": [],
        "tagsQuery": "",
        "type": "query",
        "useTags": false
      },
      {
        "allValue": null,
        "current": {},
        "datasource": "${DS_PROMETHEUS}",
        "definition": "label_values(up{job=\"hosts\"}, instance)",
        "hide": 2,
        "includeAll": true,
        "label": "Instances",
        "multi": true,
        "name": "instance",
        "options": [],
        "query": "label_values(up{job=\"hosts\"}, instance)",
        "refresh": 2,
        "regex": "",
        "skipUrlSync": false,
        "sort": 0,
        "tagValuesQuery": "",
        "tags": [],
        "tagsQuery": "",
        "type": "query",
        "useTags": false
      },
      {
        "allValue": null,
        "current": {},
        "datasource": "${DS_PROMETHEUS}",
        "definition": "label_values(consul_catalog_service_node_healthy{customer=\"$customer\", target=\"$target\", job=\"services\"}, service_name)",
        "hide": 2,
        "includeAll": false,
        "label": "Services",
        "multi": false,
        "name": "service",
        "options": [],
        "query": "label_values(consul_catalog_service_node_healthy{customer=\"$customer\", target=\"$target\", job=\"services\"}, service_name)",
        "refresh": 2,
        "regex": "",
        "skipUrlSync": false,
        "sort": 0,
        "tagValuesQuery": "",
        "tags": [],
        "tagsQuery": "",
        "type": "query",
        "useTags": false
      }
    ]
  },
  "time": {
    "from": "now-24h",
    "to": "now"
  },
  "timepicker": {
    "refresh_intervals": [
      "10s",
      "30s",
      "1m",
      "5m",
      "15m",
      "30m",
      "1h",
      "2h",
      "1d"
    ]
  },
  "timezone": "Asia/Bangkok",
  "title": "Demo upload dashbỏad",
  "uid": "84dUSNtGk",
  "version": 55,
  "description": "abc"
}