|
@@ -0,0 +1,960 @@
|
|
|
|
+{
|
|
|
|
+ "__inputs": [
|
|
|
|
+ {
|
|
|
|
+ "name": "DS_INFLUXDB",
|
|
|
|
+ "label": "InfluxDB",
|
|
|
|
+ "description": "",
|
|
|
|
+ "type": "datasource",
|
|
|
|
+ "pluginId": "influxdb",
|
|
|
|
+ "pluginName": "InfluxDB"
|
|
|
|
+ }
|
|
|
|
+ ],
|
|
|
|
+ "__elements": {},
|
|
|
|
+ "__requires": [
|
|
|
|
+ {
|
|
|
|
+ "type": "grafana",
|
|
|
|
+ "id": "grafana",
|
|
|
|
+ "name": "Grafana",
|
|
|
|
+ "version": "9.1.4"
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ "type": "datasource",
|
|
|
|
+ "id": "influxdb",
|
|
|
|
+ "name": "InfluxDB",
|
|
|
|
+ "version": "1.0.0"
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ "type": "panel",
|
|
|
|
+ "id": "stat",
|
|
|
|
+ "name": "Stat",
|
|
|
|
+ "version": ""
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ "type": "panel",
|
|
|
|
+ "id": "timeseries",
|
|
|
|
+ "name": "Time series",
|
|
|
|
+ "version": ""
|
|
|
|
+ }
|
|
|
|
+ ],
|
|
|
|
+ "annotations": {
|
|
|
|
+ "list": [
|
|
|
|
+ {
|
|
|
|
+ "builtIn": 1,
|
|
|
|
+ "datasource": {
|
|
|
|
+ "type": "grafana",
|
|
|
|
+ "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"
|
|
|
|
+ }
|
|
|
|
+ ]
|
|
|
|
+ },
|
|
|
|
+ "editable": true,
|
|
|
|
+ "fiscalYearStartMonth": 0,
|
|
|
|
+ "graphTooltip": 0,
|
|
|
|
+ "id": null,
|
|
|
|
+ "links": [],
|
|
|
|
+ "liveNow": false,
|
|
|
|
+ "panels": [
|
|
|
|
+ {
|
|
|
|
+ "datasource": {
|
|
|
|
+ "type": "influxdb",
|
|
|
|
+ "uid": "${DS_INFLUXDB}"
|
|
|
|
+ },
|
|
|
|
+ "fieldConfig": {
|
|
|
|
+ "defaults": {
|
|
|
|
+ "color": {
|
|
|
|
+ "fixedColor": "green",
|
|
|
|
+ "mode": "fixed"
|
|
|
|
+ },
|
|
|
|
+ "mappings": [],
|
|
|
|
+ "thresholds": {
|
|
|
|
+ "mode": "absolute",
|
|
|
|
+ "steps": [
|
|
|
|
+ {
|
|
|
|
+ "color": "green",
|
|
|
|
+ "value": null
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ "color": "red",
|
|
|
|
+ "value": 80
|
|
|
|
+ }
|
|
|
|
+ ]
|
|
|
|
+ },
|
|
|
|
+ "unit": "locale"
|
|
|
|
+ },
|
|
|
|
+ "overrides": []
|
|
|
|
+ },
|
|
|
|
+ "gridPos": {
|
|
|
|
+ "h": 6,
|
|
|
|
+ "w": 4,
|
|
|
|
+ "x": 0,
|
|
|
|
+ "y": 0
|
|
|
|
+ },
|
|
|
|
+ "id": 2,
|
|
|
|
+ "interval": "10m",
|
|
|
|
+ "options": {
|
|
|
|
+ "colorMode": "value",
|
|
|
|
+ "graphMode": "area",
|
|
|
|
+ "justifyMode": "auto",
|
|
|
|
+ "orientation": "auto",
|
|
|
|
+ "reduceOptions": {
|
|
|
|
+ "calcs": [
|
|
|
|
+ "sum"
|
|
|
|
+ ],
|
|
|
|
+ "fields": "",
|
|
|
|
+ "values": false
|
|
|
|
+ },
|
|
|
|
+ "textMode": "auto"
|
|
|
|
+ },
|
|
|
|
+ "pluginVersion": "9.1.4",
|
|
|
|
+ "targets": [
|
|
|
|
+ {
|
|
|
|
+ "datasource": {
|
|
|
|
+ "type": "influxdb",
|
|
|
|
+ "uid": "${DS_INFLUXDB}"
|
|
|
|
+ },
|
|
|
|
+ "query": "from(bucket: \"pihole\")\r\n |> range(start: v.timeRangeStart, stop: v.timeRangeStop)\r\n |> filter(fn: (r) => r[\"_measurement\"] == \"queries\")\r\n |> filter(fn: (r) => r[\"_field\"] == \"queries\")\r\n |> aggregateWindow(every: v.windowPeriod, fn: sum, createEmpty: false)\r\n |> yield(name: \"sum\")",
|
|
|
|
+ "refId": "A"
|
|
|
|
+ }
|
|
|
|
+ ],
|
|
|
|
+ "title": "Total Queries",
|
|
|
|
+ "transparent": true,
|
|
|
|
+ "type": "stat"
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ "datasource": {
|
|
|
|
+ "type": "influxdb",
|
|
|
|
+ "uid": "${DS_INFLUXDB}"
|
|
|
|
+ },
|
|
|
|
+ "fieldConfig": {
|
|
|
|
+ "defaults": {
|
|
|
|
+ "color": {
|
|
|
|
+ "fixedColor": "purple",
|
|
|
|
+ "mode": "fixed"
|
|
|
|
+ },
|
|
|
|
+ "mappings": [],
|
|
|
|
+ "thresholds": {
|
|
|
|
+ "mode": "absolute",
|
|
|
|
+ "steps": [
|
|
|
|
+ {
|
|
|
|
+ "color": "green",
|
|
|
|
+ "value": null
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ "color": "red",
|
|
|
|
+ "value": 80
|
|
|
|
+ }
|
|
|
|
+ ]
|
|
|
|
+ },
|
|
|
|
+ "unit": "locale"
|
|
|
|
+ },
|
|
|
|
+ "overrides": []
|
|
|
|
+ },
|
|
|
|
+ "gridPos": {
|
|
|
|
+ "h": 6,
|
|
|
|
+ "w": 4,
|
|
|
|
+ "x": 4,
|
|
|
|
+ "y": 0
|
|
|
|
+ },
|
|
|
|
+ "id": 10,
|
|
|
|
+ "interval": "10m",
|
|
|
|
+ "options": {
|
|
|
|
+ "colorMode": "value",
|
|
|
|
+ "graphMode": "area",
|
|
|
|
+ "justifyMode": "auto",
|
|
|
|
+ "orientation": "auto",
|
|
|
|
+ "reduceOptions": {
|
|
|
|
+ "calcs": [
|
|
|
|
+ "sum"
|
|
|
|
+ ],
|
|
|
|
+ "fields": "",
|
|
|
|
+ "values": false
|
|
|
|
+ },
|
|
|
|
+ "textMode": "auto"
|
|
|
|
+ },
|
|
|
|
+ "pluginVersion": "9.1.4",
|
|
|
|
+ "targets": [
|
|
|
|
+ {
|
|
|
|
+ "datasource": {
|
|
|
|
+ "type": "influxdb",
|
|
|
|
+ "uid": "${DS_INFLUXDB}"
|
|
|
|
+ },
|
|
|
|
+ "query": "from(bucket: \"pihole\")\r\n |> range(start: v.timeRangeStart, stop: v.timeRangeStop)\r\n |> filter(fn: (r) => r[\"_measurement\"] == \"domains\")\r\n |> filter(fn: (r) => r[\"_field\"] == \"cached\")\r\n |> aggregateWindow(every: v.windowPeriod, fn: sum, createEmpty: false)\r\n |> yield(name: \"sum\")",
|
|
|
|
+ "refId": "A"
|
|
|
|
+ }
|
|
|
|
+ ],
|
|
|
|
+ "title": "Queries Cached",
|
|
|
|
+ "transparent": true,
|
|
|
|
+ "type": "stat"
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ "datasource": {
|
|
|
|
+ "type": "influxdb",
|
|
|
|
+ "uid": "${DS_INFLUXDB}"
|
|
|
|
+ },
|
|
|
|
+ "fieldConfig": {
|
|
|
|
+ "defaults": {
|
|
|
|
+ "color": {
|
|
|
|
+ "fixedColor": "blue",
|
|
|
|
+ "mode": "fixed"
|
|
|
|
+ },
|
|
|
|
+ "mappings": [],
|
|
|
|
+ "thresholds": {
|
|
|
|
+ "mode": "absolute",
|
|
|
|
+ "steps": [
|
|
|
|
+ {
|
|
|
|
+ "color": "green",
|
|
|
|
+ "value": null
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ "color": "red",
|
|
|
|
+ "value": 80
|
|
|
|
+ }
|
|
|
|
+ ]
|
|
|
|
+ },
|
|
|
|
+ "unit": "locale"
|
|
|
|
+ },
|
|
|
|
+ "overrides": []
|
|
|
|
+ },
|
|
|
|
+ "gridPos": {
|
|
|
|
+ "h": 6,
|
|
|
|
+ "w": 4,
|
|
|
|
+ "x": 8,
|
|
|
|
+ "y": 0
|
|
|
|
+ },
|
|
|
|
+ "id": 3,
|
|
|
|
+ "interval": "10m",
|
|
|
|
+ "options": {
|
|
|
|
+ "colorMode": "value",
|
|
|
|
+ "graphMode": "area",
|
|
|
|
+ "justifyMode": "auto",
|
|
|
|
+ "orientation": "auto",
|
|
|
|
+ "reduceOptions": {
|
|
|
|
+ "calcs": [
|
|
|
|
+ "sum"
|
|
|
|
+ ],
|
|
|
|
+ "fields": "",
|
|
|
|
+ "values": false
|
|
|
|
+ },
|
|
|
|
+ "textMode": "auto"
|
|
|
|
+ },
|
|
|
|
+ "pluginVersion": "9.1.4",
|
|
|
|
+ "targets": [
|
|
|
|
+ {
|
|
|
|
+ "datasource": {
|
|
|
|
+ "type": "influxdb",
|
|
|
|
+ "uid": "${DS_INFLUXDB}"
|
|
|
|
+ },
|
|
|
|
+ "query": "from(bucket: \"pihole\")\r\n |> range(start: v.timeRangeStart, stop: v.timeRangeStop)\r\n |> filter(fn: (r) => r[\"_measurement\"] == \"queries\")\r\n |> filter(fn: (r) => r[\"_field\"] == \"blocked\")\r\n |> aggregateWindow(every: v.windowPeriod, fn: sum, createEmpty: false)\r\n |> yield(name: \"sum\")",
|
|
|
|
+ "refId": "A"
|
|
|
|
+ }
|
|
|
|
+ ],
|
|
|
|
+ "title": "Queries Blocked",
|
|
|
|
+ "transparent": true,
|
|
|
|
+ "type": "stat"
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ "datasource": {
|
|
|
|
+ "type": "influxdb",
|
|
|
|
+ "uid": "${DS_INFLUXDB}"
|
|
|
|
+ },
|
|
|
|
+ "fieldConfig": {
|
|
|
|
+ "defaults": {
|
|
|
|
+ "color": {
|
|
|
|
+ "fixedColor": "yellow",
|
|
|
|
+ "mode": "fixed"
|
|
|
|
+ },
|
|
|
|
+ "decimals": 1,
|
|
|
|
+ "mappings": [],
|
|
|
|
+ "thresholds": {
|
|
|
|
+ "mode": "absolute",
|
|
|
|
+ "steps": [
|
|
|
|
+ {
|
|
|
|
+ "color": "green",
|
|
|
|
+ "value": null
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ "color": "red",
|
|
|
|
+ "value": 80
|
|
|
|
+ }
|
|
|
|
+ ]
|
|
|
|
+ },
|
|
|
|
+ "unit": "percent"
|
|
|
|
+ },
|
|
|
|
+ "overrides": []
|
|
|
|
+ },
|
|
|
|
+ "gridPos": {
|
|
|
|
+ "h": 6,
|
|
|
|
+ "w": 4,
|
|
|
|
+ "x": 12,
|
|
|
|
+ "y": 0
|
|
|
|
+ },
|
|
|
|
+ "id": 4,
|
|
|
|
+ "interval": "10m",
|
|
|
|
+ "options": {
|
|
|
|
+ "colorMode": "value",
|
|
|
|
+ "graphMode": "area",
|
|
|
|
+ "justifyMode": "auto",
|
|
|
|
+ "orientation": "auto",
|
|
|
|
+ "reduceOptions": {
|
|
|
|
+ "calcs": [
|
|
|
|
+ "mean"
|
|
|
|
+ ],
|
|
|
|
+ "fields": "",
|
|
|
|
+ "values": false
|
|
|
|
+ },
|
|
|
|
+ "textMode": "auto"
|
|
|
|
+ },
|
|
|
|
+ "pluginVersion": "9.1.4",
|
|
|
|
+ "targets": [
|
|
|
|
+ {
|
|
|
|
+ "datasource": {
|
|
|
|
+ "type": "influxdb",
|
|
|
|
+ "uid": "${DS_INFLUXDB}"
|
|
|
|
+ },
|
|
|
|
+ "query": "from(bucket: \"pihole\")\r\n |> range(start: v.timeRangeStart, stop: v.timeRangeStop)\r\n |> filter(fn: (r) => r[\"_measurement\"] == \"queries\")\r\n |> filter(fn: (r) => r[\"_field\"] == \"ads_percentage\")\r\n |> aggregateWindow(every: v.windowPeriod, fn: mean, createEmpty: false)\r\n |> yield(name: \"mean\")",
|
|
|
|
+ "refId": "A"
|
|
|
|
+ }
|
|
|
|
+ ],
|
|
|
|
+ "title": "Percentage Blocked",
|
|
|
|
+ "transparent": true,
|
|
|
|
+ "type": "stat"
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ "datasource": {
|
|
|
|
+ "type": "influxdb",
|
|
|
|
+ "uid": "${DS_INFLUXDB}"
|
|
|
|
+ },
|
|
|
|
+ "description": "",
|
|
|
|
+ "fieldConfig": {
|
|
|
|
+ "defaults": {
|
|
|
|
+ "color": {
|
|
|
|
+ "fixedColor": "red",
|
|
|
|
+ "mode": "fixed"
|
|
|
|
+ },
|
|
|
|
+ "decimals": 0,
|
|
|
|
+ "mappings": [],
|
|
|
|
+ "thresholds": {
|
|
|
|
+ "mode": "absolute",
|
|
|
|
+ "steps": [
|
|
|
|
+ {
|
|
|
|
+ "color": "green",
|
|
|
|
+ "value": null
|
|
|
|
+ }
|
|
|
|
+ ]
|
|
|
|
+ },
|
|
|
|
+ "unit": "locale"
|
|
|
|
+ },
|
|
|
|
+ "overrides": []
|
|
|
|
+ },
|
|
|
|
+ "gridPos": {
|
|
|
|
+ "h": 6,
|
|
|
|
+ "w": 4,
|
|
|
|
+ "x": 16,
|
|
|
|
+ "y": 0
|
|
|
|
+ },
|
|
|
|
+ "id": 5,
|
|
|
|
+ "interval": "10m",
|
|
|
|
+ "options": {
|
|
|
|
+ "colorMode": "value",
|
|
|
|
+ "graphMode": "area",
|
|
|
|
+ "justifyMode": "auto",
|
|
|
|
+ "orientation": "auto",
|
|
|
|
+ "reduceOptions": {
|
|
|
|
+ "calcs": [
|
|
|
|
+ "lastNotNull"
|
|
|
|
+ ],
|
|
|
|
+ "fields": "",
|
|
|
|
+ "values": false
|
|
|
|
+ },
|
|
|
|
+ "textMode": "auto"
|
|
|
|
+ },
|
|
|
|
+ "pluginVersion": "9.1.4",
|
|
|
|
+ "targets": [
|
|
|
|
+ {
|
|
|
|
+ "datasource": {
|
|
|
|
+ "type": "influxdb",
|
|
|
|
+ "uid": "${DS_INFLUXDB}"
|
|
|
|
+ },
|
|
|
|
+ "query": "from(bucket: \"pihole\")\r\n |> range(start: v.timeRangeStart, stop: v.timeRangeStop)\r\n |> filter(fn: (r) => r[\"_measurement\"] == \"domains\")\r\n |> filter(fn: (r) => r[\"_field\"] == \"domain_count\")\r\n |> aggregateWindow(every: v.windowPeriod, fn: last, createEmpty: false)\r\n |> yield(name: \"last\")",
|
|
|
|
+ "refId": "A"
|
|
|
|
+ }
|
|
|
|
+ ],
|
|
|
|
+ "title": "Domains on Adlists",
|
|
|
|
+ "transparent": true,
|
|
|
|
+ "type": "stat"
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ "datasource": {
|
|
|
|
+ "type": "influxdb",
|
|
|
|
+ "uid": "${DS_INFLUXDB}"
|
|
|
|
+ },
|
|
|
|
+ "fieldConfig": {
|
|
|
|
+ "defaults": {
|
|
|
|
+ "color": {
|
|
|
|
+ "mode": "thresholds"
|
|
|
|
+ },
|
|
|
|
+ "mappings": [],
|
|
|
|
+ "thresholds": {
|
|
|
|
+ "mode": "absolute",
|
|
|
|
+ "steps": [
|
|
|
|
+ {
|
|
|
|
+ "color": "green",
|
|
|
|
+ "value": null
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ "color": "red",
|
|
|
|
+ "value": 80
|
|
|
|
+ }
|
|
|
|
+ ]
|
|
|
|
+ },
|
|
|
|
+ "unit": "locale"
|
|
|
|
+ },
|
|
|
|
+ "overrides": []
|
|
|
|
+ },
|
|
|
|
+ "gridPos": {
|
|
|
|
+ "h": 6,
|
|
|
|
+ "w": 4,
|
|
|
|
+ "x": 20,
|
|
|
|
+ "y": 0
|
|
|
|
+ },
|
|
|
|
+ "id": 11,
|
|
|
|
+ "interval": "10m",
|
|
|
|
+ "options": {
|
|
|
|
+ "colorMode": "value",
|
|
|
|
+ "graphMode": "area",
|
|
|
|
+ "justifyMode": "auto",
|
|
|
|
+ "orientation": "auto",
|
|
|
|
+ "reduceOptions": {
|
|
|
|
+ "calcs": [
|
|
|
|
+ "max"
|
|
|
|
+ ],
|
|
|
|
+ "fields": "",
|
|
|
|
+ "values": false
|
|
|
|
+ },
|
|
|
|
+ "textMode": "auto"
|
|
|
|
+ },
|
|
|
|
+ "pluginVersion": "9.1.4",
|
|
|
|
+ "targets": [
|
|
|
|
+ {
|
|
|
|
+ "datasource": {
|
|
|
|
+ "type": "influxdb",
|
|
|
|
+ "uid": "${DS_INFLUXDB}"
|
|
|
|
+ },
|
|
|
|
+ "query": "from(bucket: \"pihole\")\r\n |> range(start: v.timeRangeStart, stop: v.timeRangeStop)\r\n |> filter(fn: (r) => r[\"_measurement\"] == \"clients\")\r\n |> filter(fn: (r) => r[\"_field\"] == \"queries\")\r\n |> aggregateWindow(every: v.windowPeriod, fn: max, createEmpty: false)\r\n |> group(columns: [\"client\"])\r\n |> distinct(column: \"client\")\r\n |> keep(columns: [\"_value\", \"_time\"])\r\n |> count()\r\n |> yield(name: \"max\")",
|
|
|
|
+ "refId": "A"
|
|
|
|
+ }
|
|
|
|
+ ],
|
|
|
|
+ "title": "Total Clients",
|
|
|
|
+ "transformations": [],
|
|
|
|
+ "transparent": true,
|
|
|
|
+ "type": "stat"
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ "datasource": {
|
|
|
|
+ "type": "influxdb",
|
|
|
|
+ "uid": "${DS_INFLUXDB}"
|
|
|
|
+ },
|
|
|
|
+ "description": "",
|
|
|
|
+ "fieldConfig": {
|
|
|
|
+ "defaults": {
|
|
|
|
+ "color": {
|
|
|
|
+ "mode": "palette-classic"
|
|
|
|
+ },
|
|
|
|
+ "custom": {
|
|
|
|
+ "axisCenteredZero": false,
|
|
|
|
+ "axisColorMode": "text",
|
|
|
|
+ "axisLabel": "",
|
|
|
|
+ "axisPlacement": "auto",
|
|
|
|
+ "barAlignment": 0,
|
|
|
|
+ "drawStyle": "line",
|
|
|
|
+ "fillOpacity": 5,
|
|
|
|
+ "gradientMode": "none",
|
|
|
|
+ "hideFrom": {
|
|
|
|
+ "legend": false,
|
|
|
|
+ "tooltip": false,
|
|
|
|
+ "viz": false
|
|
|
|
+ },
|
|
|
|
+ "lineInterpolation": "smooth",
|
|
|
|
+ "lineWidth": 1,
|
|
|
|
+ "pointSize": 5,
|
|
|
|
+ "scaleDistribution": {
|
|
|
|
+ "type": "linear"
|
|
|
|
+ },
|
|
|
|
+ "showPoints": "auto",
|
|
|
|
+ "spanNulls": false,
|
|
|
|
+ "stacking": {
|
|
|
|
+ "group": "A",
|
|
|
|
+ "mode": "none"
|
|
|
|
+ },
|
|
|
|
+ "thresholdsStyle": {
|
|
|
|
+ "mode": "off"
|
|
|
|
+ }
|
|
|
|
+ },
|
|
|
|
+ "decimals": 0,
|
|
|
|
+ "mappings": [],
|
|
|
|
+ "thresholds": {
|
|
|
|
+ "mode": "absolute",
|
|
|
|
+ "steps": [
|
|
|
|
+ {
|
|
|
|
+ "color": "green",
|
|
|
|
+ "value": null
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ "color": "red",
|
|
|
|
+ "value": 80
|
|
|
|
+ }
|
|
|
|
+ ]
|
|
|
|
+ },
|
|
|
|
+ "unit": "short"
|
|
|
|
+ },
|
|
|
|
+ "overrides": []
|
|
|
|
+ },
|
|
|
|
+ "gridPos": {
|
|
|
|
+ "h": 8,
|
|
|
|
+ "w": 12,
|
|
|
|
+ "x": 0,
|
|
|
|
+ "y": 6
|
|
|
|
+ },
|
|
|
|
+ "id": 12,
|
|
|
|
+ "options": {
|
|
|
|
+ "legend": {
|
|
|
|
+ "calcs": [],
|
|
|
|
+ "displayMode": "list",
|
|
|
|
+ "placement": "bottom",
|
|
|
|
+ "showLegend": true
|
|
|
|
+ },
|
|
|
|
+ "tooltip": {
|
|
|
|
+ "mode": "multi",
|
|
|
|
+ "sort": "none"
|
|
|
|
+ }
|
|
|
|
+ },
|
|
|
|
+ "targets": [
|
|
|
|
+ {
|
|
|
|
+ "datasource": {
|
|
|
|
+ "type": "influxdb",
|
|
|
|
+ "uid": "${DS_INFLUXDB}"
|
|
|
|
+ },
|
|
|
|
+ "query": "from(bucket: \"pihole\")\r\n |> range(start: v.timeRangeStart, stop: v.timeRangeStop)\r\n |> filter(fn: (r) => r[\"_measurement\"] == \"clients\")\r\n |> filter(fn: (r) => r[\"_field\"] == \"queries\")\r\n |> aggregateWindow(every: v.windowPeriod, fn: mean, createEmpty: false)\r\n |> yield(name: \"mean\")",
|
|
|
|
+ "refId": "A"
|
|
|
|
+ }
|
|
|
|
+ ],
|
|
|
|
+ "title": "Queries per Client",
|
|
|
|
+ "transformations": [
|
|
|
|
+ {
|
|
|
|
+ "id": "renameByRegex",
|
|
|
|
+ "options": {
|
|
|
|
+ "regex": ".+client=\"(.+?)\".+",
|
|
|
|
+ "renamePattern": "$1"
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ ],
|
|
|
|
+ "transparent": true,
|
|
|
|
+ "type": "timeseries"
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ "datasource": {
|
|
|
|
+ "type": "influxdb",
|
|
|
|
+ "uid": "${DS_INFLUXDB}"
|
|
|
|
+ },
|
|
|
|
+ "description": "",
|
|
|
|
+ "fieldConfig": {
|
|
|
|
+ "defaults": {
|
|
|
|
+ "color": {
|
|
|
|
+ "mode": "palette-classic"
|
|
|
|
+ },
|
|
|
|
+ "custom": {
|
|
|
|
+ "axisCenteredZero": false,
|
|
|
|
+ "axisColorMode": "text",
|
|
|
|
+ "axisLabel": "",
|
|
|
|
+ "axisPlacement": "auto",
|
|
|
|
+ "barAlignment": 0,
|
|
|
|
+ "drawStyle": "line",
|
|
|
|
+ "fillOpacity": 5,
|
|
|
|
+ "gradientMode": "none",
|
|
|
|
+ "hideFrom": {
|
|
|
|
+ "legend": false,
|
|
|
|
+ "tooltip": false,
|
|
|
|
+ "viz": false
|
|
|
|
+ },
|
|
|
|
+ "lineInterpolation": "smooth",
|
|
|
|
+ "lineWidth": 1,
|
|
|
|
+ "pointSize": 5,
|
|
|
|
+ "scaleDistribution": {
|
|
|
|
+ "type": "linear"
|
|
|
|
+ },
|
|
|
|
+ "showPoints": "auto",
|
|
|
|
+ "spanNulls": false,
|
|
|
|
+ "stacking": {
|
|
|
|
+ "group": "A",
|
|
|
|
+ "mode": "none"
|
|
|
|
+ },
|
|
|
|
+ "thresholdsStyle": {
|
|
|
|
+ "mode": "off"
|
|
|
|
+ }
|
|
|
|
+ },
|
|
|
|
+ "decimals": 0,
|
|
|
|
+ "mappings": [],
|
|
|
|
+ "thresholds": {
|
|
|
|
+ "mode": "absolute",
|
|
|
|
+ "steps": [
|
|
|
|
+ {
|
|
|
|
+ "color": "green",
|
|
|
|
+ "value": null
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ "color": "red",
|
|
|
|
+ "value": 80
|
|
|
|
+ }
|
|
|
|
+ ]
|
|
|
|
+ },
|
|
|
|
+ "unit": "short"
|
|
|
|
+ },
|
|
|
|
+ "overrides": []
|
|
|
|
+ },
|
|
|
|
+ "gridPos": {
|
|
|
|
+ "h": 8,
|
|
|
|
+ "w": 12,
|
|
|
|
+ "x": 12,
|
|
|
|
+ "y": 6
|
|
|
|
+ },
|
|
|
|
+ "id": 13,
|
|
|
|
+ "options": {
|
|
|
|
+ "legend": {
|
|
|
|
+ "calcs": [],
|
|
|
|
+ "displayMode": "list",
|
|
|
|
+ "placement": "bottom",
|
|
|
|
+ "showLegend": true
|
|
|
|
+ },
|
|
|
|
+ "tooltip": {
|
|
|
|
+ "mode": "multi",
|
|
|
|
+ "sort": "none"
|
|
|
|
+ }
|
|
|
|
+ },
|
|
|
|
+ "targets": [
|
|
|
|
+ {
|
|
|
|
+ "datasource": {
|
|
|
|
+ "type": "influxdb",
|
|
|
|
+ "uid": "${DS_INFLUXDB}"
|
|
|
|
+ },
|
|
|
|
+ "query": "from(bucket: \"pihole\")\r\n |> range(start: v.timeRangeStart, stop: v.timeRangeStop)\r\n |> filter(fn: (r) => r[\"_measurement\"] == \"clients\")\r\n |> filter(fn: (r) => r[\"_field\"] == \"blocked\")\r\n |> aggregateWindow(every: v.windowPeriod, fn: mean, createEmpty: false)\r\n |> yield(name: \"mean\")",
|
|
|
|
+ "refId": "A"
|
|
|
|
+ }
|
|
|
|
+ ],
|
|
|
|
+ "title": "Blocked queries per Client",
|
|
|
|
+ "transformations": [
|
|
|
|
+ {
|
|
|
|
+ "id": "renameByRegex",
|
|
|
|
+ "options": {
|
|
|
|
+ "regex": ".+client=\"(.+?)\".+",
|
|
|
|
+ "renamePattern": "$1"
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ ],
|
|
|
|
+ "transparent": true,
|
|
|
|
+ "type": "timeseries"
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ "datasource": {
|
|
|
|
+ "type": "influxdb",
|
|
|
|
+ "uid": "${DS_INFLUXDB}"
|
|
|
|
+ },
|
|
|
|
+ "fieldConfig": {
|
|
|
|
+ "defaults": {
|
|
|
|
+ "color": {
|
|
|
|
+ "mode": "palette-classic"
|
|
|
|
+ },
|
|
|
|
+ "custom": {
|
|
|
|
+ "axisCenteredZero": false,
|
|
|
|
+ "axisColorMode": "text",
|
|
|
|
+ "axisLabel": "",
|
|
|
|
+ "axisPlacement": "auto",
|
|
|
|
+ "barAlignment": 0,
|
|
|
|
+ "drawStyle": "line",
|
|
|
|
+ "fillOpacity": 63,
|
|
|
|
+ "gradientMode": "none",
|
|
|
|
+ "hideFrom": {
|
|
|
|
+ "legend": false,
|
|
|
|
+ "tooltip": false,
|
|
|
|
+ "viz": false
|
|
|
|
+ },
|
|
|
|
+ "lineInterpolation": "linear",
|
|
|
|
+ "lineWidth": 1,
|
|
|
|
+ "pointSize": 5,
|
|
|
|
+ "scaleDistribution": {
|
|
|
|
+ "type": "linear"
|
|
|
|
+ },
|
|
|
|
+ "showPoints": "auto",
|
|
|
|
+ "spanNulls": false,
|
|
|
|
+ "stacking": {
|
|
|
|
+ "group": "A",
|
|
|
|
+ "mode": "percent"
|
|
|
|
+ },
|
|
|
|
+ "thresholdsStyle": {
|
|
|
|
+ "mode": "off"
|
|
|
|
+ }
|
|
|
|
+ },
|
|
|
|
+ "decimals": 0,
|
|
|
|
+ "mappings": [],
|
|
|
|
+ "thresholds": {
|
|
|
|
+ "mode": "absolute",
|
|
|
|
+ "steps": [
|
|
|
|
+ {
|
|
|
|
+ "color": "green",
|
|
|
|
+ "value": null
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ "color": "red",
|
|
|
|
+ "value": 80
|
|
|
|
+ }
|
|
|
|
+ ]
|
|
|
|
+ },
|
|
|
|
+ "unit": "short"
|
|
|
|
+ },
|
|
|
|
+ "overrides": []
|
|
|
|
+ },
|
|
|
|
+ "gridPos": {
|
|
|
|
+ "h": 7,
|
|
|
|
+ "w": 12,
|
|
|
|
+ "x": 0,
|
|
|
|
+ "y": 14
|
|
|
|
+ },
|
|
|
|
+ "id": 7,
|
|
|
|
+ "options": {
|
|
|
|
+ "legend": {
|
|
|
|
+ "calcs": [],
|
|
|
|
+ "displayMode": "list",
|
|
|
|
+ "placement": "bottom",
|
|
|
|
+ "showLegend": true
|
|
|
|
+ },
|
|
|
|
+ "tooltip": {
|
|
|
|
+ "mode": "multi",
|
|
|
|
+ "sort": "none"
|
|
|
|
+ }
|
|
|
|
+ },
|
|
|
|
+ "targets": [
|
|
|
|
+ {
|
|
|
|
+ "datasource": {
|
|
|
|
+ "type": "influxdb",
|
|
|
|
+ "uid": "${DS_INFLUXDB}"
|
|
|
|
+ },
|
|
|
|
+ "query": "from(bucket: \"pihole\")\r\n |> range(start: v.timeRangeStart, stop: v.timeRangeStop)\r\n |> filter(fn: (r) => r[\"_measurement\"] == \"query_types\")\r\n |> aggregateWindow(every: v.windowPeriod, fn: last, createEmpty: false)\r\n |> yield(name: \"last\")",
|
|
|
|
+ "refId": "A"
|
|
|
|
+ }
|
|
|
|
+ ],
|
|
|
|
+ "title": "Query Types",
|
|
|
|
+ "transformations": [
|
|
|
|
+ {
|
|
|
|
+ "id": "renameByRegex",
|
|
|
|
+ "options": {
|
|
|
|
+ "regex": ".+query_type=\"(.*)\".+",
|
|
|
|
+ "renamePattern": "$1"
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ ],
|
|
|
|
+ "transparent": true,
|
|
|
|
+ "type": "timeseries"
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ "datasource": {
|
|
|
|
+ "type": "influxdb",
|
|
|
|
+ "uid": "${DS_INFLUXDB}"
|
|
|
|
+ },
|
|
|
|
+ "fieldConfig": {
|
|
|
|
+ "defaults": {
|
|
|
|
+ "color": {
|
|
|
|
+ "mode": "palette-classic"
|
|
|
|
+ },
|
|
|
|
+ "custom": {
|
|
|
|
+ "axisCenteredZero": false,
|
|
|
|
+ "axisColorMode": "text",
|
|
|
|
+ "axisLabel": "",
|
|
|
|
+ "axisPlacement": "auto",
|
|
|
|
+ "barAlignment": 0,
|
|
|
|
+ "drawStyle": "line",
|
|
|
|
+ "fillOpacity": 6,
|
|
|
|
+ "gradientMode": "none",
|
|
|
|
+ "hideFrom": {
|
|
|
|
+ "legend": false,
|
|
|
|
+ "tooltip": false,
|
|
|
|
+ "viz": false
|
|
|
|
+ },
|
|
|
|
+ "lineInterpolation": "linear",
|
|
|
|
+ "lineWidth": 1,
|
|
|
|
+ "pointSize": 5,
|
|
|
|
+ "scaleDistribution": {
|
|
|
|
+ "type": "linear"
|
|
|
|
+ },
|
|
|
|
+ "showPoints": "auto",
|
|
|
|
+ "spanNulls": false,
|
|
|
|
+ "stacking": {
|
|
|
|
+ "group": "A",
|
|
|
|
+ "mode": "normal"
|
|
|
|
+ },
|
|
|
|
+ "thresholdsStyle": {
|
|
|
|
+ "mode": "off"
|
|
|
|
+ }
|
|
|
|
+ },
|
|
|
|
+ "decimals": 0,
|
|
|
|
+ "mappings": [],
|
|
|
|
+ "thresholds": {
|
|
|
|
+ "mode": "absolute",
|
|
|
|
+ "steps": [
|
|
|
|
+ {
|
|
|
|
+ "color": "green",
|
|
|
|
+ "value": null
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ "color": "red",
|
|
|
|
+ "value": 80
|
|
|
|
+ }
|
|
|
|
+ ]
|
|
|
|
+ },
|
|
|
|
+ "unit": "short"
|
|
|
|
+ },
|
|
|
|
+ "overrides": []
|
|
|
|
+ },
|
|
|
|
+ "gridPos": {
|
|
|
|
+ "h": 7,
|
|
|
|
+ "w": 12,
|
|
|
|
+ "x": 12,
|
|
|
|
+ "y": 14
|
|
|
|
+ },
|
|
|
|
+ "id": 9,
|
|
|
|
+ "options": {
|
|
|
|
+ "legend": {
|
|
|
|
+ "calcs": [],
|
|
|
|
+ "displayMode": "list",
|
|
|
|
+ "placement": "bottom",
|
|
|
|
+ "showLegend": true
|
|
|
|
+ },
|
|
|
|
+ "tooltip": {
|
|
|
|
+ "mode": "multi",
|
|
|
|
+ "sort": "none"
|
|
|
|
+ }
|
|
|
|
+ },
|
|
|
|
+ "targets": [
|
|
|
|
+ {
|
|
|
|
+ "datasource": {
|
|
|
|
+ "type": "influxdb",
|
|
|
|
+ "uid": "${DS_INFLUXDB}"
|
|
|
|
+ },
|
|
|
|
+ "query": "from(bucket: \"pihole\")\r\n |> range(start: v.timeRangeStart, stop: v.timeRangeStop)\r\n |> filter(fn: (r) => r[\"_measurement\"] == \"forward_destinations\")\r\n |> filter(fn: (r) => r[\"destination\"] != \"\")\r\n |> aggregateWindow(every: v.windowPeriod, fn: mean, createEmpty: false)\r\n |> yield(name: \"mean\")",
|
|
|
|
+ "refId": "A"
|
|
|
|
+ }
|
|
|
|
+ ],
|
|
|
|
+ "title": "Upstream Queries",
|
|
|
|
+ "transformations": [
|
|
|
|
+ {
|
|
|
|
+ "id": "renameByRegex",
|
|
|
|
+ "options": {
|
|
|
|
+ "regex": ".+destination=\"(.+?)#?\\d*\".+",
|
|
|
|
+ "renamePattern": "$1"
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ ],
|
|
|
|
+ "transparent": true,
|
|
|
|
+ "type": "timeseries"
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ "datasource": {
|
|
|
|
+ "type": "influxdb",
|
|
|
|
+ "uid": "${DS_INFLUXDB}"
|
|
|
|
+ },
|
|
|
|
+ "description": "",
|
|
|
|
+ "fieldConfig": {
|
|
|
|
+ "defaults": {
|
|
|
|
+ "color": {
|
|
|
|
+ "fixedColor": "red",
|
|
|
|
+ "mode": "fixed"
|
|
|
|
+ },
|
|
|
|
+ "decimals": 0,
|
|
|
|
+ "mappings": [],
|
|
|
|
+ "thresholds": {
|
|
|
|
+ "mode": "absolute",
|
|
|
|
+ "steps": [
|
|
|
|
+ {
|
|
|
|
+ "color": "green",
|
|
|
|
+ "value": null
|
|
|
|
+ }
|
|
|
|
+ ]
|
|
|
|
+ },
|
|
|
|
+ "unit": "dateTimeAsLocalNoDateIfToday"
|
|
|
|
+ },
|
|
|
|
+ "overrides": []
|
|
|
|
+ },
|
|
|
|
+ "gridPos": {
|
|
|
|
+ "h": 6,
|
|
|
|
+ "w": 8,
|
|
|
|
+ "x": 0,
|
|
|
|
+ "y": 21
|
|
|
|
+ },
|
|
|
|
+ "id": 8,
|
|
|
|
+ "interval": "10m",
|
|
|
|
+ "options": {
|
|
|
|
+ "colorMode": "value",
|
|
|
|
+ "graphMode": "none",
|
|
|
|
+ "justifyMode": "auto",
|
|
|
|
+ "orientation": "auto",
|
|
|
|
+ "reduceOptions": {
|
|
|
|
+ "calcs": [
|
|
|
|
+ "lastNotNull"
|
|
|
|
+ ],
|
|
|
|
+ "fields": "",
|
|
|
|
+ "values": false
|
|
|
|
+ },
|
|
|
|
+ "textMode": "auto"
|
|
|
|
+ },
|
|
|
|
+ "pluginVersion": "9.1.4",
|
|
|
|
+ "targets": [
|
|
|
|
+ {
|
|
|
|
+ "datasource": {
|
|
|
|
+ "type": "influxdb",
|
|
|
|
+ "uid": "${DS_INFLUXDB}"
|
|
|
|
+ },
|
|
|
|
+ "query": "from(bucket: \"pihole\")\r\n |> range(start: v.timeRangeStart, stop: v.timeRangeStop)\r\n |> filter(fn: (r) => r[\"_measurement\"] == \"other\")\r\n |> filter(fn: (r) => r[\"_field\"] == \"gravity_last_update\")\r\n |> aggregateWindow(every: v.windowPeriod, fn: last, createEmpty: false)\r\n |> map(fn: (r) => ({r with _value: r._value * 1000}))\r\n |> yield(name: \"last\")",
|
|
|
|
+ "refId": "A"
|
|
|
|
+ }
|
|
|
|
+ ],
|
|
|
|
+ "title": "Adlists last Updated",
|
|
|
|
+ "transparent": true,
|
|
|
|
+ "type": "stat"
|
|
|
|
+ }
|
|
|
|
+ ],
|
|
|
|
+ "schemaVersion": 37,
|
|
|
|
+ "style": "dark",
|
|
|
|
+ "tags": [],
|
|
|
|
+ "templating": {
|
|
|
|
+ "list": []
|
|
|
|
+ },
|
|
|
|
+ "time": {
|
|
|
|
+ "from": "now-24h",
|
|
|
|
+ "to": "now"
|
|
|
|
+ },
|
|
|
|
+ "timepicker": {
|
|
|
|
+ "refresh_intervals": [
|
|
|
|
+ "1m",
|
|
|
|
+ "5m",
|
|
|
|
+ "15m",
|
|
|
|
+ "30m",
|
|
|
|
+ "1h",
|
|
|
|
+ "2h",
|
|
|
|
+ "1d"
|
|
|
|
+ ]
|
|
|
|
+ },
|
|
|
|
+ "timezone": "",
|
|
|
|
+ "title": "Pi-hole",
|
|
|
|
+ "uid": "4Ku5WznVk",
|
|
|
|
+ "version": 10,
|
|
|
|
+ "weekStart": ""
|
|
|
|
+}
|