部署Prometheus+Grafana批量监控Linux服务器

server/2024/9/19 20:38:52/ 标签: prometheus, grafana

在 Linux 服务器上使用 Docker 容器快速部署 Prometheus 和 Grafana 监控系统,同时通过 node_exporter 采集全面的系统性能数据。整个流程涵盖了从环境配置到搭建一个全面监控平台的每个步骤。

一键安装Node Exporter

Node Exporter 是 Prometheus 生态系统中的一个关键组件,它专门用于收集和导出 Linux 系统的硬件和操作系统指标,如 CPU 使用率、内存利用率、磁盘 IO、网络统计等。这些数据可以帮助你深入了解服务器的性能表现,从而提高系统的监控和管理效率。

该服务所有需要监控的服务器安装,属于数据采集Agent。

下面是一键安装的脚本,脚本设置了国内加速

#!/bin/bash# 定义变量
URL="https://mirror.ghproxy.com/https://github.com/prometheus/node_exporter/releases/download/v1.8.2/node_exporter-1.8.2.linux-amd64.tar.gz"
TAR_FILE="node_exporter-1.8.2.linux-amd64.tar.gz"
DIR_NAME="node_exporter-1.8.2.linux-amd64"
LISTEN_PORT="9100"# 下载文件
echo "Downloading $TAR_FILE..."
wget -c $URL -O $TAR_FILE
if [ $? -ne 0 ]; thenecho "Error: Failed to download $TAR_FILE."exit 1
fi# 解压文件
echo "Extracting $TAR_FILE..."
tar -zxvf $TAR_FILE
if [ $? -ne 0 ]; thenecho "Error: Failed to extract $TAR_FILE."exit 1
fi# 进入解压后的目录
echo "Changing directory to $DIR_NAME..."
cd $DIR_NAME
if [ $? -ne 0 ]; thenecho "Error: Failed to change directory to $DIR_NAME."exit 1
fi# 后台运行 node_exporter
echo "Starting node_exporter on port $LISTEN_PORT..."
nohup ./node_exporter --web.listen-address=":$LISTEN_PORT" > node_exporter.stdout 2>&1 &
if [ $? -ne 0 ]; thenecho "Error: Failed to start node_exporter."exit 1
fiecho "node_exporter started successfully and is listening on port $LISTEN_PORT."

安装prometheus

创建数据存储目录

mkdir /data/prometheus_data && chmod 777 /data/prometheus_data

创建配置文件

将需要监控的节点和添加进配置文件

  - job_name: "node_exporter"static_configs:- targets:- "192.168.1.12:9100"- "192.168.1.13:9100"- "192.168.1.14:9100"- "192.168.1.15:9100"- "192.168.1.3:9100"- "192.168.1.4:9100"- "192.168.1.5:9100"- "192.168.1.6:9100"- "192.168.1.7:9100"

完整的配置文件内容为

# my global config
global:scrape_interval: 15s # Set the scrape interval to every 15 seconds. Default is every 1 minute.evaluation_interval: 15s # Evaluate rules every 15 seconds. The default is every 1 minute.# scrape_timeout is set to the global default (10s).# Alertmanager configuration
alerting:alertmanagers:- static_configs:- targets:# - alertmanager:9093# Load rules once and periodically evaluate them according to the global "evaluation_interval".
rule_files:# - "first_rules.yml"# - "second_rules.yml"# A scrape configuration containing exactly one endpoint to scrape:
# Here it"s Prometheus itself.
scrape_configs:# The job name is added as a label `job=<job_name>` to any timeseries scraped from this config.- job_name: "prometheus"static_configs:- targets: ["localhost:9090"]- job_name: "node_exporter"static_configs:- targets:- "192.168.1.12:9100"- "192.168.1.13:9100"- "192.168.1.14:9100"- "192.168.1.15:9100"- "192.168.1.3:9100"- "192.168.1.4:9100"- "192.168.1.5:9100"- "192.168.1.6:9100"- "192.168.1.7:9100"

tips:这里格式一定要对齐,否则可能会启动失败

设置配置文件权限

chmod 777 /etc/prometheus.yml

下载运行Prometheus

下载运行服务

docker run -d \--name=prometheus \-p 9090:9090 \-v /etc/prometheus.yml:/etc/prometheus/prometheus.yml \-v /data/prometheus_data:/prometheus \--restart always \prom/prometheus

如果拉取不了可以用下面这个

docker run -d \--name=prometheus \-p 9090:9090 \-v /etc/prometheus.yml:/etc/prometheus/prometheus.yml \-v /data/prometheus_data:/prometheus \--restart always \registry.cn-hangzhou.aliyuncs.com/jast-docker/prometheus:latest
参数说明
`-d`使容器在后台运行(分离模式)。
`--name=prometheus`为容器指定名称 `prometheus`,便于管理。
`-p 9090:9090`将宿主机的 `9090` 端口映射到容器的 `9090` 端口,便于访问 Prometheus。
`-v /etc/prometheus.yml:/etc/prometheus/prometheus.yml`挂载宿主机的 Prometheus 配置文件到容器中。
`-v /data/prometheus_data:/prometheus`挂载宿主机的目录用于存储 Prometheus 数据,确保数据持久化。
`--restart always`设定容器在停止后自动重启,保证持续运行。
`prom/prometheus`使用 Prometheus 的官方 Docker 镜像启动容器。

访问:http://localhost:9090 验证是否启动生效

安装Grafana

创建数据目录

mkdir -p grafana/data

下载运行Grafana

docker run -d -p 3000:3000 --name=grafana \--user "$(id -u)" \  --volume "$PWD/grafana/data:/var/lib/grafana" \grafana/grafana  

上面的如果用不了,用下面的国内镜像

docker run -d -p 3000:3000 --name=grafana \--user "$(id -u)" \--restart always \--volume "$PWD/grafana/data:/var/lib/grafana" \registry.cn-hangzhou.aliyuncs.com/jast-docker/grafana:latest

运行完成访问: http://localhost:3000

配置Grafana监控Linux服务器

登录

默认账号密码admin/admin

首次登录后设置密码

添加数据源

选择prometheus

填写prometheus地址

最下方点击保存

导入模板

导入8189模板,官方提供的监控模板

输入名称和数据源导入

监控效果

到此监控已经配置完成,你也可以配置预警值,进行一些告警操作,第一时间发现问题。

json文件内容

