From da10b50174b3c6c8f43c90dfdd3d57627882aadf Mon Sep 17 00:00:00 2001 From: Ruslan Gilfanov Date: Sun, 21 Jun 2026 22:57:54 +0300 Subject: [PATCH] =?UTF-8?q?monitoring:=20network=20=D0=B4=D0=B0=D1=88?= =?UTF-8?q?=D0=B1=D0=BE=D1=80=D0=B4=20=E2=80=94=20=D0=BF=D0=B0=D0=BD=D0=B5?= =?UTF-8?q?=D0=BB=D0=B8=20=D0=BE=D0=B1=D1=8A=D1=91=D0=BC=D0=B0=20(=D0=93?= =?UTF-8?q?=D0=91=20=D0=B7=D0=B0=20=D0=BF=D0=B5=D1=80=D0=B8=D0=BE=D0=B4)?= =?UTF-8?q?=20+=20=D1=81=D0=BA=D0=BE=D1=80=D0=BE=D1=81=D1=82=D1=8C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../provisioning/dashboards/network.json | 64 ++++++++++++------- 1 file changed, 40 insertions(+), 24 deletions(-) diff --git a/stacks/monitoring/grafana/provisioning/dashboards/network.json b/stacks/monitoring/grafana/provisioning/dashboards/network.json index 07c3b2b..9a9dbcb 100644 --- a/stacks/monitoring/grafana/provisioning/dashboards/network.json +++ b/stacks/monitoring/grafana/provisioning/dashboards/network.json @@ -4,9 +4,9 @@ "tags": ["network", "infra"], "timezone": "browser", "schemaVersion": 39, - "version": 1, + "version": 2, "refresh": "30s", - "time": { "from": "now-3h", "to": "now" }, + "time": { "from": "now-24h", "to": "now" }, "templating": { "list": [ { @@ -25,31 +25,53 @@ }, "panels": [ { - "type": "timeseries", "title": "Входящий трафик (RX)", "gridPos": { "h": 8, "w": 12, "x": 0, "y": 0 }, + "type": "row", "title": "Объём за выбранный период (диапазон вверху справа)", "gridPos": { "h": 1, "w": 24, "x": 0, "y": 0 } + }, + { + "type": "stat", "title": "Принято всего (RX)", "gridPos": { "h": 5, "w": 6, "x": 0, "y": 1 }, + "datasource": { "type": "prometheus", "uid": "prometheus" }, + "fieldConfig": { "defaults": { "unit": "bytes", "color": { "mode": "fixed", "fixedColor": "green" } } }, + "options": { "colorMode": "value", "graphMode": "area" }, + "targets": [ { "expr": "sum(increase(node_network_receive_bytes_total{instance=~\"$instance\",device=~\"$device\"}[$__range]))", "refId": "A" } ] + }, + { + "type": "stat", "title": "Отдано всего (TX)", "gridPos": { "h": 5, "w": 6, "x": 6, "y": 1 }, + "datasource": { "type": "prometheus", "uid": "prometheus" }, + "fieldConfig": { "defaults": { "unit": "bytes", "color": { "mode": "fixed", "fixedColor": "blue" } } }, + "options": { "colorMode": "value", "graphMode": "area" }, + "targets": [ { "expr": "sum(increase(node_network_transmit_bytes_total{instance=~\"$instance\",device=~\"$device\"}[$__range]))", "refId": "A" } ] + }, + { + "type": "bargauge", "title": "Объём по интерфейсам (RX за период)", "gridPos": { "h": 5, "w": 6, "x": 12, "y": 1 }, + "datasource": { "type": "prometheus", "uid": "prometheus" }, + "fieldConfig": { "defaults": { "unit": "bytes" } }, + "options": { "displayMode": "gradient", "orientation": "horizontal" }, + "targets": [ { "expr": "increase(node_network_receive_bytes_total{instance=~\"$instance\",device=~\"$device\"}[$__range])", "legendFormat": "{{device}}", "refId": "A", "instant": true } ] + }, + { + "type": "bargauge", "title": "Объём по интерфейсам (TX за период)", "gridPos": { "h": 5, "w": 6, "x": 18, "y": 1 }, + "datasource": { "type": "prometheus", "uid": "prometheus" }, + "fieldConfig": { "defaults": { "unit": "bytes" } }, + "options": { "displayMode": "gradient", "orientation": "horizontal" }, + "targets": [ { "expr": "increase(node_network_transmit_bytes_total{instance=~\"$instance\",device=~\"$device\"}[$__range])", "legendFormat": "{{device}}", "refId": "A", "instant": true } ] + }, + { + "type": "row", "title": "Скорость (мгновенная)", "gridPos": { "h": 1, "w": 24, "x": 0, "y": 6 } + }, + { + "type": "timeseries", "title": "Скорость входящего (RX), бит/с", "gridPos": { "h": 8, "w": 12, "x": 0, "y": 7 }, "datasource": { "type": "prometheus", "uid": "prometheus" }, "fieldConfig": { "defaults": { "unit": "bps", "custom": { "drawStyle": "line", "lineWidth": 2, "fillOpacity": 10 } } }, "targets": [ { "expr": "rate(node_network_receive_bytes_total{instance=~\"$instance\",device=~\"$device\"}[$__rate_interval])*8", "legendFormat": "{{device}}", "refId": "A" } ] }, { - "type": "timeseries", "title": "Исходящий трафик (TX)", "gridPos": { "h": 8, "w": 12, "x": 12, "y": 0 }, + "type": "timeseries", "title": "Скорость исходящего (TX), бит/с", "gridPos": { "h": 8, "w": 12, "x": 12, "y": 7 }, "datasource": { "type": "prometheus", "uid": "prometheus" }, "fieldConfig": { "defaults": { "unit": "bps", "custom": { "drawStyle": "line", "lineWidth": 2, "fillOpacity": 10 } } }, "targets": [ { "expr": "rate(node_network_transmit_bytes_total{instance=~\"$instance\",device=~\"$device\"}[$__rate_interval])*8", "legendFormat": "{{device}}", "refId": "A" } ] }, { - "type": "stat", "title": "RX суммарно (сейчас)", "gridPos": { "h": 6, "w": 6, "x": 0, "y": 8 }, - "datasource": { "type": "prometheus", "uid": "prometheus" }, - "fieldConfig": { "defaults": { "unit": "bps", "color": { "mode": "thresholds" }, "thresholds": { "steps": [ { "color": "green", "value": null } ] } } }, - "targets": [ { "expr": "sum(rate(node_network_receive_bytes_total{instance=~\"$instance\",device=~\"$device\"}[$__rate_interval])*8)", "refId": "A" } ] - }, - { - "type": "stat", "title": "TX суммарно (сейчас)", "gridPos": { "h": 6, "w": 6, "x": 6, "y": 8 }, - "datasource": { "type": "prometheus", "uid": "prometheus" }, - "fieldConfig": { "defaults": { "unit": "bps", "color": { "mode": "thresholds" }, "thresholds": { "steps": [ { "color": "blue", "value": null } ] } } }, - "targets": [ { "expr": "sum(rate(node_network_transmit_bytes_total{instance=~\"$instance\",device=~\"$device\"}[$__rate_interval])*8)", "refId": "A" } ] - }, - { - "type": "timeseries", "title": "Пакеты/с (RX +, TX −)", "gridPos": { "h": 6, "w": 12, "x": 12, "y": 8 }, + "type": "timeseries", "title": "Пакеты/с (RX +, TX −)", "gridPos": { "h": 6, "w": 12, "x": 0, "y": 15 }, "datasource": { "type": "prometheus", "uid": "prometheus" }, "fieldConfig": { "defaults": { "unit": "pps", "custom": { "drawStyle": "line", "lineWidth": 1, "fillOpacity": 5 } } }, "targets": [ @@ -58,7 +80,7 @@ ] }, { - "type": "timeseries", "title": "Ошибки и дропы /с", "gridPos": { "h": 7, "w": 12, "x": 0, "y": 14 }, + "type": "timeseries", "title": "Ошибки и дропы /с", "gridPos": { "h": 6, "w": 12, "x": 12, "y": 15 }, "datasource": { "type": "prometheus", "uid": "prometheus" }, "fieldConfig": { "defaults": { "unit": "pps", "custom": { "drawStyle": "line", "lineWidth": 2, "fillOpacity": 10 } } }, "targets": [ @@ -67,12 +89,6 @@ { "expr": "rate(node_network_receive_drop_total{instance=~\"$instance\",device=~\"$device\"}[$__rate_interval])", "legendFormat": "rx drop {{device}}", "refId": "C" }, { "expr": "rate(node_network_transmit_drop_total{instance=~\"$instance\",device=~\"$device\"}[$__rate_interval])", "legendFormat": "tx drop {{device}}", "refId": "D" } ] - }, - { - "type": "timeseries", "title": "Статус интерфейсов (up=1)", "gridPos": { "h": 7, "w": 12, "x": 12, "y": 14 }, - "datasource": { "type": "prometheus", "uid": "prometheus" }, - "fieldConfig": { "defaults": { "unit": "short", "max": 1, "min": 0, "custom": { "drawStyle": "line", "lineWidth": 2, "fillOpacity": 0 } } }, - "targets": [ { "expr": "node_network_up{instance=~\"$instance\",device=~\"$device\"}", "legendFormat": "{{device}}", "refId": "A" } ] } ] }