Linux主机列表
总览
。
{
  "__inputs": [
    {
      "name": "DS_PROMETHEUS",
      "label": "Prometheus",
      "description": "",
      "type": "datasource",
      "pluginId": "prometheus",
      "pluginName": "Prometheus"
    }
  ],
  "__requires": [
    {
      "type": "grafana",
      "id": "grafana",
      "name": "Grafana",
      "version": "6.6.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"
      }
    ]
  },
  "description": "总览",
  "editable": true,
  "gnetId": 12649,
  "graphTooltip": 0,
  "id": null,
  "iteration": 1594802488951,
  "links": [],
  "panels": [
    {
      "columns": [],
      "datasource": "${DS_PROMETHEUS}",
      "fontSize": "100%",
      "gridPos": {
        "h": 22,
        "w": 24,
        "x": 0,
        "y": 0
      },
      "id": 2,
      "options": {},
      "pageSize": null,
      "repeat": null,
      "showHeader": true,
      "sort": {
        "col": 1,
        "desc": false
      },
      "styles": [
        {
          "alias": "Time",
          "align": "auto",
          "dateFormat": "YYYY-MM-DD HH:mm:ss",
          "pattern": "Time",
          "type": "hidden"
        },
        {
          "alias": "内存总量",
          "align": "auto",
          "colorMode": null,
          "colors": [
            "rgba(245, 54, 54, 0.9)",
            "rgba(237, 129, 40, 0.89)",
            "rgba(50, 172, 45, 0.97)"
          ],
          "decimals": 2,
          "mappingType": 1,
          "pattern": "Value #C",
          "thresholds": [],
          "type": "number",
          "unit": "bits"
        },
        {
          "alias": "IP",
          "align": "auto",
          "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": "/d/9CWBz0biy/linuxzi-yuan-jian-kong?var-project=${__cell_5}&var-job=${__cell_2}",
          "mappingType": 2,
          "pattern": "ip",
          "preserveFormat": false,
          "rangeMaps": [],
          "sanitize": false,
          "thresholds": [],
          "type": "string",
          "unit": "forceNm"
        },
        {
          "alias": "CPU使用率",
          "align": "auto",
          "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": "CPU核数",
          "align": "auto",
          "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": "short"
        },
        {
          "alias": "系统运行时间",
          "align": "auto",
          "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,
          "mappingType": 1,
          "pattern": "Value #D",
          "thresholds": [],
          "type": "number",
          "unit": "s"
        },
        {
          "alias": "内存使用率",
          "align": "auto",
          "colorMode": "cell",
          "colors": [
            "#1F60C4",
            "#8F3BB8",
            "#FA6400"
          ],
          "dateFormat": "YYYY-MM-DD HH:mm:ss",
          "decimals": 0,
          "mappingType": 1,
          "pattern": "Value #B",
          "thresholds": [
            "50",
            "78"
          ],
          "type": "number",
          "unit": "percent"
        },
        {
          "alias": "磁盘大小",
          "align": "auto",
          "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": "Value #F",
          "thresholds": [],
          "type": "number",
          "unit": "bits"
        },
        {
          "alias": "磁盘使用率",
          "align": "auto",
          "colorMode": "cell",
          "colors": [
            "#1F60C4",
            "#8F3BB8",
            "#FA6400"
          ],
          "dateFormat": "YYYY-MM-DD HH:mm:ss",
          "decimals": 2,
          "mappingType": 1,
          "pattern": "Value #G",
          "thresholds": [
            "50",
            "78"
          ],
          "type": "number",
          "unit": "percent"
        },
        {
          "alias": "网络下载（s）",
          "align": "auto",
          "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）",
          "align": "auto",
          "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": "",
          "align": "auto",
          "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": "",
          "align": "auto",
          "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": "instance",
          "thresholds": [],
          "type": "hidden",
          "unit": "short"
        },
        {
          "alias": "",
          "align": "auto",
          "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": "job",
          "thresholds": [],
          "type": "hidden",
          "unit": "short"
        },
        {
          "alias": "",
          "align": "auto",
          "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": "Time",
          "thresholds": [],
          "type": "number",
          "unit": "short"
        },
        {
          "alias": "类别",
          "align": "auto",
          "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": "part",
          "thresholds": [],
          "type": "string",
          "unit": "short"
        },
        {
          "alias": "项目",
          "align": "auto",
          "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": "project",
          "thresholds": [],
          "type": "string",
          "unit": "short"
        }
      ],
      "targets": [
        {
          "datasource": "${DS_PROMETHEUS}",
          "expr": "label_replace((time() - node_boot_time_seconds),\"ip\",\"$1\",\"instance\",\"(.*):.*\")",
          "format": "table",
          "hide": false,
          "instant": true,
          "interval": "10s",
          "refId": "D"
        },
        {
          "datasource": "${DS_PROMETHEUS}",
          "expr": "label_replace((count(count(node_cpu_seconds_total{mode=\"system\"}) by (instance,cpu)) by (instance)),\"ip\",\"$1\",\"instance\",\"(.*):.*\")",
          "format": "table",
          "hide": false,
          "instant": true,
          "legendFormat": "",
          "refId": "A"
        },
        {
          "datasource": "${DS_PROMETHEUS}",
          "expr": "label_replace((node_memory_MemTotal_bytes),\"ip\",\"$1\",\"instance\",\"(.*):.*\")",
          "format": "table",
          "hide": false,
          "instant": true,
          "legendFormat": "",
          "refId": "C"
        },
        {
          "datasource": "${DS_PROMETHEUS}",
          "expr": "label_replace((sum(node_filesystem_size_bytes{fstype=~\"ext4|xfs\"})by (instance)),\"ip\",\"$1\",\"instance\",\"(.*):.*\")",
          "format": "table",
          "hide": false,
          "instant": true,
          "interval": "10s",
          "refId": "F"
        },
        {
          "datasource": "${DS_PROMETHEUS}",
          "expr": "label_replace((100 - (avg(irate(node_cpu_seconds_total{mode=\"idle\"}[5m]))by (instance) * 100)),\"ip\",\"$1\",\"instance\",\"(.*):.*\")",
          "format": "table",
          "hide": false,
          "instant": true,
          "interval": "",
          "refId": "E"
        },
        {
          "datasource": "${DS_PROMETHEUS}",
          "expr": "label_replace((node_memory_MemTotal_bytes-node_memory_MemFree_bytes-node_memory_Buffers_bytes-node_memory_Cached_bytes) / node_memory_MemTotal_bytes* 100,\"ip\",\"$1\",\"instance\",\"(.*):.*\")",
          "format": "table",
          "hide": false,
          "instant": true,
          "refId": "B"
        },
        {
          "datasource": "${DS_PROMETHEUS}",
          "expr": "label_replace((100 - (sum((node_filesystem_avail_bytes{fstype=~\"ext4|xfs\"}) * 100) by (instance) / sum(node_filesystem_size_bytes{fstype=~\"ext4|xfs\"})by (instance))),\"ip\",\"$1\",\"instance\",\"(.*):.*\")",
          "format": "table",
          "hide": false,
          "instant": true,
          "interval": "10s",
          "refId": "G"
        },
        {
          "datasource": "${DS_PROMETHEUS}",
          "expr": "label_replace((sum(irate(node_network_receive_bytes_total{device!~\"tap.*|veth.*|br.*|docker.*|virbr*|lo*\"}[5m])*8) by (instance)),\"ip\",\"$1\",\"instance\",\"(.*):.*\")",
          "format": "table",
          "hide": false,
          "instant": true,
          "interval": "10s",
          "refId": "H"
        },
        {
          "datasource": "${DS_PROMETHEUS}",
          "expr": "label_replace((sum(irate(node_network_transmit_bytes_total{device!~\"tap.*|veth.*|br.*|docker.*|virbr*|lo*\"}[5m])*8) by (instance)),\"ip\",\"$1\",\"instance\",\"(.*):.*\")",
          "format": "table",
          "hide": false,
          "instant": true,
          "interval": "10s",
          "refId": "I"
        }
      ],
      "timeFrom": null,
      "timeShift": null,
      "title": "",
      "transform": "table",
      "transparent": true,
      "type": "table"
    }
  ],
  "refresh": false,
  "schemaVersion": 22,
  "style": "dark",
  "tags": [
    "node_exporter"
  ],
  "templating": {
    "list": [
      {
        "datasource": "Prometheus",
        "filters": [],
        "hide": 0,
        "label": "",
        "name": "Filters",
        "skipUrlSync": false,
        "type": "adhoc"
      }
    ]
  },
  "time": {
    "from": "now-5m",
    "to": "now"
  },
  "timepicker": {
    "hidden": false,
    "nowDelay": "",
    "refresh_intervals": [
      "5s",
      "10s",
      "30s",
      "1m",
      "5m",
      "15m",
      "30m",
      "1h",
      "2h",
      "1d"
    ]
  },
  "timezone": "",
  "title": "Linux主机列表",
  "uid": "FZyJTbJZz",
  "version": 18
}