1 Docker Dashboard for Prometheus  中文版
1 Docker Dashboard for Prometheus  中文版
Docker Exporter 总览

E-mail: henry525@qq.com
{
  "__inputs": [
    {
      "name": "DS_PROMETHEUS",
      "label": "Prometheus",
      "description": "",
      "type": "datasource",
      "pluginId": "prometheus",
      "pluginName": "Prometheus"
    }
  ],
  "__requires": [
    {
      "type": "grafana",
      "id": "grafana",
      "name": "Grafana",
      "version": "6.5.2"
    },
    {
      "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)",
        "name": "Annotations & Alerts",
        "type": "dashboard"
      }
    ]
  },
  "editable": true,
  "gnetId": 11558,
  "graphTooltip": 0,
  "id": null,
  "iteration": 1578975849589,
  "links": [],
  "panels": [
    {
      "columns": [],
      "datasource": "${DS_PROMETHEUS}",
      "fontSize": "100%",
      "gridPos": {
        "h": 13,
        "w": 24,
        "x": 0,
        "y": 0
      },
      "id": 4,
      "options": {},
      "pageSize": null,
      "repeat": null,
      "showHeader": true,
      "sort": {
        "col": 1,
        "desc": false
      },
      "styles": [
        {
          "alias": "Time",
          "dateFormat": "YYYY-MM-DD HH:mm:ss",
          "pattern": "Time",
          "type": "hidden"
        },
        {
          "alias": "IP",
          "colorMode": null,
          "colors": [
            "rgba(245, 54, 54, 0.9)",
            "rgba(237, 129, 40, 0.89)",
            "rgba(50, 172, 45, 0.97)"
          ],
          "dateFormat": "YYYY-MM-DD HH:mm:ss",
          "decimals": 1,
          "link": true,
          "linkTargetBlank": true,
          "linkTooltip": "点击查看详情",
          "linkUrl": "/grafana/d/MLqsM4bZk/docker-and-system-monitoring?var-server=${__cell_2}",
          "mappingType": 2,
          "pattern": "ip",
          "preserveFormat": false,
          "rangeMaps": [],
          "sanitize": false,
          "thresholds": [],
          "type": "string",
          "unit": "forceNm"
        },
        {
          "alias": "CPU使用率",
          "colorMode": "cell",
          "colors": [
            "#1F60C4",
            "#8F3BB8",
            "#FA6400"
          ],
          "dateFormat": "YYYY-MM-DD HH:mm:ss",
          "decimals": 0,
          "mappingType": 1,
          "pattern": "Value #E",
          "thresholds": [
            "50",
            "78"
          ],
          "type": "number",
          "unit": "percent"
        },
        {
          "alias": "容器数量",
          "colorMode": null,
          "colors": [
            "rgba(245, 54, 54, 0.9)",
            "rgba(237, 129, 40, 0.89)",
            "rgba(50, 172, 45, 0.97)"
          ],
          "dateFormat": "YYYY-MM-DD HH:mm:ss",
          "decimals": 0,
          "link": true,
          "linkTargetBlank": true,
          "linkTooltip": "查看容器详情",
          "linkUrl": "/grafana/d/FRVE0VbWz/docker-exporter-dashboard?orgId=1&var-server=${__cell_2}&var-interval=30s",
          "mappingType": 1,
          "pattern": "Value #A",
          "thresholds": [],
          "type": "number",
          "unit": "short"
        },
        {
          "alias": "内存使用量",
          "colorMode": "cell",
          "colors": [
            "#1F60C4",
            "#8F3BB8",
            "#FA6400"
          ],
          "dateFormat": "YYYY-MM-DD HH:mm:ss",
          "decimals": 0,
          "mappingType": 1,
          "pattern": "Value #B",
          "thresholds": [
            "30000000000",
            "800000000000"
          ],
          "type": "number",
          "unit": "decbytes"
        },
        {
          "alias": "磁盘使用量",
          "colorMode": "cell",
          "colors": [
            "#1F60C4",
            "#8F3BB8",
            "#FA6400"
          ],
          "dateFormat": "YYYY-MM-DD HH:mm:ss",
          "decimals": 2,
          "mappingType": 1,
          "pattern": "Value #G",
          "thresholds": [
            "5000000000",
            "80000000000"
          ],
          "type": "number",
          "unit": "bytes"
        },
        {
          "alias": "网络下载（s）",
          "colorMode": "cell",
          "colors": [
            "#1F60C4",
            "#8F3BB8",
            "#FA6400"
          ],
          "dateFormat": "YYYY-MM-DD HH:mm:ss",
          "decimals": 1,
          "mappingType": 1,
          "pattern": "Value #H",
          "thresholds": [
            "50000000",
            "800000000"
          ],
          "type": "number",
          "unit": "bps"
        },
        {
          "alias": "网络上传（s）",
          "colorMode": "cell",
          "colors": [
            "#1F60C4",
            "#8F3BB8",
            "#FA6400"
          ],
          "dateFormat": "YYYY-MM-DD HH:mm:ss",
          "decimals": 2,
          "mappingType": 1,
          "pattern": "Value #I",
          "thresholds": [
            "50000000",
            "800000000"
          ],
          "type": "number",
          "unit": "bps"
        },
        {
          "alias": "",
          "colorMode": null,
          "colors": [
            "rgba(245, 54, 54, 0.9)",
            "rgba(237, 129, 40, 0.89)",
            "rgba(50, 172, 45, 0.97)"
          ],
          "dateFormat": "YYYY-MM-DD HH:mm:ss",
          "decimals": 2,
          "mappingType": 1,
          "pattern": "__name__",
          "thresholds": [],
          "type": "hidden",
          "unit": "short"
        },
        {
          "alias": "Docker版本",
          "colorMode": null,
          "colors": [
            "rgba(245, 54, 54, 0.9)",
            "rgba(237, 129, 40, 0.89)",
            "rgba(50, 172, 45, 0.97)"
          ],
          "dateFormat": "YYYY-MM-DD HH:mm:ss",
          "decimals": 2,
          "mappingType": 1,
          "pattern": "dockerVersion",
          "thresholds": [],
          "type": "string",
          "unit": "short"
        },
        {
          "alias": "",
          "colorMode": null,
          "colors": [
            "rgba(245, 54, 54, 0.9)",
            "rgba(237, 129, 40, 0.89)",
            "rgba(50, 172, 45, 0.97)"
          ],
          "dateFormat": "YYYY-MM-DD HH:mm:ss",
          "decimals": 2,
          "mappingType": 1,
          "pattern": "/.*/",
          "thresholds": [],
          "type": "hidden",
          "unit": "short"
        }
      ],
      "targets": [
        {
          "expr": "label_replace((count(container_cpu_load_average_10s{name!=\"\"}) by (instance)),\"ip\",\"$1\",\"instance\",\"(.*):.*\")",
          "format": "table",
          "hide": false,
          "instant": true,
          "legendFormat": "",
          "refId": "A"
        },
        {
          "expr": "label_replace((cadvisor_version_info),\"ip\",\"$1\",\"instance\",\"(.*):.*\")",
          "format": "table",
          "hide": false,
          "instant": true,
          "legendFormat": "",
          "refId": "C"
        },
        {
          "expr": "label_replace((time() - node_boot_time_seconds),\"ip\",\"$1\",\"instance\",\"(.*):.*\")",
          "format": "table",
          "hide": true,
          "instant": true,
          "interval": "10s",
          "refId": "D"
        },
        {
          "expr": "label_replace((sum(node_filesystem_size_bytes{fstype=~\"ext4|xfs\"})by (instance)),\"ip\",\"$1\",\"instance\",\"(.*):.*\")",
          "format": "table",
          "hide": true,
          "instant": true,
          "interval": "10s",
          "refId": "F"
        },
        {
          "expr": "label_replace(((avg(irate(container_cpu_system_seconds_total{name!=\"\"}[1m]))by (instance) * 100)),\"ip\",\"$1\",\"instance\",\"(.*):.*\")",
          "format": "table",
          "hide": false,
          "instant": true,
          "interval": "",
          "refId": "E"
        },
        {
          "expr": "label_replace((sum(container_memory_usage_bytes{name=~\".+\"}) by (instance)),\"ip\",\"$1\",\"instance\",\"(.*):.*\")",
          "format": "table",
          "hide": false,
          "instant": true,
          "refId": "B"
        },
        {
          "expr": "label_replace((sum(container_fs_usage_bytes{name!=\"\"}) by (instance)),\"ip\",\"$1\",\"instance\",\"(.*):.*\")",
          "format": "table",
          "hide": false,
          "instant": true,
          "interval": "10s",
          "refId": "G"
        },
        {
          "expr": "label_replace((sum(rate(container_network_receive_bytes_total{name!=\"\"}[1m])) by (instance)),\"ip\",\"$1\",\"instance\",\"(.*):.*\")",
          "format": "table",
          "hide": false,
          "instant": true,
          "interval": "10s",
          "refId": "H"
        },
        {
          "expr": "label_replace((sum(rate(container_network_transmit_bytes_total{name!=\"\"}[1m])) by (instance)),\"ip\",\"$1\",\"instance\",\"(.*):.*\")",
          "format": "table",
          "hide": false,
          "instant": true,
          "interval": "10s",
          "refId": "I"
        },
        {
          "refId": "J"
        }
      ],
      "timeFrom": null,
      "timeShift": null,
      "title": "",
      "transform": "table",
      "transparent": true,
      "type": "table"
    },
    {
      "columns": [],
      "datasource": "${DS_PROMETHEUS}",
      "fontSize": "100%",
      "gridPos": {
        "h": 13,
        "w": 24,
        "x": 0,
        "y": 13
      },
      "id": 5,
      "options": {},
      "pageSize": null,
      "showHeader": true,
      "sort": {
        "col": 1,
        "desc": false
      },
      "styles": [
        {
          "alias": "Time",
          "dateFormat": "YYYY-MM-DD HH:mm:ss",
          "pattern": "Time",
          "type": "hidden"
        },
        {
          "alias": "容器名称",
          "colorMode": null,
          "colors": [
            "rgba(245, 54, 54, 0.9)",
            "rgba(237, 129, 40, 0.89)",
            "rgba(50, 172, 45, 0.97)"
          ],
          "dateFormat": "YYYY-MM-DD HH:mm:ss",
          "decimals": 1,
          "link": false,
          "linkTargetBlank": true,
          "linkTooltip": "点击查看详情",
          "linkUrl": "/d/MLqsM4bZk/docker-and-system-monitoring?var-server=${__cell_2}",
          "mappingType": 2,
          "pattern": "name",
          "preserveFormat": false,
          "rangeMaps": [],
          "sanitize": false,
          "thresholds": [],
          "type": "string",
          "unit": "forceNm"
        },
        {
          "alias": "CPU使用率",
          "colorMode": null,
          "colors": [
            "rgba(245, 54, 54, 0.9)",
            "rgba(237, 129, 40, 0.89)",
            "rgba(50, 172, 45, 0.97)"
          ],
          "dateFormat": "YYYY-MM-DD HH:mm:ss",
          "decimals": 0,
          "mappingType": 1,
          "pattern": "Value #A",
          "thresholds": [],
          "type": "number",
          "unit": "percent"
        },
        {
          "alias": "内存使用率",
          "colorMode": "cell",
          "colors": [
            "#1F60C4",
            "#8F3BB8",
            "#FA6400"
          ],
          "dateFormat": "YYYY-MM-DD HH:mm:ss",
          "decimals": 2,
          "mappingType": 1,
          "pattern": "Value #B",
          "thresholds": [
            "30000000000",
            "800000000000"
          ],
          "type": "number",
          "unit": "decbytes"
        },
        {
          "alias": "磁盘使用量",
          "colorMode": "cell",
          "colors": [
            "#1F60C4",
            "#8F3BB8",
            "#FA6400"
          ],
          "dateFormat": "YYYY-MM-DD HH:mm:ss",
          "decimals": 2,
          "mappingType": 1,
          "pattern": "Value #G",
          "thresholds": [
            "5000000000",
            "80000000000"
          ],
          "type": "hidden",
          "unit": "bytes"
        },
        {
          "alias": "网络下载（s）",
          "colorMode": "cell",
          "colors": [
            "#1F60C4",
            "#8F3BB8",
            "#FA6400"
          ],
          "dateFormat": "YYYY-MM-DD HH:mm:ss",
          "decimals": 1,
          "mappingType": 1,
          "pattern": "Value #H",
          "thresholds": [
            "50000000",
            "800000000"
          ],
          "type": "number",
          "unit": "bps"
        },
        {
          "alias": "网络上传（s）",
          "colorMode": "cell",
          "colors": [
            "#1F60C4",
            "#8F3BB8",
            "#FA6400"
          ],
          "dateFormat": "YYYY-MM-DD HH:mm:ss",
          "decimals": 2,
          "mappingType": 1,
          "pattern": "Value #I",
          "thresholds": [
            "50000000",
            "800000000"
          ],
          "type": "number",
          "unit": "bps"
        },
        {
          "alias": "",
          "colorMode": null,
          "colors": [
            "rgba(245, 54, 54, 0.9)",
            "rgba(237, 129, 40, 0.89)",
            "rgba(50, 172, 45, 0.97)"
          ],
          "dateFormat": "YYYY-MM-DD HH:mm:ss",
          "decimals": 2,
          "mappingType": 1,
          "pattern": "__name__",
          "thresholds": [],
          "type": "hidden",
          "unit": "short"
        },
        {
          "alias": "",
          "colorMode": null,
          "colors": [
            "rgba(245, 54, 54, 0.9)",
            "rgba(237, 129, 40, 0.89)",
            "rgba(50, 172, 45, 0.97)"
          ],
          "dateFormat": "YYYY-MM-DD HH:mm:ss",
          "decimals": 2,
          "mappingType": 1,
          "pattern": "/.*/",
          "thresholds": [],
          "type": "hidden",
          "unit": "short"
        }
      ],
      "targets": [
        {
          "expr": "sum(rate(container_cpu_usage_seconds_total{instance=~\"$server:.*\",name=~\".+\"}[$interval])) by (name) * 100",
          "format": "table",
          "hide": false,
          "instant": true,
          "legendFormat": "",
          "refId": "A"
        },
        {
          "expr": "sum(container_memory_rss{instance=~\"$server:.*\",name=~\".+\"}) by (name)",
          "format": "table",
          "hide": false,
          "instant": true,
          "refId": "B"
        },
        {
          "expr": "sum(rate(container_network_receive_bytes_total{instance=~\"$server:.*\",name=~\".+\"}[$interval])) by (name)",
          "format": "table",
          "hide": false,
          "instant": true,
          "interval": "10s",
          "refId": "H"
        },
        {
          "expr": "sum(rate(container_network_transmit_bytes_total{instance=~\"$server:.*\",name=~\".+\"}[$interval])) by (name)",
          "format": "table",
          "hide": false,
          "instant": true,
          "interval": "10s",
          "refId": "I"
        },
        {
          "refId": "J"
        }
      ],
      "timeFrom": null,
      "timeShift": null,
      "title": "",
      "transform": "table",
      "transparent": true,
      "type": "table"
    }
  ],
  "refresh": false,
  "schemaVersion": 21,
  "style": "dark",
  "tags": [
    "Docker"
  ],
  "templating": {
    "list": [
      {
        "allValue": null,
        "current": {},
        "datasource": "${DS_PROMETHEUS}",
        "definition": "label_values(node_boot_time_seconds, instance)",
        "hide": 0,
        "includeAll": false,
        "label": null,
        "multi": false,
        "name": "server",
        "options": [],
        "query": "label_values(node_boot_time_seconds, instance)",
        "refresh": 1,
        "regex": "/(.*):.*/",
        "skipUrlSync": false,
        "sort": 0,
        "tagValuesQuery": "",
        "tags": [],
        "tagsQuery": "",
        "type": "query",
        "useTags": false
      },
      {
        "auto": false,
        "auto_count": 30,
        "auto_min": "10s",
        "current": {
          "selected": false,
          "text": "30s",
          "value": "30s"
        },
        "hide": 0,
        "label": "interval",
        "name": "interval",
        "options": [
          {
            "selected": true,
            "text": "30s",
            "value": "30s"
          },
          {
            "selected": false,
            "text": "1m",
            "value": "1m"
          },
          {
            "selected": false,
            "text": "2m",
            "value": "2m"
          },
          {
            "selected": false,
            "text": "3m",
            "value": "3m"
          },
          {
            "selected": false,
            "text": "5m",
            "value": "5m"
          },
          {
            "selected": false,
            "text": "7m",
            "value": "7m"
          },
          {
            "selected": false,
            "text": "10m",
            "value": "10m"
          },
          {
            "selected": false,
            "text": "30m",
            "value": "30m"
          },
          {
            "selected": false,
            "text": "1h",
            "value": "1h"
          },
          {
            "selected": false,
            "text": "6h",
            "value": "6h"
          },
          {
            "selected": false,
            "text": "12h",
            "value": "12h"
          },
          {
            "selected": false,
            "text": "1d",
            "value": "1d"
          },
          {
            "selected": false,
            "text": "7d",
            "value": "7d"
          },
          {
            "selected": false,
            "text": "14d",
            "value": "14d"
          },
          {
            "selected": false,
            "text": "30d",
            "value": "30d"
          }
        ],
        "query": "30s,1m,2m,3m,5m,7m,10m,30m,1h,6h,12h,1d,7d,14d,30d",
        "refresh": 2,
        "skipUrlSync": false,
        "type": "interval"
      }
    ]
  },
  "time": {
    "from": "now-5m",
    "to": "now"
  },
  "timepicker": {
    "refresh_intervals": [
      "5s",
      "10s",
      "30s",
      "1m",
      "5m",
      "15m",
      "30m",
      "1h",
      "2h",
      "1d"
    ]
  },
  "timezone": "",
  "title": "1 Docker Dashboard for Prometheus  中文版",
  "uid": "FRVE0VbWz",
  "version": 21,
  "description": "1 Docker Dashboard for Prometheus  中文版"
}