{"__inputs": [{"name": "DS__VICTORIAMETRICS-PROD-ALL","label": "Prometheus","description": "","type": "datasource","pluginId": "prometheus","pluginName": "Prometheus"}],"__elements": {},"__requires": [{"type": "panel","id": "bargauge","name": "Bar gauge","version": ""},{"type": "grafana","id": "grafana","name": "Grafana","version": "11.0.0"},{"type": "datasource","id": "prometheus","name": "Prometheus","version": "1.0.0"},{"type": "panel","id": "stat","name": "Stat","version": ""},{"type": "panel","id": "table","name": "Table","version": ""},{"type": "panel","id": "timeseries","name": "Time series","version": ""}],"annotations": {"list": [{"$$hashKey": "object:2875","builtIn": 1,"datasource": {"type": "datasource","uid": "grafana"},"enable": true,"hide": true,"iconColor": "rgba(0, 211, 255, 1)","name": "Annotations & Alerts","target": {"limit": 100,"matchAny": false,"tags": [],"type": "dashboard"},"type": "dashboard"}]},"description": "【中文版本】2024.05.20更新,基于TenSunS采集的ECS,可匹配自动同步方式采集ECS信息字段的展示,优化重要指标展示。使用Grafana10新样式重建,新增健康评分概念,并新增了整体资源消耗信息的一些图表。包含整体资源展示与资源明细图表:CPU 内存 磁盘 IO 网络等监控指标。https://github.com/starsliao/TenSunS","editable": true,"fiscalYearStartMonth": 0,"gnetId": 8919,"graphTooltip": 0,"id": null,"links": [{"$$hashKey": "object:2300","icon": "bolt","tags": [],"targetBlank": true,"title": "Update","tooltip": "更多仪表板","type": "link","url": "https://grafana.com/orgs/starsliao/dashboards"},{"$$hashKey": "object:2301","icon": "question","tags": [],"targetBlank": true,"title": "GitHub","tooltip": "GITHUB:TenSunS","type": "link","url": "https://github.com/starsliao/TenSunS"},{"$$hashKey": "object:2302","asDropdown": true,"icon": "external link","tags": [],"targetBlank": true,"title": "","type": "dashboards"}],"liveNow": false,"panels": [{"collapsed": false,"datasource": {"type": "prometheus","uid": "WAYOn0FGz"},"gridPos": {"h": 1,"w": 24,"x": 0,"y": 0},"id": 187,"panels": [],"title": "🏡资源总览:当前选中主机:$show_name,实例:$instance","type": "row"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"description": "分区使用率、磁盘读取、磁盘写入、下载带宽、上传带宽,如果有多个网卡或者多个分区,是采集的使用率最高的网卡或者分区的数值。\n\n连接数:CurrEstab - 当前状态为 ESTABLISHED 或 CLOSE-WAIT 的 TCP 连接数。\n\n健康值是一个新增的指标,根据CPU,内存,IO计算出来的一个值,低于90分说明系统的资源使用情况需要注意了,这是一个正在测试的指标,参数可能需要根据实际情况再优化。","fieldConfig": {"defaults": {"color": {"mode": "thresholds"},"custom": {"align": "center","cellOptions": {"type": "auto"},"filterable": false,"inspect": false},"decimals": 1,"mappings": [],"max": 100,"thresholds": {"mode": "absolute","steps": [{"color": "green","value": null}]},"unit": "none"},"overrides": [{"matcher": {"id": "byName","options": "内存"},"properties": [{"id": "unit","value": "bytes"},{"id": "decimals"},{"id": "custom.width","value": 66},{"id": "color","value": {"fixedColor": "blue","mode": "fixed"}},{"id": "custom.cellOptions","value": {"type": "color-text"}},{"id": "decimals","value": 0}]},{"matcher": {"id": "byName","options": "启动(天)"},"properties": [{"id": "unit","value": "none"},{"id": "custom.width","value": 68},{"id": "decimals"}]},{"matcher": {"id": "byName","options": "磁盘读取*"},"properties": [{"id": "unit","value": "binBps"},{"id": "custom.cellOptions","value": {"mode": "gradient","type": "color-background"}},{"id": "thresholds","value": {"mode": "absolute","steps": [{"color": "rgba(50, 172, 45, 0.97)","value": null},{"color": "rgba(237, 129, 40, 0.89)","value": 10485760},{"color": "rgba(245, 54, 54, 0.9)","value": 20485760}]}},{"id": "custom.width","value": 93}]},{"matcher": {"id": "byName","options": "磁盘写入*"},"properties": [{"id": "unit","value": "binBps"},{"id": "custom.cellOptions","value": {"mode": "gradient","type": "color-background"}},{"id": "thresholds","value": {"mode": "absolute","steps": [{"color": "rgba(50, 172, 45, 0.97)","value": null},{"color": "rgba(237, 129, 40, 0.89)","value": 10485760},{"color": "rgba(245, 54, 54, 0.9)","value": 20485760}]}},{"id": "custom.width","value": 95}]},{"matcher": {"id": "byName","options": "下载带宽*"},"properties": [{"id": "unit","value": "binbps"},{"id": "custom.cellOptions","value": {"mode": "gradient","type": "color-background"}},{"id": "thresholds","value": {"mode": "absolute","steps": [{"color": "rgba(50, 172, 45, 0.97)","value": null},{"color": "rgba(237, 129, 40, 0.89)","value": 30485760},{"color": "rgba(245, 54, 54, 0.9)","value": 104857600}]}},{"id": "custom.width","value": 91},{"id": "decimals"}]},{"matcher": {"id": "byName","options": "上传带宽*"},"properties": [{"id": "unit","value": "binbps"},{"id": "custom.cellOptions","value": {"mode": "gradient","type": "color-background"}},{"id": "thresholds","value": {"mode": "absolute","steps": [{"color": "rgba(50, 172, 45, 0.97)","value": null},{"color": "rgba(237, 129, 40, 0.89)","value": 30485760},{"color": "rgba(245, 54, 54, 0.9)","value": 104857600}]}},{"id": "custom.width","value": 85},{"id": "decimals"}]},{"matcher": {"id": "byName","options": "负载"},"properties": [{"id": "decimals","value": 2},{"id": "custom.width","value": 67}]},{"matcher": {"id": "byName","options": "连接数"},"properties": [{"id": "custom.cellOptions","value": {"mode": "gradient","type": "color-background"}},{"id": "thresholds","value": {"mode": "absolute","steps": [{"color": "rgba(50, 172, 45, 0.97)","value": null},{"color": "rgba(237, 129, 40, 0.89)","value": 1000},{"color": "rgba(245, 54, 54, 0.9)","value": 1500}]}},{"id": "custom.width","value": 59},{"id": "decimals"}]},{"matcher": {"id": "byName","options": "TCP_tw"},"properties": [{"id": "custom.cellOptions","value": {"mode": "gradient","type": "color-background"}},{"id": "thresholds","value": {"mode": "absolute","steps": [{"color": "rgba(50, 172, 45, 0.97)","value": null},{"color": "rgba(237, 129, 40, 0.89)","value": 5000},{"color": "rgba(245, 54, 54, 0.9)","value": 20000}]}},{"id": "custom.width","value": 69},{"id": "decimals"}]},{"matcher": {"id": "byName","options": "CPU"},"properties": [{"id": "custom.width","value": 46},{"id": "decimals","value": 0},{"id": "custom.cellOptions","value": {"type": "color-text"}},{"id": "color","value": {"fixedColor": "blue","mode": "fixed"}}]},{"matcher": {"id": "byName","options": "IP"},"properties": [{"id": "custom.width","value": 91},{"id": "custom.filterable","value": true},{"id": "mappings","value": [{"options": {"pattern": "/(.*):9100/","result": {"index": 0,"text": "$1"}},"type": "regex"}]}]},{"matcher": {"id": "byName","options": "名称"},"properties": [{"id": "custom.filterable","value": true},{"id": "custom.width","value": 145}]},{"matcher": {"id": "byName","options": "健康值"},"properties": [{"id": "custom.width","value": 57},{"id": "thresholds","value": {"mode": "absolute","steps": [{"color": "red","value": null},{"color": "orange","value": 80},{"color": "green","value": 90}]}},{"id": "color","value": {"mode": "thresholds"}},{"id": "custom.cellOptions","value": {"mode": "gradient","type": "color-background"}}]},{"matcher": {"id": "byRegexp","options": "/.*使用率.*/"},"properties": [{"id": "unit","value": "percent"},{"id": "custom.cellOptions","value": {"mode": "gradient","type": "gauge"}},{"id": "color","value": {"mode": "continuous-GrYlRd"}},{"id": "custom.width","value": 110}]},{"matcher": {"id": "byName","options": "到期日"},"properties": [{"id": "custom.width","value": 97}]},{"matcher": {"id": "byName","options": "实例ID"},"properties": [{"id": "custom.width","value": 115}]}]},"gridPos": {"h": 10,"w": 24,"x": 0,"y": 1},"id": 198,"options": {"cellHeight": "sm","footer": {"countRows": false,"fields": ["Value #B","Value #C","Value #L","Value #H","Value #I","Value #M","Value #N","Value #J","Value #K"],"reducer": ["sum"],"show": false},"showHeader": true,"sortBy": [{"desc": true,"displayName": "到期日"}]},"pluginVersion": "11.0.0","targets": [{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"editorMode": "code","exemplar": false,"expr": "node_uname_info{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\"} - 0","format": "table","hide": false,"instant": true,"interval": "","legendFormat": "主机名","refId": "A"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"editorMode": "code","exemplar": false,"expr": "sum(time() - node_boot_time_seconds{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\"})by(instance)/86400","format": "table","hide": false,"instant": true,"interval": "","legendFormat": "运行时间","refId": "D"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": false,"expr": "node_memory_MemTotal_bytes{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\"} - 0","format": "table","hide": false,"instant": true,"interval": "","legendFormat": "总内存","refId": "B"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": false,"expr": "count(node_cpu_seconds_total{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",mode='system',name=~\".*$sname.*\"}) by (instance)","format": "table","hide": false,"instant": true,"interval": "","legendFormat": "总核数","refId": "C"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": false,"expr": "node_load5{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\"}","format": "table","instant": true,"interval": "","legendFormat": "5分钟负载","refId": "L"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": false,"expr": "(1 - avg(irate(node_cpu_seconds_total{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",mode=\"idle\",name=~\".*$sname.*\"}[$interval])) by (instance)) * 100","format": "table","hide": false,"instant": true,"interval": "","legendFormat": "CPU使用率","refId": "F"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": false,"expr": "(1 - (node_memory_MemAvailable_bytes{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\"} / (node_memory_MemTotal_bytes{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\"})))* 100","format": "table","hide": false,"instant": true,"interval": "","legendFormat": "内存使用率","refId": "G"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": false,"expr": "max((node_filesystem_size_bytes{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\",fstype=~\"ext.?|xfs\"}-node_filesystem_free_bytes{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\",fstype=~\"ext.?|xfs\"}) *100/(node_filesystem_avail_bytes {vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\",fstype=~\"ext.?|xfs\"}+(node_filesystem_size_bytes{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\",fstype=~\"ext.?|xfs\"}-node_filesystem_free_bytes{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\",fstype=~\"ext.?|xfs\"})))by(instance)","format": "table","hide": false,"instant": true,"interval": "","legendFormat": "分区使用率","refId": "E"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": false,"expr": "max(irate(node_disk_read_bytes_total{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\"}[$interval])) by (instance)","format": "table","hide": false,"instant": true,"interval": "","legendFormat": "最大读取","refId": "H"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": false,"expr": "max(irate(node_disk_written_bytes_total{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\"}[$interval])) by (instance)","format": "table","hide": false,"instant": true,"interval": "","legendFormat": "最大写入","refId": "I"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": false,"expr": "node_netstat_Tcp_CurrEstab{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\"} - 0","format": "table","hide": false,"instant": true,"interval": "","legendFormat": "连接数","refId": "M"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": false,"expr": "node_sockstat_TCP_tw{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\"} - 0","format": "table","hide": false,"instant": true,"interval": "","legendFormat": "TIME_WAIT","refId": "N"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": false,"expr": "max(irate(node_network_receive_bytes_total{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\"}[$interval])*8) by (instance)","format": "table","hide": false,"instant": true,"interval": "","legendFormat": "下载带宽","refId": "J"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": false,"expr": "max(irate(node_network_transmit_bytes_total{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\"}[$interval])*8) by (instance)","format": "table","hide": false,"instant": true,"interval": "","legendFormat": "上传带宽","refId": "K"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": false,"expr": "((1-(1 - avg(irate(node_cpu_seconds_total{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\",mode=\"idle\"}[$interval])) by (instance))^1.3)^(1/3)*0.5 + \r\n(1-(1 - avg(node_memory_MemAvailable_bytes{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\"} / node_memory_MemTotal_bytes{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\"})by (instance))^6)^(1/3)*0.3 + \r\n(1 - max(irate(node_disk_io_time_seconds_total{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\"}[$interval]))by (instance)^1.1)^(1/2)*0.2)*100","format": "table","hide": false,"instant": true,"interval": "","legendFormat": "健康评分","refId": "O"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": false,"expr": "max(irate(node_disk_io_time_seconds_total{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\"}[$interval])) by (instance) *100","format": "table","hide": false,"instant": true,"interval": "","legendFormat": "IOutil使用率","refId": "P"}],"title": "服务器资源总览表【分组:$group,主机总数:$total】","transformations": [{"id": "merge","options": {"reducers": []}},{"id": "filterFieldsByName","options": {"include": {"pattern": "/^Value #[^A]|^instance$|^name$|^iid$|^exp$/"}}},{"id": "organize","options": {"excludeByName": {"exp": false},"indexByName": {"Value #B": 6,"Value #C": 7,"Value #D": 3,"Value #E": 12,"Value #F": 9,"Value #G": 10,"Value #H": 13,"Value #I": 14,"Value #J": 17,"Value #K": 18,"Value #L": 8,"Value #M": 15,"Value #N": 16,"Value #O": 5,"Value #P": 11,"exp": 4,"iid": 2,"instance": 1,"name": 0},"renameByName": {"Value #B": "内存","Value #C": "CPU","Value #D": "启动(天)","Value #E": "分区使用率*","Value #F": "CPU使用率","Value #G": "内存使用率","Value #H": "磁盘读取*","Value #I": "磁盘写入*","Value #J": "下载带宽*","Value #K": "上传带宽*","Value #L": "负载","Value #M": "连接数","Value #N": "TCP_tw","Value #O": "健康值","Value #P": "IOutil使用率*","exp": "到期日","iid": "实例ID","instance": "IP","name": "名称","nodename": "主机名"}}}],"type": "table"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"description": "- P99:数据集按升序排列,第99分位置大的数据。(即升序排列后排在99%位置的数据)\n- 该表格需要在Prometheus增加记录规则(参考看板下载页)\n- 采集1小时后出数据\n- 时间范围[7d:1h]表示要查看过去 7 天内每小时的数据点。","fieldConfig": {"defaults": {"color": {"mode": "palette-classic"},"custom": {"align": "center","cellOptions": {"type": "color-text"},"inspect": false},"mappings": [],"max": 100,"min": 0,"thresholds": {"mode": "absolute","steps": [{"color": "green","value": null},{"color": "red","value": 80}]}},"overrides": [{"matcher": {"id": "byRegexp","options": "/.*%/"},"properties": [{"id": "unit","value": "percent"},{"id": "decimals","value": 1},{"id": "custom.width","value": 72},{"id": "color","value": {"mode": "continuous-GrYlRd"}},{"id": "custom.cellOptions","value": {"type": "color-background"}}]},{"matcher": {"id": "byName","options": "IP"},"properties": [{"id": "custom.width","value": 91},{"id": "mappings","value": [{"options": {"pattern": "/(.+):.+/","result": {"index": 0,"text": "$1"}},"type": "regex"}]}]},{"matcher": {"id": "byName","options": "P99内存使用率"},"properties": [{"id": "custom.width","value": 79}]},{"matcher": {"id": "byName","options": "P99CPU使用率"},"properties": [{"id": "custom.width","value": 101}]},{"matcher": {"id": "byName","options": "名称"},"properties": [{"id": "custom.width","value": 128}]}]},"gridPos": {"h": 7,"w": 6,"x": 0,"y": 11},"id": 200,"options": {"cellHeight": "sm","footer": {"countRows": false,"fields": "","reducer": ["sum"],"show": false},"showHeader": true,"sortBy": [{"desc": true,"displayName": "P99内存%"}]},"pluginVersion": "11.0.0","targets": [{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": false,"expr": "node_uname_info{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\"} - 0","format": "table","instant": true,"interval": "","legendFormat": "主机名","refId": "A"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"editorMode": "code","exemplar": false,"expr": "quantile_over_time(0.99, cpu:usage:rate1m{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\"}[7d:1h])","format": "table","hide": false,"instant": true,"interval": "","legendFormat": "CPU使用率P99","refId": "B"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"editorMode": "code","exemplar": false,"expr": "quantile_over_time(0.99, mem:usage:rate1m{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\"}[7d:1h])","format": "table","hide": false,"instant": true,"interval": "","legendFormat": "内存使用率P99","refId": "C"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"editorMode": "code","exemplar": false,"expr": " ((quantile_over_time(0.95, cpu:usage:rate1m{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\"}[7d:1h]) < 10) \r\n and ignoring(cservice,exp,iaccount,igroup,iid,iname,job,region)\r\n (quantile_over_time(0.95, mem:usage:rate1m{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\"}[7d:1h]) < 10)) ","format": "table","hide": true,"instant": true,"interval": "","legendFormat": "内存使用率P99","refId": "D"}],"title": "最近7天P99资源使用率","transformations": [{"id": "seriesToColumns","options": {"byField": "instance"}},{"id": "filterFieldsByName","options": {"include": {"pattern": "/^Value #[^A]|^instance$|^name 1$/"}}},{"id": "organize","options": {"excludeByName": {},"indexByName": {"Value #B": 2,"Value #C": 3,"instance": 1,"name 1": 0},"renameByName": {"Value #B": "P99CPU%","Value #C": "P99内存%","instance": "IP","name": "名称","name 1": "名称","nodename": "主机名"}}}],"type": "table"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"description": "","fieldConfig": {"defaults": {"color": {"mode": "palette-classic"},"custom": {"axisBorderShow": false,"axisCenteredZero": false,"axisColorMode": "series","axisLabel": "总5分钟负载","axisPlacement": "auto","axisSoftMin": 0,"barAlignment": 0,"drawStyle": "line","fillOpacity": 0,"gradientMode": "none","hideFrom": {"legend": false,"tooltip": false,"viz": false},"insertNulls": false,"lineInterpolation": "linear","lineWidth": 2,"pointSize": 5,"scaleDistribution": {"type": "linear"},"showPoints": "never","spanNulls": false,"stacking": {"group": "A","mode": "none"},"thresholdsStyle": {"mode": "off"}},"links": [],"mappings": [],"thresholds": {"mode": "absolute","steps": [{"color": "green","value": null},{"color": "red","value": 80}]},"unit": "none"},"overrides": [{"matcher": {"id": "byName","options": "平均%"},"properties": [{"id": "unit","value": "percent"},{"id": "custom.axisLabel","value": "总平均使用率"},{"id": "custom.pointSize","value": 3},{"id": "custom.lineWidth","value": 1},{"id": "custom.showPoints","value": "always"},{"id": "custom.axisSoftMin"}]},{"matcher": {"id": "byName","options": "核数"},"properties": [{"id": "color","value": {"fixedColor": "#C4162A","mode": "fixed"}},{"id": "custom.pointSize","value": 3},{"id": "custom.drawStyle","value": "points"}]},{"matcher": {"id": "byName","options": "5m负载"},"properties": [{"id": "color","value": {"fixedColor": "orange","mode": "fixed"}}]}]},"gridPos": {"h": 7,"w": 6,"x": 6,"y": 11},"id": 191,"maxDataPoints": 100,"options": {"legend": {"calcs": [],"displayMode": "list","placement": "bottom","showLegend": true},"tooltip": {"maxHeight": 600,"mode": "multi","sort": "desc"}},"pluginVersion": "10.0.2","targets": [{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"editorMode": "code","exemplar": true,"expr": "sum(node_load5{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\".*$sname.*\",name=~\"$name\"})","format": "time_series","hide": false,"interval": "","intervalFactor": 1,"legendFormat": "5m负载","range": true,"refId": "A","step": 240},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"editorMode": "code","exemplar": true,"expr": "count(node_cpu_seconds_total{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\",mode='system'})","format": "time_series","hide": false,"instant": false,"interval": "","intervalFactor": 1,"legendFormat": "核数","refId": "B","step": 240},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"editorMode": "code","exemplar": true,"expr": "avg(1 - avg(irate(node_cpu_seconds_total{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\",mode=\"idle\"}[$interval])) by (instance)) * 100","format": "time_series","hide": false,"interval": "","intervalFactor": 1,"legendFormat": "平均%","range": true,"refId": "F","step": 240}],"title": "整体总负载与整体平均CPU使用率","type": "timeseries"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"fieldConfig": {"defaults": {"color": {"mode": "palette-classic"},"custom": {"axisBorderShow": false,"axisCenteredZero": false,"axisColorMode": "series","axisLabel": "总已用内存","axisPlacement": "auto","axisSoftMin": 0,"barAlignment": 0,"drawStyle": "line","fillOpacity": 0,"gradientMode": "none","hideFrom": {"legend": false,"tooltip": false,"viz": false},"insertNulls": false,"lineInterpolation": "linear","lineWidth": 2,"pointSize": 5,"scaleDistribution": {"type": "linear"},"showPoints": "never","spanNulls": false,"stacking": {"group": "A","mode": "none"},"thresholdsStyle": {"mode": "off"}},"decimals": 0,"links": [],"mappings": [],"thresholds": {"mode": "absolute","steps": [{"color": "green","value": null},{"color": "red","value": 80}]},"unit": "bytes"},"overrides": [{"matcher": {"id": "byName","options": "总内存"},"properties": [{"id": "color","value": {"fixedColor": "#C4162A","mode": "fixed"}},{"id": "custom.drawStyle","value": "points"},{"id": "custom.pointSize","value": 3}]},{"matcher": {"id": "byName","options": "总平均%"},"properties": [{"id": "unit","value": "percent"},{"id": "decimals","value": 1},{"id": "custom.axisLabel","value": "总平均使用率"},{"id": "custom.showPoints","value": "always"},{"id": "custom.lineWidth","value": 1},{"id": "custom.pointSize","value": 3},{"id": "custom.axisSoftMin"}]},{"matcher": {"id": "byName","options": "总已用"},"properties": [{"id": "color","value": {"fixedColor": "orange","mode": "fixed"}}]}]},"gridPos": {"h": 7,"w": 6,"x": 12,"y": 11},"id": 195,"maxDataPoints": 100,"options": {"legend": {"calcs": [],"displayMode": "list","placement": "bottom","showLegend": true},"tooltip": {"maxHeight": 600,"mode": "multi","sort": "desc"}},"pluginVersion": "10.0.2","targets": [{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"editorMode": "code","exemplar": true,"expr": "sum(node_memory_MemTotal_bytes{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\"} - node_memory_MemAvailable_bytes{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\"})","format": "time_series","hide": false,"interval": "","intervalFactor": 1,"legendFormat": "总已用","range": true,"refId": "B","step": 4},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": true,"expr": "sum(node_memory_MemTotal_bytes{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\"})","format": "time_series","hide": false,"instant": false,"interval": "","intervalFactor": 1,"legendFormat": "总内存","refId": "A","step": 4},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"editorMode": "code","exemplar": true,"expr": "(sum(node_memory_MemTotal_bytes{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\"} - node_memory_MemAvailable_bytes{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\"}) / sum(node_memory_MemTotal_bytes{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\"}))*100","format": "time_series","hide": false,"interval": "","intervalFactor": 1,"legendFormat": "总平均%","range": true,"refId": "H"}],"title": "整体总内存与整体平均内存使用率","type": "timeseries"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"description": "","fieldConfig": {"defaults": {"color": {"mode": "palette-classic"},"custom": {"axisBorderShow": false,"axisCenteredZero": false,"axisColorMode": "series","axisLabel": "总磁盘使用量","axisPlacement": "auto","axisSoftMin": 0,"barAlignment": 0,"drawStyle": "line","fillOpacity": 0,"gradientMode": "none","hideFrom": {"legend": false,"tooltip": false,"viz": false},"insertNulls": false,"lineInterpolation": "linear","lineWidth": 2,"pointSize": 5,"scaleDistribution": {"type": "linear"},"showPoints": "never","spanNulls": false,"stacking": {"group": "A","mode": "none"},"thresholdsStyle": {"mode": "off"}},"links": [],"mappings": [],"thresholds": {"mode": "absolute","steps": [{"color": "green","value": null},{"color": "red","value": 80}]},"unit": "bytes"},"overrides": [{"matcher": {"id": "byName","options": "平均%"},"properties": [{"id": "unit","value": "percent"},{"id": "decimals","value": 2},{"id": "custom.axisLabel","value": "总平均使用率"},{"id": "custom.lineWidth","value": 1},{"id": "custom.showPoints","value": "always"},{"id": "custom.pointSize","value": 3},{"id": "custom.axisSoftMin"}]},{"matcher": {"id": "byName","options": "总磁盘量"},"properties": [{"id": "color","value": {"fixedColor": "#C4162A","mode": "fixed"}},{"id": "custom.drawStyle","value": "points"},{"id": "custom.pointSize","value": 3}]},{"matcher": {"id": "byName","options": "总使用量"},"properties": [{"id": "color","value": {"fixedColor": "orange","mode": "fixed"}}]}]},"gridPos": {"h": 7,"w": 6,"x": 18,"y": 11},"id": 197,"maxDataPoints": 100,"options": {"legend": {"calcs": [],"displayMode": "list","placement": "bottom","showLegend": true},"tooltip": {"maxHeight": 600,"mode": "multi","sort": "desc"}},"pluginVersion": "10.0.2","targets": [{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": true,"expr": "sum(avg(node_filesystem_size_bytes{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\",fstype=~\"xfs|ext.*\"})by(device,instance)) - sum(avg(node_filesystem_free_bytes{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\",fstype=~\"xfs|ext.*\"})by(device,instance))","format": "time_series","instant": false,"interval": "","intervalFactor": 1,"legendFormat": "总使用量","refId": "C"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": true,"expr": "sum(avg(node_filesystem_size_bytes{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\",fstype=~\"xfs|ext.*\"})by(device,instance))","format": "time_series","instant": false,"interval": "","intervalFactor": 1,"legendFormat": "总磁盘量","refId": "E"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"editorMode": "code","exemplar": true,"expr": "(sum(avg(node_filesystem_size_bytes{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\",fstype=~\"xfs|ext.*\"})by(device,instance)) - sum(avg(node_filesystem_free_bytes{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\",fstype=~\"xfs|ext.*\"})by(device,instance))) *100/(sum(avg(node_filesystem_avail_bytes{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\",fstype=~\"xfs|ext.*\"})by(device,instance))+(sum(avg(node_filesystem_size_bytes{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\",fstype=~\"xfs|ext.*\"})by(device,instance)) - sum(avg(node_filesystem_free_bytes{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\",fstype=~\"xfs|ext.*\"})by(device,instance))))","format": "time_series","instant": false,"interval": "","intervalFactor": 1,"legendFormat": "平均%","refId": "A"}],"title": "整体总磁盘与整体平均磁盘使用率","type": "timeseries"},{"collapsed": true,"datasource": {"type": "prometheus","uid": "WAYOn0FGz"},"gridPos": {"h": 1,"w": 24,"x": 0,"y": 18},"id": 189,"panels": [{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"description": "本看板中的:磁盘总量、使用量、可用量、使用率保持和df命令的Size、Used、Avail、Use% 列的值一致,并且Use%的值会四舍五入保留一位小数,会更加准确。\n\n注:df中Use%算法为:(size - free) * 100 / (avail + (size - free)),结果是整除则为该值,非整除则为该值+1,结果的单位是%。\n参考df命令源码:","fieldConfig": {"defaults": {"color": {"mode": "thresholds"},"custom": {"align": "center","cellOptions": {"type": "auto"},"inspect": false},"displayName": "","mappings": [],"thresholds": {"mode": "percentage","steps": [{"color": "green","value": null}]},"unit": "none"},"overrides": [{"matcher": {"id": "byName","options": "分区"},"properties": [{"id": "custom.width","value": 81}]},{"matcher": {"id": "byName","options": "剩余空间"},"properties": [{"id": "unit","value": "bytes"},{"id": "decimals"},{"id": "custom.cellOptions","value": {"type": "color-text"}},{"id": "thresholds","value": {"mode": "absolute","steps": [{"color": "red","value": null},{"color": "orange","value": 10000000000},{"color": "green","value": 20000000000}]}},{"id": "custom.width","value": 72}]},{"matcher": {"id": "byName","options": "使用率"},"properties": [{"id": "unit","value": "percent"},{"id": "decimals","value": 0},{"id": "custom.cellOptions","value": {"mode": "gradient","type": "gauge"}},{"id": "custom.width","value": 115},{"id": "min","value": 0},{"id": "max","value": 100},{"id": "color","value": {"mode": "continuous-GrYlRd"}}]},{"matcher": {"id": "byName","options": "总空间"},"properties": [{"id": "unit","value": "bytes"},{"id": "custom.width","value": 75},{"id": "color","value": {"fixedColor": "blue","mode": "fixed"}},{"id": "custom.cellOptions","value": {"type": "color-text"}}]},{"matcher": {"id": "byName","options": "类型"},"properties": [{"id": "custom.width","value": 51}]},{"matcher": {"id": "byName","options": "设备名"},"properties": [{"id": "custom.width","value": 120}]}]},"gridPos": {"h": 6,"w": 8,"x": 0,"y": 19},"id": 181,"links": [{"targetBlank": true,"title": "https://github.com/coreutils/coreutils/blob/master/src/df.c","url": "https://github.com/coreutils/coreutils/blob/master/src/df.c"}],"options": {"cellHeight": "sm","footer": {"countRows": false,"fields": "","reducer": ["sum"],"show": false},"showHeader": true,"sortBy": [{"desc": true,"displayName": "使用率"}]},"pluginVersion": "11.0.0","targets": [{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"editorMode": "code","exemplar": false,"expr": "node_filesystem_size_bytes{instance=~\"$instance\",fstype=~\"ext.*|xfs|nfs\",mountpoint !~\".*pod.*\"}-0","format": "table","hide": false,"instant": true,"interval": "","intervalFactor": 1,"legendFormat": "总量","refId": "C"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"editorMode": "code","exemplar": false,"expr": "node_filesystem_avail_bytes {instance=~\"$instance\",fstype=~\"ext.*|xfs|nfs\",mountpoint !~\".*pod.*\"}-0","format": "table","hide": false,"instant": true,"interval": "10s","intervalFactor": 1,"legendFormat": "","refId": "A"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": false,"expr": "(node_filesystem_size_bytes{instance=~\"$instance\",fstype=~\"ext.*|xfs|nfs\",mountpoint !~\".*pod.*\"}-node_filesystem_free_bytes{instance=~\"$instance\",fstype=~\"ext.*|xfs|nfs\",mountpoint !~\".*pod.*\"}) *100/(node_filesystem_avail_bytes {instance=~\"$instance\",fstype=~\"ext.*|xfs|nfs\",mountpoint !~\".*pod.*\"}+(node_filesystem_size_bytes{instance=~\"$instance\",fstype=~\"ext.*|xfs|nfs\",mountpoint !~\".*pod.*\"}-node_filesystem_free_bytes{instance=~\"$instance\",fstype=~\"ext.*|xfs|nfs\",mountpoint !~\".*pod.*\"}))","format": "table","hide": false,"instant": true,"interval": "","intervalFactor": 1,"legendFormat": "","refId": "B"}],"title": "【$show_name】:分区可用空间(EXT.*/XFS/NFS)","transformations": [{"id": "merge","options": {"reducers": []}},{"id": "filterFieldsByName","options": {"include": {"names": ["device","fstype","mountpoint","Value #C","Value #A","Value #B"]}}},{"id": "organize","options": {"excludeByName": {},"indexByName": {},"renameByName": {"Value #A": "剩余空间","Value #B": "使用率","Value #C": "总空间","device": "设备名","fstype": "类型","mountpoint": "分区"}}}],"type": "table"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"fieldConfig": {"defaults": {"color": {"mode": "thresholds"},"decimals": 1,"mappings": [{"options": {"0": {"text": "N/A"}},"type": "value"}],"max": 100,"min": 0.1,"thresholds": {"mode": "absolute","steps": [{"color": "green","value": null},{"color": "#EAB839","value": 70},{"color": "red","value": 90}]},"unit": "percent"},"overrides": []},"gridPos": {"h": 6,"w": 4,"x": 8,"y": 19},"id": 177,"options": {"displayMode": "lcd","maxVizHeight": 300,"minVizHeight": 45,"minVizWidth": 0,"namePlacement": "auto","orientation": "horizontal","reduceOptions": {"calcs": ["last"],"fields": "","values": false},"showUnfilled": true,"sizing": "auto","valueMode": "color"},"pluginVersion": "11.0.0","targets": [{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": false,"expr": "100 - (avg(irate(node_cpu_seconds_total{instance=~\"$instance\",mode=\"idle\"}[$interval])) * 100)","instant": true,"interval": "","legendFormat": "总CPU使用率","refId": "A"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"editorMode": "code","exemplar": false,"expr": "avg(irate(node_cpu_seconds_total{instance=~\"$instance\",mode=\"iowait\"}[$interval])) * 100","hide": true,"instant": true,"interval": "","legendFormat": "IOwait使用率","refId": "C"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": false,"expr": "(1 - (node_memory_MemAvailable_bytes{instance=~\"$instance\"} / (node_memory_MemTotal_bytes{instance=~\"$instance\"})))* 100","instant": true,"interval": "","legendFormat": "内存使用率","refId": "B"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"editorMode": "code","exemplar": false,"expr": "(node_filesystem_size_bytes{instance=~\"$instance\",fstype=~\"ext.*|xfs\",mountpoint=\"$maxmount\"}-node_filesystem_free_bytes{instance=~\"$instance\",fstype=~\"ext.*|xfs\",mountpoint=\"$maxmount\"})*100 /(node_filesystem_avail_bytes {instance=~\"$instance\",fstype=~\"ext.*|xfs\",mountpoint=\"$maxmount\"}+(node_filesystem_size_bytes{instance=~\"$instance\",fstype=~\"ext.*|xfs\",mountpoint=\"$maxmount\"}-node_filesystem_free_bytes{instance=~\"$instance\",fstype=~\"ext.*|xfs\",mountpoint=\"$maxmount\"}))","hide": false,"instant": true,"interval": "","legendFormat": "最大分区使用率({{mountpoint}})","refId": "D"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"editorMode": "code","exemplar": false,"expr": "(1 - ((node_memory_SwapFree_bytes{instance=~\"$instance\"} + 1)/ (node_memory_SwapTotal_bytes{instance=~\"$instance\"} + 1))) * 100","instant": true,"interval": "","legendFormat": "交换分区使用率","refId": "F"}],"type": "bargauge"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"fieldConfig": {"defaults": {"color": {"mode": "thresholds"},"mappings": [],"thresholds": {"mode": "absolute","steps": [{"color": "green","value": null}]},"unit": "none"},"overrides": [{"matcher": {"id": "byName","options": "运行时间"},"properties": [{"id": "thresholds","value": {"mode": "absolute","steps": [{"color": "red","value": null},{"color": "orange","value": 3600},{"color": "green","value": 7200}]}},{"id": "unit","value": "s"}]},{"matcher": {"id": "byName","options": "总内存"},"properties": [{"id": "unit","value": "bytes"},{"id": "decimals","value": 0}]},{"matcher": {"id": "byName","options": "CPU iowait"},"properties": [{"id": "unit","value": "percent"},{"id": "thresholds","value": {"mode": "percentage","steps": [{"color": "green","value": null},{"color": "orange","value": 40},{"color": "red","value": 60}]}},{"id": "decimals","value": 2}]},{"matcher": {"id": "byName","options": "总文件描述符"},"properties": [{"id": "unit","value": "short"},{"id": "thresholds","value": {"mode": "absolute","steps": [{"color": "red","value": null},{"color": "orange","value": 50000},{"color": "green","value": 200000}]}}]},{"matcher": {"id": "byName","options": "最大打开文件"},"properties": [{"id": "unit","value": "none"},{"id": "thresholds","value": {"mode": "absolute","steps": [{"color": "red","value": null},{"color": "orange","value": 10000},{"color": "green","value": 50000}]}}]}]},"gridPos": {"h": 6,"w": 4,"x": 12,"y": 19},"id": 206,"interval": "15s","options": {"colorMode": "background","graphMode": "none","justifyMode": "center","orientation": "auto","reduceOptions": {"calcs": ["lastNotNull"],"fields": "","values": false},"showPercentChange": false,"text": {"valueSize": 15},"textMode": "auto","wideLayout": true},"pluginVersion": "11.0.0","targets": [{"alias": "","bucketAggs": [{"id": "2","settings": {"interval": "auto"},"type": "date_histogram"}],"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": false,"expr": "avg(time() - node_boot_time_seconds{instance=~\"$instance\"})","hide": false,"instant": true,"interval": "","legendFormat": "运行时间","metrics": [{"id": "1","type": "count"}],"query": "","refId": "C","timeField": "@timestamp"},{"alias": "","bucketAggs": [{"id": "2","settings": {"interval": "auto"},"type": "date_histogram"}],"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": false,"expr": "count(node_cpu_seconds_total{instance=~\"$instance\", mode='system'})","instant": true,"interval": "","legendFormat": "CPU 核数","metrics": [{"id": "1","type": "count"}],"query": "","refId": "A","timeField": "@timestamp"},{"alias": "","bucketAggs": [{"id": "2","settings": {"interval": "auto"},"type": "date_histogram"}],"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": false,"expr": "sum(node_memory_MemTotal_bytes{instance=~\"$instance\"})","hide": false,"instant": true,"interval": "","legendFormat": "总内存","metrics": [{"id": "1","type": "count"}],"query": "","refId": "B","timeField": "@timestamp"},{"alias": "","bucketAggs": [{"id": "2","settings": {"interval": "auto"},"type": "date_histogram"}],"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": false,"expr": "avg(irate(node_cpu_seconds_total{instance=~\"$instance\",mode=\"iowait\"}[$interval])) * 100","hide": false,"instant": true,"interval": "","legendFormat": "CPU iowait","metrics": [{"id": "1","type": "count"}],"query": "","refId": "D","timeField": "@timestamp"},{"alias": "","bucketAggs": [{"id": "2","settings": {"interval": "auto"},"type": "date_histogram"}],"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": false,"expr": "node_filefd_maximum{instance=~\"$instance\"}","hide": false,"instant": true,"interval": "","legendFormat": "总文件描述符","metrics": [{"id": "1","type": "count"}],"query": "","refId": "E","timeField": "@timestamp"},{"alias": "","bucketAggs": [{"id": "2","settings": {"interval": "auto"},"type": "date_histogram"}],"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"editorMode": "code","exemplar": false,"expr": "process_max_fds{job=\"node_exporter\",instance=~\"$instance\"}","hide": false,"instant": true,"interval": "","legendFormat": "最大打开文件","metrics": [{"id": "1","type": "count"}],"query": "","refId": "F","timeField": "@timestamp"}],"type": "stat"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"fieldConfig": {"defaults": {"color": {"mode": "palette-classic"},"custom": {"axisBorderShow": false,"axisCenteredZero": false,"axisColorMode": "text","axisLabel": "","axisPlacement": "auto","barAlignment": 0,"drawStyle": "bars","fillOpacity": 60,"gradientMode": "opacity","hideFrom": {"legend": false,"tooltip": false,"viz": false},"insertNulls": false,"lineInterpolation": "linear","lineWidth": 2,"pointSize": 5,"scaleDistribution": {"type": "linear"},"showPoints": "never","spanNulls": false,"stacking": {"group": "A","mode": "none"},"thresholdsStyle": {"mode": "off"}},"links": [],"mappings": [],"thresholds": {"mode": "absolute","steps": [{"color": "green","value": null},{"color": "red","value": 80}]},"unit": "bytes"},"overrides": [{"matcher": {"id": "byName","options": "cn-shenzhen.i-wz9cq1dcb6zwc39ehw59_cni0_in"},"properties": [{"id": "color","value": {"fixedColor": "light-red","mode": "fixed"}}]},{"matcher": {"id": "byName","options": "cn-shenzhen.i-wz9cq1dcb6zwc39ehw59_cni0_in下载"},"properties": [{"id": "color","value": {"fixedColor": "green","mode": "fixed"}}]},{"matcher": {"id": "byName","options": "cn-shenzhen.i-wz9cq1dcb6zwc39ehw59_cni0_out上传"},"properties": [{"id": "color","value": {"fixedColor": "yellow","mode": "fixed"}}]},{"matcher": {"id": "byName","options": "cn-shenzhen.i-wz9cq1dcb6zwc39ehw59_eth0_in下载"},"properties": [{"id": "color","value": {"fixedColor": "purple","mode": "fixed"}}]},{"matcher": {"id": "byName","options": "cn-shenzhen.i-wz9cq1dcb6zwc39ehw59_eth0_out"},"properties": [{"id": "color","value": {"fixedColor": "purple","mode": "fixed"}}]},{"matcher": {"id": "byName","options": "cn-shenzhen.i-wz9cq1dcb6zwc39ehw59_eth0_out上传"},"properties": [{"id": "color","value": {"fixedColor": "blue","mode": "fixed"}}]}]},"gridPos": {"h": 6,"w": 8,"x": 16,"y": 19},"id": 183,"options": {"legend": {"calcs": [],"displayMode": "list","placement": "bottom","showLegend": true},"tooltip": {"maxHeight": 600,"mode": "multi","sort": "desc"}},"pluginVersion": "10.0.2","targets": [{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": true,"expr": "increase(node_network_receive_bytes_total{instance=~\"$instance\",device=~\"$device\"}[1m])","interval": "1m","intervalFactor": 2,"legendFormat": "{{device}}_in下载","metric": "","refId": "A","step": 600,"target": ""},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": true,"expr": "increase(node_network_transmit_bytes_total{instance=~\"$instance\",device=~\"$device\"}[1m])","hide": false,"interval": "1m","intervalFactor": 2,"legendFormat": "{{device}}_out上传","refId": "B","step": 600}],"title": "每分钟流量$device","type": "timeseries"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"description": "","fieldConfig": {"defaults": {"color": {"mode": "palette-classic"},"custom": {"axisBorderShow": false,"axisCenteredZero": false,"axisColorMode": "series","axisLabel": "总使用率","axisPlacement": "auto","barAlignment": 0,"drawStyle": "line","fillOpacity": 0,"gradientMode": "none","hideFrom": {"legend": false,"tooltip": false,"viz": false},"insertNulls": false,"lineInterpolation": "linear","lineWidth": 1,"pointSize": 5,"scaleDistribution": {"type": "linear"},"showPoints": "never","spanNulls": false,"stacking": {"group": "A","mode": "none"},"thresholdsStyle": {"mode": "off"}},"decimals": 0,"links": [],"mappings": [],"thresholds": {"mode": "absolute","steps": [{"color": "green"},{"color": "red","value": 80}]},"unit": "percent"},"overrides": [{"matcher": {"id": "byRegexp","options": "/.*总使用率/"},"properties": [{"id": "color","value": {"fixedColor": "dark-red","mode": "fixed"}},{"id": "custom.fillOpacity","value": 0},{"id": "custom.lineWidth","value": 2}]},{"matcher": {"id": "byName","options": "磁盘IO使用率"},"properties": [{"id": "custom.axisPlacement","value": "right"},{"id": "custom.axisLabel","value": "磁盘IO使用率"},{"id": "color","value": {"fixedColor": "#0ad4ff","mode": "fixed"}}]},{"matcher": {"id": "byName","options": "用户使用率"},"properties": [{"id": "color","value": {"fixedColor": "yellow","mode": "fixed"}}]},{"matcher": {"id": "byName","options": "系统使用率"},"properties": [{"id": "color","value": {"fixedColor": "green","mode": "fixed"}}]}]},"gridPos": {"h": 8,"w": 8,"x": 0,"y": 25},"id": 207,"options": {"legend": {"calcs": ["mean","lastNotNull","max"],"displayMode": "table","placement": "bottom","showLegend": true,"sortBy": "Max","sortDesc": true},"tooltip": {"mode": "multi","sort": "desc"}},"pluginVersion": "10.0.2","targets": [{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"expr": "(1 - avg(irate(node_cpu_seconds_total{instance=~\"$instance\",mode=\"idle\"}[$interval])) by (instance))*100","format": "time_series","hide": false,"interval": "","intervalFactor": 1,"legendFormat": "总使用率","refId": "F","step": 240},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"editorMode": "code","expr": "avg(irate(node_cpu_seconds_total{instance=~\"$instance\",mode=\"system\"}[$interval])) by (instance) *100","format": "time_series","hide": false,"instant": false,"interval": "","intervalFactor": 1,"legendFormat": "系统使用率","refId": "A","step": 20},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"expr": "avg(irate(node_cpu_seconds_total{instance=~\"$instance\",mode=\"user\"}[$interval])) by (instance) *100","format": "time_series","hide": false,"interval": "","intervalFactor": 1,"legendFormat": "用户使用率","refId": "B","step": 240},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"expr": "avg(irate(node_cpu_seconds_total{instance=~\"$instance\",mode=\"iowait\"}[$interval])) by (instance) *100","format": "time_series","hide": false,"instant": false,"interval": "","intervalFactor": 1,"legendFormat": "磁盘IO使用率","refId": "D","step": 240}],"title": "CPU使用率","type": "timeseries"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"fieldConfig": {"defaults": {"color": {"mode": "palette-classic"},"custom": {"axisBorderShow": false,"axisCenteredZero": false,"axisColorMode": "series","axisLabel": "剩余内存","axisPlacement": "left","axisSoftMin": 0,"barAlignment": 0,"drawStyle": "line","fillOpacity": 0,"gradientMode": "none","hideFrom": {"legend": false,"tooltip": false,"viz": false},"insertNulls": false,"lineInterpolation": "linear","lineWidth": 1,"pointSize": 5,"scaleDistribution": {"type": "linear"},"showPoints": "never","spanNulls": false,"stacking": {"group": "A","mode": "none"},"thresholdsStyle": {"mode": "off"}},"links": [],"mappings": [],"thresholds": {"mode": "absolute","steps": [{"color": "green"},{"color": "red","value": 80}]},"unit": "bytes"},"overrides": [{"matcher": {"id": "byName","options": "可用"},"properties": [{"id": "color","value": {"fixedColor": "#9ac48a","mode": "fixed"}},{"id": "custom.lineWidth","value": 2}]},{"matcher": {"id": "byName","options": "总内存"},"properties": [{"id": "color","value": {"fixedColor": "#C4162A","mode": "fixed"}},{"id": "custom.lineWidth","value": 1},{"id": "custom.pointSize","value": 3},{"id": "custom.showPoints","value": "always"}]},{"matcher": {"id": "byName","options": "使用率"},"properties": [{"id": "color","value": {"fixedColor": "#00d1ff","mode": "fixed"}},{"id": "custom.lineWidth","value": 1},{"id": "unit","value": "percent"},{"id": "custom.axisLabel","value": "内存使用率"},{"id": "custom.pointSize","value": 3},{"id": "custom.showPoints","value": "always"},{"id": "custom.axisPlacement","value": "right"},{"id": "custom.axisSoftMin"}]},{"matcher": {"id": "byName","options": "已用"},"properties": [{"id": "color","value": {"fixedColor": "orange","mode": "fixed"}}]}]},"gridPos": {"h": 8,"w": 8,"x": 8,"y": 25},"id": 156,"options": {"legend": {"calcs": ["mean","lastNotNull","max"],"displayMode": "table","placement": "bottom","showLegend": true,"sortBy": "Max","sortDesc": true},"tooltip": {"mode": "multi","sort": "desc"}},"pluginVersion": "10.0.2","targets": [{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"expr": "node_memory_MemAvailable_bytes{instance=~\"$instance\"}","format": "time_series","hide": false,"interval": "","intervalFactor": 1,"legendFormat": "可用","refId": "F","step": 4},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": true,"expr": "node_memory_MemTotal_bytes{instance=~\"$instance\"}","format": "time_series","hide": false,"instant": false,"interval": "2m","intervalFactor": 1,"legendFormat": "总内存","refId": "A","step": 4},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"expr": "node_memory_MemTotal_bytes{instance=~\"$instance\"} - node_memory_MemAvailable_bytes{instance=~\"$instance\"}","format": "time_series","hide": false,"interval": "","intervalFactor": 1,"legendFormat": "已用","refId": "B","step": 4},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": true,"expr": "(1 - (node_memory_MemAvailable_bytes{instance=~\"$instance\"} / (node_memory_MemTotal_bytes{instance=~\"$instance\"})))* 100","format": "time_series","hide": false,"interval": "","intervalFactor": 1,"legendFormat": "使用率","refId": "H"}],"title": "内存信息","type": "timeseries"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"description": "","fieldConfig": {"defaults": {"color": {"mode": "continuous-GrYlRd"},"custom": {"axisBorderShow": false,"axisCenteredZero": false,"axisColorMode": "series","axisLabel": "容量使用率","axisPlacement": "auto","axisSoftMax": 100,"axisSoftMin": 0,"barAlignment": 0,"drawStyle": "line","fillOpacity": 0,"gradientMode": "none","hideFrom": {"legend": false,"tooltip": false,"viz": false},"insertNulls": false,"lineInterpolation": "linear","lineWidth": 2,"pointSize": 5,"scaleDistribution": {"type": "linear"},"showPoints": "never","spanNulls": false,"stacking": {"group": "A","mode": "none"},"thresholdsStyle": {"mode": "off"}},"links": [],"mappings": [],"thresholds": {"mode": "absolute","steps": [{"color": "green"},{"color": "red","value": 80}]},"unit": "percent"},"overrides": [{"matcher": {"id": "byRegexp","options": "/Inodes.*/"},"properties": [{"id": "color","value": {"fixedColor": "#00d1ff","mode": "fixed"}},{"id": "custom.lineWidth","value": 0},{"id": "custom.showPoints","value": "always"},{"id": "custom.pointSize","value": 3},{"id": "custom.axisLabel","value": "Inodes使用率"}]}]},"gridPos": {"h": 8,"w": 8,"x": 16,"y": 25},"id": 174,"options": {"legend": {"calcs": ["mean","lastNotNull","max"],"displayMode": "table","placement": "bottom","showLegend": true},"tooltip": {"mode": "multi","sort": "desc"}},"pluginVersion": "10.0.2","targets": [{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"editorMode": "code","exemplar": true,"expr": "(node_filesystem_size_bytes{instance=~\"$instance\",fstype=~\"ext.*|xfs|nfs\",mountpoint !~\".*pod.*\"}-node_filesystem_free_bytes{instance=~\"$instance\",fstype=~\"ext.*|xfs|nfs\",mountpoint !~\".*pod.*\"}) *100/(node_filesystem_avail_bytes {instance=~\"$instance\",fstype=~\"ext.*|xfs|nfs\",mountpoint !~\".*pod.*\"}+(node_filesystem_size_bytes{instance=~\"$instance\",fstype=~\"ext.*|xfs|nfs\",mountpoint !~\".*pod.*\"}-node_filesystem_free_bytes{instance=~\"$instance\",fstype=~\"ext.*|xfs|nfs\",mountpoint !~\".*pod.*\"}))","format": "time_series","instant": false,"interval": "","intervalFactor": 1,"legendFormat": "容量%:{{mountpoint}}","refId": "A"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"editorMode": "code","exemplar": true,"expr": "(1 - node_filesystem_files_free{instance=~\"$instance\",fstype=~\"ext.?|xfs|nfs\",mountpoint !~\".*pod.*\"} / node_filesystem_files{instance=~\"$instance\",fstype=~\"ext.?|xfs|nfs\",mountpoint !~\".*pod.*\"}) * 100","hide": false,"interval": "","legendFormat": "Inodes%:{{mountpoint}}","range": true,"refId": "B"}],"title": "磁盘使用率","type": "timeseries"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"fieldConfig": {"defaults": {"color": {"mode": "palette-classic"},"custom": {"axisBorderShow": false,"axisCenteredZero": false,"axisColorMode": "series","axisLabel": "1分钟负载","axisPlacement": "auto","barAlignment": 0,"drawStyle": "line","fillOpacity": 0,"gradientMode": "none","hideFrom": {"legend": false,"tooltip": false,"viz": false},"insertNulls": false,"lineInterpolation": "linear","lineWidth": 1,"pointSize": 5,"scaleDistribution": {"type": "linear"},"showPoints": "never","spanNulls": false,"stacking": {"group": "A","mode": "none"},"thresholdsStyle": {"mode": "off"}},"links": [],"mappings": [],"thresholds": {"mode": "absolute","steps": [{"color": "green"},{"color": "red","value": 80}]},"unit": "none"},"overrides": [{"matcher": {"id": "byName","options": "15分钟负载"},"properties": [{"id": "color","value": {"fixedColor": "purple","mode": "fixed"}}]},{"matcher": {"id": "byName","options": "1分钟负载"},"properties": [{"id": "color","value": {"fixedColor": "orange","mode": "fixed"}}]},{"matcher": {"id": "byName","options": "5分钟负载"},"properties": [{"id": "color","value": {"fixedColor": "blue","mode": "fixed"}}]},{"matcher": {"id": "byRegexp","options": "/.*总核数/"},"properties": [{"id": "color","value": {"fixedColor": "#C4162A","mode": "fixed"}},{"id": "custom.lineWidth","value": 1},{"id": "custom.pointSize","value": 4},{"id": "custom.showPoints","value": "always"}]}]},"gridPos": {"h": 8,"w": 8,"x": 0,"y": 33},"id": 13,"options": {"legend": {"calcs": ["mean","lastNotNull","max"],"displayMode": "table","placement": "bottom","showLegend": true},"tooltip": {"mode": "multi","sort": "desc"}},"pluginVersion": "10.0.2","targets": [{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": true,"expr": "node_load1{instance=~\"$instance\"}","format": "time_series","instant": false,"interval": "","intervalFactor": 1,"legendFormat": "1分钟负载","metric": "","refId": "A","step": 20,"target": ""},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": true,"expr": " sum(count(node_cpu_seconds_total{instance=~\"$instance\", mode='system'}) by (cpu,instance)) by(instance)","format": "time_series","instant": false,"interval": "2m","intervalFactor": 1,"legendFormat": "CPU总核数","refId": "D","step": 20},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"expr": "node_load5{instance=~\"$instance\"}","format": "time_series","instant": false,"interval": "","intervalFactor": 1,"legendFormat": "5分钟负载","refId": "B","step": 20},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"expr": "node_load15{instance=~\"$instance\"}","format": "time_series","instant": false,"interval": "","intervalFactor": 1,"legendFormat": "15分钟负载","refId": "C","step": 20}],"title": "系统平均负载","type": "timeseries"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"fieldConfig": {"defaults": {"color": {"mode": "palette-classic"},"custom": {"axisBorderShow": false,"axisCenteredZero": false,"axisColorMode": "text","axisLabel": "","axisPlacement": "auto","barAlignment": 0,"drawStyle": "bars","fillOpacity": 100,"gradientMode": "opacity","hideFrom": {"legend": false,"tooltip": false,"viz": false},"insertNulls": false,"lineInterpolation": "linear","lineWidth": 1,"pointSize": 5,"scaleDistribution": {"type": "linear"},"showPoints": "never","spanNulls": false,"stacking": {"group": "A","mode": "normal"},"thresholdsStyle": {"mode": "off"}},"mappings": [],"min": 0,"thresholds": {"mode": "absolute","steps": [{"color": "green"},{"color": "red","value": 80}]},"unit": "none"},"overrides": [{"matcher": {"id": "byName","options": "等待IO完成阻塞的进程"},"properties": [{"id": "color","value": {"fixedColor": "red","mode": "fixed"}}]},{"matcher": {"id": "byName","options": "运行态的进程"},"properties": [{"id": "color","value": {"fixedColor": "green","mode": "fixed"}}]},{"matcher": {"id": "byValue","options": {"op": "gte","reducer": "allIsZero","value": 0}},"properties": [{"id": "custom.hideFrom","value": {"legend": true,"tooltip": true,"viz": false}}]},{"matcher": {"id": "byValue","options": {"op": "gte","reducer": "allIsNull","value": 0}},"properties": [{"id": "custom.hideFrom","value": {"legend": true,"tooltip": true,"viz": false}}]}]},"gridPos": {"h": 8,"w": 8,"x": 8,"y": 33},"id": 202,"options": {"legend": {"calcs": ["mean","lastNotNull","max"],"displayMode": "table","placement": "bottom","showLegend": true},"tooltip": {"mode": "multi","sort": "desc"}},"pluginVersion": "10.0.2","targets": [{"calculatedInterval": "2m","datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"datasourceErrors": {},"errors": {},"exemplar": true,"expr": "node_procs_running{instance=~\"$instance\"}","format": "time_series","interval": "1m","intervalFactor": 1,"legendFormat": "运行态的进程","metric": "","prometheusLink": "/api/datasources/proxy/1/graph#%5B%7B%22expr%22%3A%22node_procs_running%7Binstance%3D%5C%22%24host%5C%22%7D%22%2C%22range_input%22%3A%2243200s%22%2C%22end_input%22%3A%222015-9-18%2013%3A46%22%2C%22step_input%22%3A%22%22%2C%22stacked%22%3Atrue%2C%22tab%22%3A0%7D%5D","refId": "A","step": 5,"target": ""},{"calculatedInterval": "2m","datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"datasourceErrors": {},"errors": {},"exemplar": true,"expr": "node_procs_blocked{instance=~\"$instance\"}","format": "time_series","interval": "1m","intervalFactor": 1,"legendFormat": "等待IO完成阻塞的进程","metric": "","prometheusLink": "/api/datasources/proxy/1/graph#%5B%7B%22expr%22%3A%22node_procs_blocked%7Binstance%3D%5C%22%24host%5C%22%7D%22%2C%22range_input%22%3A%2243200s%22%2C%22end_input%22%3A%222015-9-18%2013%3A46%22%2C%22step_input%22%3A%22%22%2C%22stacked%22%3Atrue%2C%22tab%22%3A0%7D%5D","refId": "B","step": 5,"target": ""}],"title": "进程运行状态","type": "timeseries"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"description": "","fieldConfig": {"defaults": {"color": {"mode": "palette-classic"},"custom": {"axisBorderShow": false,"axisCenteredZero": false,"axisColorMode": "series","axisLabel": "","axisPlacement": "auto","barAlignment": 0,"drawStyle": "line","fillOpacity": 0,"gradientMode": "opacity","hideFrom": {"legend": false,"tooltip": false,"viz": false},"insertNulls": false,"lineInterpolation": "linear","lineWidth": 2,"pointSize": 5,"scaleDistribution": {"type": "linear"},"showPoints": "never","spanNulls": false,"stacking": {"group": "A","mode": "none"},"thresholdsStyle": {"mode": "off"}},"links": [],"mappings": [],"min": 0,"thresholds": {"mode": "absolute","steps": [{"color": "green"},{"color": "red","value": 80}]},"unit": "short"},"overrides": [{"matcher": {"id": "byName","options": "总使用FD"},"properties": [{"id": "color","value": {"fixedColor": "red","mode": "fixed"}}]},{"matcher": {"id": "byName","options": "总使用FD占比"},"properties": [{"id": "color","value": {"fixedColor": "yellow","mode": "fixed"}}]},{"matcher": {"id": "byName","options": "每秒上下文切换"},"properties": [{"id": "color","value": {"fixedColor": "dark-blue","mode": "fixed"}}]},{"matcher": {"id": "byRegexp","options": "/.*占比/"},"properties": [{"id": "custom.lineWidth","value": 0},{"id": "unit","value": "percent"},{"id": "custom.showPoints","value": "always"},{"id": "custom.pointSize","value": 3},{"id": "custom.axisSoftMax","value": 100},{"id": "custom.axisSoftMin","value": 0}]},{"matcher": {"id": "byName","options": "进程使用FD占比"},"properties": [{"id": "color","value": {"fixedColor": "dark-orange","mode": "fixed"}}]}]},"gridPos": {"h": 8,"w": 8,"x": 16,"y": 33},"hideTimeOverride": false,"id": 16,"options": {"legend": {"calcs": [],"displayMode": "list","placement": "bottom","showLegend": true},"tooltip": {"mode": "multi","sort": "desc"}},"pluginVersion": "10.0.2","targets": [{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"editorMode": "code","exemplar": true,"expr": "irate(node_context_switches_total{instance=~\"$instance\"}[$interval])","interval": "","intervalFactor": 1,"legendFormat": "每秒上下文切换","range": true,"refId": "A"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"editorMode": "code","exemplar": true,"expr": "node_filefd_allocated{instance=~\"$instance\"}","format": "time_series","instant": false,"interval": "","intervalFactor": 1,"legendFormat": "总使用FD","refId": "B"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"editorMode": "code","exemplar": true,"expr": "(node_filefd_allocated{instance=~\"$instance\"}/node_filefd_maximum{instance=~\"$instance\"}) *100","format": "time_series","hide": false,"instant": false,"interval": "","intervalFactor": 1,"legendFormat": "总使用FD占比","refId": "C"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"editorMode": "code","exemplar": true,"expr": "(process_open_fds{instance=~\"$instance\"}/process_max_fds{instance=~\"$instance\"}) *100","format": "time_series","hide": false,"instant": false,"interval": "","intervalFactor": 1,"legendFormat": "进程使用FD占比","refId": "D"}],"title": "文件描述符(FD)/每秒上下文切换","type": "timeseries"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"description": "Read time seconds 每个磁盘分区读操作花费的秒数\n\nWrite time seconds 每个磁盘分区写操作花费的秒数\n\nIO time seconds 每个磁盘分区输入/输出操作花费的秒数\n\nIO time weighted seconds每个磁盘分区输入/输出操作花费的加权秒数","fieldConfig": {"defaults": {"color": {"mode": "palette-classic"},"custom": {"axisBorderShow": false,"axisCenteredZero": false,"axisColorMode": "text","axisLabel": "读取(-)/写入(+)","axisPlacement": "auto","barAlignment": 0,"drawStyle": "line","fillOpacity": 10,"gradientMode": "opacity","hideFrom": {"legend": false,"tooltip": false,"viz": false},"insertNulls": false,"lineInterpolation": "linear","lineWidth": 1,"pointSize": 5,"scaleDistribution": {"type": "linear"},"showPoints": "never","spanNulls": false,"stacking": {"group": "A","mode": "none"},"thresholdsStyle": {"mode": "off"}},"links": [],"mappings": [],"thresholds": {"mode": "absolute","steps": [{"color": "green"},{"color": "red","value": 80}]},"unit": "s"},"overrides": [{"matcher": {"id": "byName","options": "vda"},"properties": [{"id": "color","value": {"fixedColor": "#6ED0E0","mode": "fixed"}}]},{"matcher": {"id": "byRegexp","options": "/,*_读取$/"},"properties": [{"id": "custom.transform","value": "negative-Y"}]},{"matcher": {"id": "byValue","options": {"op": "gte","reducer": "allIsZero","value": 0}},"properties": [{"id": "custom.hideFrom","value": {"legend": true,"tooltip": true,"viz": false}}]},{"matcher": {"id": "byValue","options": {"op": "gte","reducer": "allIsNull","value": 0}},"properties": [{"id": "custom.hideFrom","value": {"legend": true,"tooltip": true,"viz": false}}]}]},"gridPos": {"h": 8,"w": 6,"x": 0,"y": 41},"id": 160,"options": {"legend": {"calcs": ["mean","lastNotNull","max"],"displayMode": "table","placement": "bottom","showLegend": true},"tooltip": {"mode": "multi","sort": "desc"}},"pluginVersion": "10.4.1","targets": [{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"expr": "irate(node_disk_read_time_seconds_total{instance=~\"$instance\"}[$interval]) / irate(node_disk_reads_completed_total{instance=~\"$instance\"}[$interval])","format": "time_series","hide": false,"instant": false,"interval": "","intervalFactor": 1,"legendFormat": "{{device}}_读取","refId": "B"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"expr": "irate(node_disk_write_time_seconds_total{instance=~\"$instance\"}[$interval]) / irate(node_disk_writes_completed_total{instance=~\"$instance\"}[$interval])","format": "time_series","hide": false,"instant": false,"interval": "","intervalFactor": 1,"legendFormat": "{{device}}_写入","refId": "C"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"expr": "irate(node_disk_io_time_seconds_total{instance=~\"$instance\"}[$interval])","format": "time_series","hide": true,"interval": "","intervalFactor": 1,"legendFormat": "{{device}}","refId": "A","step": 10},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"expr": "irate(node_disk_io_time_weighted_seconds_total{instance=~\"$instance\"}[$interval])","format": "time_series","hide": true,"interval": "","intervalFactor": 1,"legendFormat": "{{device}}_加权","refId": "D"}],"title": "每次IO读写的耗时(参考:小于100ms)","type": "timeseries"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"description": "Reads completed: 每个磁盘分区每秒读完成次数\n\nWrites completed: 每个磁盘分区每秒写完成次数\n\nIO now 每个磁盘分区每秒正在处理的输入/输出请求数","fieldConfig": {"defaults": {"color": {"mode": "palette-classic"},"custom": {"axisBorderShow": false,"axisCenteredZero": false,"axisColorMode": "text","axisLabel": "读取(-)/写入(+)I/O ops/sec","axisPlacement": "auto","barAlignment": 0,"drawStyle": "line","fillOpacity": 0,"gradientMode": "none","hideFrom": {"legend": false,"tooltip": false,"viz": false},"insertNulls": false,"lineInterpolation": "linear","lineWidth": 1,"pointSize": 5,"scaleDistribution": {"type": "linear"},"showPoints": "never","spanNulls": false,"stacking": {"group": "A","mode": "none"},"thresholdsStyle": {"mode": "off"}},"links": [],"mappings": [],"thresholds": {"mode": "absolute","steps": [{"color": "green"},{"color": "red","value": 80}]},"unit": "none"},"overrides": [{"matcher": {"id": "byName","options": "vda_write"},"properties": [{"id": "color","value": {"fixedColor": "#6ED0E0","mode": "fixed"}}]},{"matcher": {"id": "byRegexp","options": "/.*_读取$/"},"properties": [{"id": "custom.transform","value": "negative-Y"}]},{"matcher": {"id": "byValue","options": {"op": "gte","reducer": "allIsZero","value": 0}},"properties": [{"id": "custom.hideFrom","value": {"legend": true,"tooltip": true,"viz": false}}]},{"matcher": {"id": "byValue","options": {"op": "gte","reducer": "allIsNull","value": 0}},"properties": [{"id": "custom.hideFrom","value": {"legend": true,"tooltip": true,"viz": false}}]}]},"gridPos": {"h": 8,"w": 6,"x": 6,"y": 41},"id": 161,"options": {"legend": {"calcs": ["mean","lastNotNull","max"],"displayMode": "table","placement": "bottom","showLegend": true},"tooltip": {"mode": "multi","sort": "desc"}},"pluginVersion": "10.4.1","targets": [{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"expr": "irate(node_disk_reads_completed_total{instance=~\"$instance\"}[$interval])","format": "time_series","hide": false,"interval": "","intervalFactor": 1,"legendFormat": "{{device}}_读取","refId": "A","step": 10},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"expr": "irate(node_disk_writes_completed_total{instance=~\"$instance\"}[$interval])","format": "time_series","hide": false,"interval": "","intervalFactor": 1,"legendFormat": "{{device}}_写入","refId": "B","step": 10},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"expr": "node_disk_io_now{instance=~\"$instance\"}","format": "time_series","hide": true,"interval": "","intervalFactor": 1,"legendFormat": "{{device}}","refId": "C"}],"title": "磁盘读写速率(IOPS)","type": "timeseries"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"description": "Read bytes 每个磁盘分区每秒读取的比特数\nWritten bytes 每个磁盘分区每秒写入的比特数","fieldConfig": {"defaults": {"color": {"mode": "palette-classic"},"custom": {"axisBorderShow": false,"axisCenteredZero": false,"axisColorMode": "text","axisLabel": "读取(-)/写入(+)","axisPlacement": "auto","barAlignment": 0,"drawStyle": "line","fillOpacity": 0,"gradientMode": "none","hideFrom": {"legend": false,"tooltip": false,"viz": false},"insertNulls": false,"lineInterpolation": "linear","lineWidth": 1,"pointSize": 5,"scaleDistribution": {"type": "linear"},"showPoints": "never","spanNulls": false,"stacking": {"group": "A","mode": "none"},"thresholdsStyle": {"mode": "off"}},"links": [],"mappings": [],"thresholds": {"mode": "absolute","steps": [{"color": "green"},{"color": "red","value": 80}]},"unit": "Bps"},"overrides": [{"matcher": {"id": "byName","options": "vda_write"},"properties": [{"id": "color","value": {"fixedColor": "#6ED0E0","mode": "fixed"}}]},{"matcher": {"id": "byRegexp","options": "/.*_读取$/"},"properties": [{"id": "custom.transform","value": "negative-Y"}]},{"matcher": {"id": "byValue","options": {"op": "gte","reducer": "allIsZero","value": 0}},"properties": [{"id": "custom.hideFrom","value": {"legend": true,"tooltip": true,"viz": false}}]},{"matcher": {"id": "byValue","options": {"op": "gte","reducer": "allIsNull","value": 0}},"properties": [{"id": "custom.hideFrom","value": {"legend": true,"tooltip": true,"viz": false}}]}]},"gridPos": {"h": 8,"w": 6,"x": 12,"y": 41},"id": 168,"options": {"legend": {"calcs": ["mean","lastNotNull","max"],"displayMode": "table","placement": "bottom","showLegend": true},"tooltip": {"mode": "multi","sort": "desc"}},"pluginVersion": "10.4.1","targets": [{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"expr": "irate(node_disk_read_bytes_total{instance=~\"$instance\"}[$interval])","format": "time_series","interval": "","intervalFactor": 1,"legendFormat": "{{device}}_读取","refId": "A","step": 10},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"expr": "irate(node_disk_written_bytes_total{instance=~\"$instance\"}[$interval])","format": "time_series","hide": false,"interval": "","intervalFactor": 1,"legendFormat": "{{device}}_写入","refId": "B","step": 10}],"title": "每秒磁盘读写容量","type": "timeseries"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"description": "每一秒钟的自然时间内,花费在I/O上的耗时。(wall-clock time)\n\nnode_disk_io_time_seconds_total:\n磁盘花费在输入/输出操作上的秒数。该值为累加值。(Milliseconds Spent Doing I/Os)\n\nirate(node_disk_io_time_seconds_total[1m]):\n计算每秒的速率:(last值-last前一个值)/时间戳差值,即:1秒钟内磁盘花费在I/O操作的时间占比。","fieldConfig": {"defaults": {"color": {"mode": "palette-classic"},"custom": {"axisBorderShow": false,"axisCenteredZero": false,"axisColorMode": "text","axisLabel": "","axisPlacement": "auto","barAlignment": 0,"drawStyle": "line","fillOpacity": 10,"gradientMode": "opacity","hideFrom": {"legend": false,"tooltip": false,"viz": false},"insertNulls": false,"lineInterpolation": "linear","lineWidth": 1,"pointSize": 5,"scaleDistribution": {"type": "linear"},"showPoints": "never","spanNulls": false,"stacking": {"group": "A","mode": "none"},"thresholdsStyle": {"mode": "off"}},"links": [],"mappings": [],"thresholds": {"mode": "absolute","steps": [{"color": "green"},{"color": "red","value": 80}]},"unit": "percentunit"},"overrides": [{"matcher": {"id": "byName","options": "Idle - Waiting for something to happen"},"properties": [{"id": "color","value": {"fixedColor": "#052B51","mode": "fixed"}}]},{"matcher": {"id": "byName","options": "guest"},"properties": [{"id": "color","value": {"fixedColor": "#9AC48A","mode": "fixed"}}]},{"matcher": {"id": "byName","options": "idle"},"properties": [{"id": "color","value": {"fixedColor": "#052B51","mode": "fixed"}}]},{"matcher": {"id": "byName","options": "iowait"},"properties": [{"id": "color","value": {"fixedColor": "#EAB839","mode": "fixed"}}]},{"matcher": {"id": "byName","options": "irq"},"properties": [{"id": "color","value": {"fixedColor": "#BF1B00","mode": "fixed"}}]},{"matcher": {"id": "byName","options": "nice"},"properties": [{"id": "color","value": {"fixedColor": "#C15C17","mode": "fixed"}}]},{"matcher": {"id": "byName","options": "sdb_每秒I/O操作%"},"properties": [{"id": "color","value": {"fixedColor": "#d683ce","mode": "fixed"}}]},{"matcher": {"id": "byName","options": "softirq"},"properties": [{"id": "color","value": {"fixedColor": "#E24D42","mode": "fixed"}}]},{"matcher": {"id": "byName","options": "steal"},"properties": [{"id": "color","value": {"fixedColor": "#FCE2DE","mode": "fixed"}}]},{"matcher": {"id": "byName","options": "system"},"properties": [{"id": "color","value": {"fixedColor": "#508642","mode": "fixed"}}]},{"matcher": {"id": "byName","options": "user"},"properties": [{"id": "color","value": {"fixedColor": "#5195CE","mode": "fixed"}}]},{"matcher": {"id": "byName","options": "磁盘花费在I/O操作占比"},"properties": [{"id": "color","value": {"fixedColor": "#ba43a9","mode": "fixed"}}]},{"matcher": {"id": "byValue","options": {"op": "gte","reducer": "allIsZero","value": 0}},"properties": [{"id": "custom.hideFrom","value": {"legend": true,"tooltip": true,"viz": false}}]},{"matcher": {"id": "byValue","options": {"op": "gte","reducer": "allIsNull","value": 0}},"properties": [{"id": "custom.hideFrom","value": {"legend": true,"tooltip": true,"viz": false}}]}]},"gridPos": {"h": 8,"w": 6,"x": 18,"y": 41},"id": 175,"options": {"legend": {"calcs": ["mean","lastNotNull","max"],"displayMode": "table","placement": "bottom","showLegend": true},"tooltip": {"mode": "multi","sort": "desc"}},"pluginVersion": "10.4.1","targets": [{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": true,"expr": "irate(node_disk_io_time_seconds_total{instance=~\"$instance\"}[$interval])","format": "time_series","interval": "","intervalFactor": 1,"legendFormat": "{{device}}_每秒I/O操作%","refId": "C"}],"title": "每1秒内I/O操作耗时占比(I/O Util)","type": "timeseries"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"description": "Sockets_used - 已使用的所有协议套接字总量\n\nCurrEstab - 当前状态为 ESTABLISHED 或 CLOSE-WAIT 的 TCP 连接数\n\nTCP_alloc - 已分配(已建立、已申请到sk_buff)的TCP套接字数量\n\nTCP_tw - 等待关闭的TCP连接数\n\nUDP_inuse - 正在使用的 UDP 套接字数量\n\nRetransSegs - TCP 重传报文数\n\nOutSegs - TCP 发送的报文数\n\nInSegs - TCP 接收的报文数","fieldConfig": {"defaults": {"color": {"mode": "palette-classic"},"custom": {"axisBorderShow": false,"axisCenteredZero": false,"axisColorMode": "series","axisLabel": "CurrEstab","axisPlacement": "auto","barAlignment": 0,"drawStyle": "line","fillOpacity": 0,"gradientMode": "none","hideFrom": {"legend": false,"tooltip": false,"viz": false},"insertNulls": false,"lineInterpolation": "linear","lineWidth": 1,"pointSize": 5,"scaleDistribution": {"type": "linear"},"showPoints": "never","spanNulls": false,"stacking": {"group": "A","mode": "none"},"thresholdsStyle": {"mode": "off"}},"links": [],"mappings": [],"thresholds": {"mode": "absolute","steps": [{"color": "green"},{"color": "red","value": 80}]},"unit": "none"},"overrides": [{"matcher": {"id": "byName","options": "TCP_alloc"},"properties": [{"id": "color","value": {"fixedColor": "blue","mode": "fixed"}}]},{"matcher": {"id": "byRegexp","options": "/.*Sockets_used/"},"properties": [{"id": "color","value": {"fixedColor": "#E02F44","mode": "fixed"}},{"id": "custom.lineWidth","value": 1},{"id": "custom.axisLabel","value": "已使用的所有协议套接字总量"},{"id": "custom.showPoints","value": "always"}]}]},"gridPos": {"h": 8,"w": 16,"x": 0,"y": 49},"id": 158,"interval": "","options": {"legend": {"calcs": ["last","max"],"displayMode": "table","placement": "right","showLegend": true,"sortBy": "Max","sortDesc": true},"tooltip": {"mode": "multi","sort": "desc"}},"pluginVersion": "10.0.2","targets": [{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"expr": "node_netstat_Tcp_CurrEstab{instance=~\"$instance\"}","format": "time_series","hide": false,"instant": false,"interval": "","intervalFactor": 1,"legendFormat": "CurrEstab","refId": "A","step": 20},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"expr": "node_sockstat_TCP_tw{instance=~\"$instance\"}","format": "time_series","interval": "","intervalFactor": 1,"legendFormat": "TCP_tw","refId": "D"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": true,"expr": "node_sockstat_sockets_used{instance=~\"$instance\"}","hide": false,"interval": "2m","intervalFactor": 1,"legendFormat": "Sockets_used","refId": "B"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"expr": "node_sockstat_UDP_inuse{instance=~\"$instance\"}","interval": "","legendFormat": "UDP_inuse","refId": "C"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"expr": "node_sockstat_TCP_alloc{instance=~\"$instance\"}","interval": "","legendFormat": "TCP_alloc","refId": "E"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"expr": "irate(node_netstat_Tcp_PassiveOpens{instance=~\"$instance\"}[$interval])","hide": true,"interval": "","legendFormat": "{{instance}}_Tcp_PassiveOpens","refId": "G"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"expr": "irate(node_netstat_Tcp_ActiveOpens{instance=~\"$instance\"}[$interval])","hide": true,"interval": "","legendFormat": "{{instance}}_Tcp_ActiveOpens","refId": "F"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"expr": "irate(node_netstat_Tcp_InSegs{instance=~\"$instance\"}[$interval])","interval": "","legendFormat": "Tcp_InSegs","refId": "H"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"expr": "irate(node_netstat_Tcp_OutSegs{instance=~\"$instance\"}[$interval])","interval": "","legendFormat": "Tcp_OutSegs","refId": "I"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"expr": "irate(node_netstat_Tcp_RetransSegs{instance=~\"$instance\"}[$interval])","hide": false,"interval": "","legendFormat": "Tcp_RetransSegs","refId": "J"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"expr": "irate(node_netstat_TcpExt_ListenDrops{instance=~\"$instance\"}[$interval])","hide": true,"interval": "","legendFormat": "","refId": "K"}],"title": "网络Socket连接信息","type": "timeseries"},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"fieldConfig": {"defaults": {"color": {"mode": "palette-classic"},"custom": {"axisBorderShow": false,"axisCenteredZero": false,"axisColorMode": "text","axisLabel": "上传(-)/下载(+)","axisPlacement": "auto","barAlignment": 0,"drawStyle": "line","fillOpacity": 0,"gradientMode": "none","hideFrom": {"legend": false,"tooltip": false,"viz": false},"insertNulls": false,"lineInterpolation": "linear","lineWidth": 1,"pointSize": 5,"scaleDistribution": {"type": "linear"},"showPoints": "never","spanNulls": false,"stacking": {"group": "A","mode": "none"},"thresholdsStyle": {"mode": "off"}},"links": [],"mappings": [],"thresholds": {"mode": "absolute","steps": [{"color": "green"},{"color": "red","value": 80}]},"unit": "bps"},"overrides": [{"matcher": {"id": "byRegexp","options": "/.*_out上传$/"},"properties": [{"id": "custom.transform","value": "negative-Y"},{"id": "color","value": {"fixedColor": "blue","mode": "fixed"}}]},{"matcher": {"id": "byValue","options": {"op": "gte","reducer": "allIsZero","value": 0}},"properties": [{"id": "custom.hideFrom","value": {"legend": true,"tooltip": true,"viz": false}}]},{"matcher": {"id": "byValue","options": {"op": "gte","reducer": "allIsNull","value": 0}},"properties": [{"id": "custom.hideFrom","value": {"legend": true,"tooltip": true,"viz": false}}]},{"matcher": {"id": "byRegexp","options": "/.*_in下载$/"},"properties": [{"id": "color","value": {"fixedColor": "yellow","mode": "fixed"}}]}]},"gridPos": {"h": 8,"w": 8,"x": 16,"y": 49},"id": 157,"options": {"legend": {"calcs": ["mean","lastNotNull","max"],"displayMode": "table","placement": "bottom","showLegend": true},"tooltip": {"mode": "multi","sort": "desc"}},"pluginVersion": "10.0.2","targets": [{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"exemplar": true,"expr": "irate(node_network_receive_bytes_total{instance=~\"$instance\",device=~\"$device\"}[$interval])*8","format": "time_series","interval": "","intervalFactor": 1,"legendFormat": "{{device}}_in下载","refId": "A","step": 4},{"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"expr": "irate(node_network_transmit_bytes_total{instance=~\"$instance\",device=~\"$device\"}[$interval])*8","format": "time_series","interval": "","intervalFactor": 1,"legendFormat": "{{device}}_out上传","refId": "B","step": 4}],"title": "每秒网络带宽使用$device","type": "timeseries"}],"title": "🧮资源明细:【$show_name】【$instance】【$iid】","type": "row"}],"refresh": "1m","revision": 1,"schemaVersion": 39,"tags": ["Prometheus","node_exporter","StarsL.cn","TenSunS"],"templating": {"list": [{"current": {},"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"definition": "label_values(node_uname_info, vendor)","hide": 0,"includeAll": false,"label": "云厂商","multi": false,"name": "vendor","options": [],"query": {"query": "label_values(node_uname_info, vendor)","refId": "StandardVariableQuery"},"refresh": 2,"regex": "","skipUrlSync": false,"sort": 5,"tagValuesQuery": "","tagsQuery": "","type": "query","useTags": false},{"current": {},"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"definition": "label_values(node_uname_info{vendor=~\"$vendor\"}, account)","hide": 0,"includeAll": false,"label": "账户","multi": false,"name": "account","options": [],"query": {"query": "label_values(node_uname_info{vendor=~\"$vendor\"}, account)","refId": "StandardVariableQuery"},"refresh": 2,"regex": "","skipUrlSync": false,"sort": 5,"tagValuesQuery": "","tagsQuery": "","type": "query","useTags": false},{"current": {},"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"definition": "label_values(node_uname_info{vendor=~\"$vendor\",account=~\"$account\"},group)","hide": 0,"includeAll": true,"label": "分组","multi": false,"name": "group","options": [],"query": {"query": "label_values(node_uname_info{vendor=~\"$vendor\",account=~\"$account\"},group)","refId": "PrometheusVariableQueryEditor-VariableQuery"},"refresh": 2,"regex": "","skipUrlSync": false,"sort": 5,"tagValuesQuery": "","tagsQuery": "","type": "query","useTags": false},{"current": {},"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"definition": "label_values(node_uname_info{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\"},name)","hide": 0,"includeAll": true,"label": "名称","multi": false,"name": "name","options": [],"query": {"query": "label_values(node_uname_info{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\"},name)","refId": "PrometheusVariableQueryEditor-VariableQuery"},"refresh": 2,"regex": "","skipUrlSync": false,"sort": 5,"tagValuesQuery": "","tagsQuery": "","type": "query","useTags": false},{"allFormat": "glob","current": {},"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"definition": "label_values(node_uname_info{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\"},instance)","hide": 0,"includeAll": false,"label": "IP","multi": false,"multiFormat": "regex values","name": "instance","options": [],"query": {"query": "label_values(node_uname_info{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\"},instance)","refId": "PrometheusVariableQueryEditor-VariableQuery"},"refresh": 2,"regex": "","skipUrlSync": false,"sort": 5,"tagValuesQuery": "","tagsQuery": "","type": "query","useTags": false},{"auto": false,"auto_count": 100,"auto_min": "1m","current": {"selected": false,"text": "3m","value": "3m"},"hide": 2,"label": "间隔","name": "interval","options": [{"selected": true,"text": "3m","value": "3m"}],"query": "3m","queryValue": "","refresh": 2,"skipUrlSync": false,"type": "interval"},{"current": {},"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"definition": "query_result(count(node_uname_info{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\"}))","hide": 2,"includeAll": false,"label": "主机数","multi": false,"name": "total","options": [],"query": {"query": "query_result(count(node_uname_info{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",name=~\".*$sname.*\"}))","refId": "StandardVariableQuery"},"refresh": 2,"regex": "/{} (.*) .*/","skipUrlSync": false,"sort": 0,"tagValuesQuery": "","tagsQuery": "","type": "query","useTags": false},{"allFormat": "glob","current": {},"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"definition": "label_values(node_network_info{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",instance=~\"$instance\",device!~'tap.*|veth.*|br.*|docker.*|virbr.*|lo.*|cni.*'},device)","hide": 0,"includeAll": true,"label": "网卡","multi": true,"multiFormat": "regex values","name": "device","options": [],"query": {"query": "label_values(node_network_info{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",instance=~\"$instance\",device!~'tap.*|veth.*|br.*|docker.*|virbr.*|lo.*|cni.*'},device)","refId": "StandardVariableQuery"},"refresh": 2,"regex": "","skipUrlSync": false,"sort": 1,"tagValuesQuery": "","tagsQuery": "","type": "query","useTags": false},{"current": {},"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"definition": "query_result(topk(1,sort_desc (max(node_filesystem_size_bytes{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",instance=~\"$instance\",fstype=~\"ext.?|xfs\",mountpoint!~\".*pods.*\"}) by (mountpoint))))","hide": 2,"includeAll": false,"label": "最大挂载目录","multi": false,"name": "maxmount","options": [],"query": {"query": "query_result(topk(1,sort_desc (max(node_filesystem_size_bytes{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",instance=~\"$instance\",fstype=~\"ext.?|xfs\",mountpoint!~\".*pods.*\"}) by (mountpoint))))","refId": "StandardVariableQuery"},"refresh": 2,"regex": "/.*\\\"(.*)\\\".*/","skipUrlSync": false,"sort": 5,"tagValuesQuery": "","tagsQuery": "","type": "query","useTags": false},{"current": {},"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"definition": "label_values(node_uname_info{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",instance=~\"$instance\"}, name)","hide": 2,"includeAll": false,"label": "展示使用的名称","multi": false,"name": "show_name","options": [],"query": {"query": "label_values(node_uname_info{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\",instance=~\"$instance\"}, name)","refId": "StandardVariableQuery"},"refresh": 2,"regex": "","skipUrlSync": false,"sort": 5,"tagValuesQuery": "","tagsQuery": "","type": "query","useTags": false},{"allFormat": "glob","current": {},"datasource": {"type": "prometheus","uid": "${DS__VICTORIAMETRICS-PROD-ALL}"},"definition": "label_values(node_uname_info{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\"},iid)","hide": 2,"includeAll": false,"label": "实例ID","multi": false,"multiFormat": "regex values","name": "iid","options": [],"query": {"query": "label_values(node_uname_info{vendor=~\"$vendor\",account=~\"$account\",group=~\"$group\",name=~\"$name\"},iid)","refId": "StandardVariableQuery"},"refresh": 2,"regex": "","skipUrlSync": false,"sort": 5,"tagValuesQuery": "","tagsQuery": "","type": "query","useTags": false},{"current": {"selected": false,"text": "","value": ""},"description": "总览表名称字段支持筛选,可以使用正则,如:.*aa.*bb.*","hide": 0,"label": "查询","name": "sname","options": [{"selected": true,"text": "","value": ""}],"query": "","skipUrlSync": false,"type": "textbox"}]},"time": {"from": "now-30m","to": "now"},"timeRangeUpdatedDuringEditOrView": false,"timepicker": {"hidden": false,"now": true,"refresh_intervals": ["30s","1m","3m","5m","15m","30m"],"time_options": ["5m","15m","1h","6h","12h","24h","2d","7d","30d"]},"timezone": "browser","title": "Node Exporter Dashboard 20240520 TenSunS自动同步版","uid": "StarsL-TenSunS-node","version": 9,"weekStart": ""
}


http://www.ppmy.cn/server/117667.html

相关文章

Nacos与Eureka的区别:深入解析微服务中的服务注册与发现

在微服务架构中&#xff0c;服务注册与发现是确保各个服务之间高效通信与协调的重要机制。随着云原生应用的快速发展&#xff0c;服务治理的需求也在不断增长。在这一背景下&#xff0c;Nacos和Eureka作为两种主流的服务注册与发现工具&#xff0c;各具特色和优势。本文将深入分…

除了字符串前导的*号之外,将串中其它*号全部删除

要求 假定输入的字符串中只包含字母和*号。请编写函数fun&#xff0c;它的功能是:除了字符串前导的*号之外&#xff0c;将串中其它*号全部删除。在编写函数时&#xff0c;不得使用C语言提供的字符串函数。函数fun中给出的语句仅供参考。 例如&#xff0c;字符串中的内容为:-**…

GBase 8s数据类型与java.sql.Types对应关系

GBase 8s数据类型与java.sql.Types对应关系 GBase 8s类型类型java.sql.Typesjava类型名称SMALLINT5SMALLINTINTEGER4INTEGERBIGINT-5BIGINTINT8-5BIGINTSMALLFLOAT7REALFLOAT8DOUBLEDECIMAL3DECIMALMONEY3DECIMALCHAR1CHARNCHAR1CHARVARCHAR12VARCHARNVARCHAR12VARCHARVARCHAR…

基于Vue.js的超市商品管理导购中心设计与实现(任务书)

本科毕业论文&#xff08;设计&#xff09;任务书 学院&#xff1a;数学与数据科学学院 学生姓名 专业班级 信息与计算科学202班 学号 校内指导教师姓名 职称/职务 副教授 签名 校外指导教师姓名 职称/职务 工程师 签名 论文题目 基于Vue.js的超市商品管理导购中心 起始日期…

Web安全与网络安全:SQL漏洞注入

Web安全与网络安全&#xff1a;SQL漏洞注入 引言 在Web安全领域&#xff0c;SQL注入漏洞&#xff08;SQL Injection Vulnerability&#xff09;是一种极具破坏性的安全威胁。它允许攻击者通过向Web应用程序的输入字段中插入或“注入”恶意的SQL代码片段&#xff0c;从而操纵后…

uni-app 应用名称 跟随系统语言 改变

官方已确认BUG:&#xff1a;https://ask.dcloud.net.cn/question/164804 { "name" : "%app.name%",//这里随便写&#xff0c;配置了 locales,name 就不生效了 "appid" : "", "description" : "", "versi…

Pytorch详解-Pytorch核心模块

Pytorch核心模块 一、Pytorch模块结构_pycache__Cincludelibautogradnnoptimutils 二、Lib\site-packages\torchvisiondatasetsmodelsopstransforms 三、核心数据结构——Tensor&#xff08;张量&#xff09;在深度学习中&#xff0c;时间序列数据为什么是三维张量&#xff1f;…

基于鸿蒙API10的RTSP播放器(七:亮度调节功能测试)

目标&#xff1a; 当我的手指在设备左方进行上下移动的时候&#xff0c;可以进行屏幕亮度的调节&#xff0c;在调节的同时&#xff0c;有实时的调节进度条显示 步骤&#xff1a; 界面逻辑&#xff1a;使用Stack() 组件&#xff0c;完成音量图标和进度条的组合显示&#xff0c…

Kubernetes Pod镜像的3种状态

Kubernetes Pod镜像的3种状态 1. Pending状态2. Running状态3. Unknown状态💖The Begin💖点点关注,收藏不迷路💖 1. Pending状态 定义:Pod已被创建但尚未启动。 原因: 资源不足(CPU、内存等)。调度策略或标签选择器不匹配。镜像正在从仓库下载中。解决方案:检查资…

java 网络编程URL与URLConnection的使用

Java中的网络编程不仅限于Socket编程&#xff0c;还包括使用java.net.URL和java.net.URLConnection来进行简单的网络请求和数据获取。URL类用于表示统一资源定位符&#xff08;Uniform Resource Locator&#xff09;&#xff0c;而URLConnection类提供了与URL进行通信的功能。下…

RedisTemplate操作ZSet的API

文章目录 ⛄概述⛄常见命令有⛄RedisTemplate API❄️❄️ 向集合中插入元素&#xff0c;并设置分数❄️❄️向集合中插入多个元素,并设置分数❄️❄️按照排名先后(从小到大)打印指定区间内的元素, -1为打印全部❄️❄️获得指定元素的分数❄️❄️返回集合内的成员个数❄️❄…

【无人机设计与控制】四旋翼飞行无人机姿态控制ADRC非线性自抗扰控制Simulink仿真

摘要 本研究针对四旋翼飞行无人机姿态控制&#xff0c;提出了一种基于非线性自抗扰控制&#xff08;ADRC&#xff09;的控制策略。通过Simulink对系统进行了建模和仿真&#xff0c;验证了所设计控制器在不同工况下的有效性和鲁棒性。仿真结果表明&#xff0c;所设计的控制器能…

TensorFlow 笔记

------------------------------- 1. 创建模型阶段 ------------------------------- 1. Activation 激活函数&#xff0c; 属于模型的一个层&#xff0c;可以用于中间层&#xff0c;输出层。 ReLU (Rectified Linear Unit), 修正线性单元&#xff0c;即 max(0, x)&#xff…

【目标检测数据集】锯子数据集1107张VOC+YOLO格式

数据集格式&#xff1a;Pascal VOC格式YOLO格式(不包含分割路径的txt文件&#xff0c;仅仅包含jpg图片以及对应的VOC格式xml文件和yolo格式txt文件) 图片数量(jpg文件个数)&#xff1a;1107 标注数量(xml文件个数)&#xff1a;1107 标注数量(txt文件个数)&#xff1a;1107 标注…

创建一个Java项目在IntelliJ IDEA中

创建一个Java项目在IntelliJ IDEA中是一个直观且功能强大的过程&#xff0c;适合从初学者到经验丰富的开发者。IntelliJ IDEA由JetBrains开发&#xff0c;被誉为Java开发领域最受欢迎的IDE&#xff08;集成开发环境&#xff09;之一&#xff0c;它提供了代码自动补全、版本控制…

模仿抖音用户ID加密ID的算法MB4E,提高自己平台ID安全性

先看抖音的格式 对ID加密的格式 MB4EENgLILJPeQKhJht-rjcc6y0ECMk_RGTceg6JBAA 需求是 同一个ID 比如 413884936367560 每次获取得到的加密ID都是不同的&#xff0c;最终解密的ID都是413884936367560 注意这是一个加密后可解密原文的方式&#xff0c;不是单向加密 那么如下进行…

2024/9/15 408“回头看”之应用层小总结(下)

域名系统DNS: 本地域名服务器 本地域名服务器起着代理的作用&#xff0c;会将报文转发到根域名服务器、顶级域名服务器、权限域名服务器。 递归查询&#xff1a; 迭代查询&#xff1a; 文件传送协议FTP: FTP客户和FTP服务器之间使用的是tcp连接。 控制连接使用21端口&…

优化算法(三)—模拟退火算法(附MATLAB程序)

模拟退火算法&#xff08;Simulated Annealing, SA&#xff09;是一种基于概率的优化算法&#xff0c;旨在寻找全局最优解。该算法模拟金属退火过程中的物质冷却过程&#xff0c;逐渐降低系统的“温度”以达到全局优化的效果。它特别适用于解决复杂的组合优化问题。 一、模拟退…

Java 中使用 Redis 的几种方式优缺点对比

一、为什么选择 Redis&#xff1f; 在分析 Java 中使用 Redis 的不同方式之前&#xff0c;我们需要了解为什么 Redis 在分布式应用中如此重要。以下是 Redis 在 Java 项目中常见的应用场景&#xff1a; 缓存&#xff1a;通过将热点数据缓存到 Redis&#xff0c;可以减少数据库…

一文速通calcite结合flink理解SQL从文本变成执行计划详细过程

文章目录 你可以学到啥测试代码背景知识SQL转变流程图问题 你可以学到啥 SQL如何一步步变成执行计划的有哪些优化器&#xff0c;哪些优化规则calcite 和flink 如何结合的 测试代码 EnvironmentSettings settings EnvironmentSettings.inBatchMode(); TableEnvironment tabl…