diff --git a/.github/utils/extract_chart_n_image_list.sh b/.github/utils/extract_chart_n_image_list.sh deleted file mode 100755 index 88db9104326..00000000000 --- a/.github/utils/extract_chart_n_image_list.sh +++ /dev/null @@ -1,185 +0,0 @@ -#!/bin/bash - -KB_VERSION=${1:-0.7.0-alpha.0} -KB_HELM_REPO_INDEX_URL_BASE=https://apecloud.github.io/helm-charts -KB_HELM_REPO_INDEX_URL=${KB_HELM_REPO_INDEX_URL_BASE}/index.yaml - -# set -o errexit -# set -o nounset -# set -o pipefail - -print_error() { - echo "$1" >&2 -} - -# List of required commands -required_cmds=("curl" "helm" "jq" "yq") - -# Loop through the list of commands and check if they exist -for cmd in "${required_cmds[@]}"; do - if ! command -v "$cmd" &> /dev/null; then - print_error "Error: '$cmd' command not found" - exit 1 - fi -done - -# Regular expression to match http or https -regex="^(http|https)://.*" - -# Get helm chart index -echo "Processing helm chart index: ${KB_HELM_REPO_INDEX_URL}" -kb_index_json=`curl ${KB_HELM_REPO_INDEX_URL} | yq eval -ojson` -entries=`echo ${kb_index_json} | jq -r '.entries | keys | .[]'` - -chart_url_array=() -image_array=() -for entry in ${entries} -do - version=${KB_VERSION} - url="" - helm_custom_args="" - images="" - - # specialized processor - case ${entry} in - # ignored entries - "agamotto" | \ - "apecloud-mysql-cluster" | \ - "postgresql-cluster" | \ - "tdengine-cluster" | \ - "chaos-mesh" | \ - "chatgpt-retrieval-plugin" | \ - "clickhouse" | \ - "delphic" | \ - "etcd" | \ - "etcd-cluster" | \ - "kafka" | \ - "opensearch" | \ - "opensearch-cluster" | \ - "redis-demo" | \ - "prometheus-kubeblocks" | \ - "bytebase" ) - continue - ;; - "aws-load-balancer-controller") - helm_custom_args="--set clusterName=clusterName" - ;; - "dt-platform" | "kubeblocks-csi-driver") - # following chart is missing from chart repo index - version="0.1.0" - # url=https://jihulab.com/api/v4/projects/85949/packages/helm/stable/charts/${entry}-${version}.tgz - ;; - "prometheus") - version="15.16.1" - ;; - esac - - # compose helm chart URL - if [ -z "${url}" ]; then - select_entry=`echo ${kb_index_json} | jq -r ".entries[\"${entry}\"][] | select(.version == \"${version}\")"` - url=`echo ${select_entry} | jq -r '.urls[0]'` - if [ -z "$url" ]; then - # choose latest version instead - select_entry=`echo ${kb_index_json} | jq -r ".entries[\"${entry}\"][0]"` - url=`echo ${select_entry} | jq -r '.urls[0]'` - version=`echo ${select_entry} | jq -r '.version'` - fi - if ! [[ $url =~ $regex ]]; then - url=${KB_HELM_REPO_INDEX_URL_BASE}/${url} - fi - fi - - # extract images from helm templates - if [ -z "${images}" ]; then - images=`helm template ${entry} ${url} ${helm_custom_args} | grep -e "image:" -e "chartsImage"| awk '{print $2}'` - fi - - chart_url_array+=(${url}) - print_error "processed entry=${entry}; version=${version}; url=${url}" - for image in ${images} - do - image="${image//\"}" - image_array+=(${image}) - done -done - -print_error "" - -# Convert array to set -image_set=($(printf "%s\n" "${image_array[@]}" | sort -u)) - -# Convert to JSON -chart_url_json_arr="[$(printf '"%s",' "${chart_url_array[@]}" | sed 's/,$//')]" -images_json_arr="[$(printf '"%s",' "${image_set[@]}" | sed 's/,$//')]" -json_out="{\"chartURLs\":${chart_url_json_arr},\"images\":${images_json_arr}}" -echo $json_out | jq -r '.' - -# Generata a daemonSet yaml to pre pull images on all nodes - -# find kubeblocks-tools image -KB_TOOLS_IMAGE="" -for image in "${image_set[@]}"; do - if [[ "$image" =~ "kubeblocks-tools" ]]; then - KB_TOOLS_IMAGE=$image - fi -done - -whiteList=(kubeblocks mysql spilo mongo pgbouncer redis wal-g agamotto) -cat < prepuller.yaml -apiVersion: apps/v1 -kind: DaemonSet -metadata: - name: kubeblocks-image-prepuller -spec: - selector: - matchLabels: - name: kubeblocks-image-prepuller - template: - metadata: - labels: - name: kubeblocks-image-prepuller - spec: - volumes: - - name: shared-volume - emptyDir: {} - initContainers: - - name: pull-kb-tools - image: ${KB_TOOLS_IMAGE} - imagePullPolicy: IfNotPresent - command: ["cp", "-r", "/usr/bin/kubectl", "/kb-tools/kubectl"] - volumeMounts: - - name: shared-volume - mountPath: /kb-tools -EOF - -count=1 -for image in "${image_set[@]}"; do - match=false - for j in "${whiteList[@]}"; do - if [[ "$image" =~ "$j" ]]; then - match=true - fi - done - - if ! $match; then - echo "skip image=${image}" - continue - fi - - cat <> prepuller.yaml - - name: pull-${count} - image: ${image} - imagePullPolicy: IfNotPresent - command: ["/kb-tools/kubectl"] - volumeMounts: - - name: shared-volume - mountPath: /kb-tools -EOF - count=$((count+1)) -done - -cat <> prepuller.yaml - containers: - - name: pause - image: k8s.gcr.io/pause:3.2 -EOF \ No newline at end of file diff --git a/deploy/helm/dashboards/container-log.json b/deploy/helm/dashboards/container-log.json deleted file mode 100644 index a178a9cb5bc..00000000000 --- a/deploy/helm/dashboards/container-log.json +++ /dev/null @@ -1,301 +0,0 @@ -{ - "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" - } - ] - }, - "description": "Basic dashboard for Kubernetes Container Logs from Loki.", - "editable": true, - "fiscalYearStartMonth": 0, - "gnetId": 18494, - "graphTooltip": 0, - "id": 12, - "links": [], - "liveNow": false, - "panels": [ - { - "datasource": { - "type": "loki", - "uid": "loki-kubeblocks" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 42, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineStyle": { - "fill": "solid" - }, - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "auto", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 10, - "w": 24, - "x": 0, - "y": 0 - }, - "id": 2, - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom", - "showLegend": false - }, - "tooltip": { - "mode": "single", - "sort": "none" - } - }, - "targets": [ - { - "datasource": { - "type": "loki", - "uid": "loki-kubeblocks" - }, - "editorMode": "builder", - "expr": "sum(count_over_time({namespace=~\"$namespace\", pod=~\"$pod\", container=~\"$container\"} |~ `(?i)$search` [$__interval]))", - "legendFormat": "{{container}}", - "queryType": "range", - "refId": "A", - "resolution": 1 - } - ], - "title": "Logs Trend", - "type": "timeseries" - }, - { - "datasource": { - "type": "loki", - "uid": "loki-kubeblocks" - }, - "gridPos": { - "h": 26, - "w": 24, - "x": 0, - "y": 10 - }, - "id": 3, - "options": { - "dedupStrategy": "exact", - "enableLogDetails": true, - "prettifyLogMessage": false, - "showCommonLabels": false, - "showLabels": true, - "showTime": true, - "sortOrder": "Descending", - "wrapLogMessage": true - }, - "targets": [ - { - "datasource": { - "type": "loki", - "uid": "loki-kubeblocks" - }, - "editorMode": "builder", - "expr": "{namespace=~\"$namespace\", pod=~\"$pod\", container=~\"$container\"} |~ `(?i)$search`", - "queryType": "range", - "refId": "A" - } - ], - "title": "Logs Panel", - "type": "logs" - } - ], - "refresh": false, - "schemaVersion": 37, - "style": "dark", - "tags": [], - "templating": { - "list": [ - { - "allValue": ".+", - "current": { - "selected": false, - "text": "All", - "value": "$__all" - }, - "datasource": { - "type": "loki", - "uid": "loki-kubeblocks" - }, - "definition": "", - "hide": 0, - "includeAll": true, - "label": "Namespace", - "multi": false, - "name": "namespace", - "options": [], - "query": { - "label": "namespace", - "refId": "LokiVariableQueryEditor-VariableQuery", - "stream": "", - "type": 1 - }, - "refresh": 2, - "regex": "", - "skipUrlSync": false, - "sort": 5, - "type": "query" - }, - { - "allValue": ".+", - "current": { - "selected": false, - "text": "All", - "value": "$__all" - }, - "datasource": { - "type": "loki", - "uid": "loki-kubeblocks" - }, - "definition": "", - "hide": 0, - "includeAll": true, - "label": "Pod", - "multi": false, - "name": "pod", - "options": [], - "query": { - "label": "pod", - "refId": "LokiVariableQueryEditor-VariableQuery", - "stream": "{namespace=~\"$namespace\"}", - "type": 1 - }, - "refresh": 2, - "regex": "", - "skipUrlSync": false, - "sort": 5, - "type": "query" - }, - { - "allValue": ".+", - "current": { - "selected": false, - "text": "All", - "value": "$__all" - }, - "datasource": { - "type": "loki", - "uid": "loki-kubeblocks" - }, - "definition": "", - "hide": 0, - "includeAll": true, - "label": "Container", - "multi": false, - "name": "container", - "options": [], - "query": { - "label": "container", - "refId": "LokiVariableQueryEditor-VariableQuery", - "stream": "{namespace=~\"$namespace\", pod=~\"$pod\"}", - "type": 1 - }, - "refresh": 2, - "regex": "", - "skipUrlSync": false, - "sort": 5, - "type": "query" - }, - { - "current": { - "selected": false, - "text": ".+", - "value": ".+" - }, - "hide": 0, - "label": "Search Term", - "name": "search", - "options": [ - { - "selected": true, - "text": ".+", - "value": ".+" - } - ], - "query": ".+", - "skipUrlSync": false, - "type": "textbox" - } - ] - }, - "time": { - "from": "now-30m", - "to": "now" - }, - "timepicker": { - "refresh_intervals": [ - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ] - }, - "timezone": "", - "title": "Container Logs", - "uid": "container-logs", - "version": 1, - "weekStart": "" -} \ No newline at end of file diff --git a/deploy/helm/dashboards/kubeblocks-home.json b/deploy/helm/dashboards/kubeblocks-home.json deleted file mode 100644 index 46416ffd48e..00000000000 --- a/deploy/helm/dashboards/kubeblocks-home.json +++ /dev/null @@ -1,1969 +0,0 @@ -{ - "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": 21, - "links": [ - { - "asDropdown": false, - "icon": "cloud", - "includeVars": false, - "keepTime": false, - "tags": [], - "targetBlank": true, - "title": "ApeCloud", - "tooltip": "Improved productivity, cost-efficiency and business continuity.", - "type": "link", - "url": "https://kubeblocks.io/" - }, - { - "asDropdown": false, - "icon": "external link", - "includeVars": false, - "keepTime": false, - "tags": [], - "targetBlank": true, - "title": "KubeBlocks", - "tooltip": "An open-source and cloud-neutral DBaaS with Kubernetes.", - "type": "link", - "url": "https://github.com/apecloud/kubeblocks" - }, - { - "asDropdown": true, - "icon": "external link", - "includeVars": false, - "keepTime": true, - "tags": [ - "db", - "overview", - "kubeblocks" - ], - "targetBlank": true, - "title": "State Services", - "tooltip": "", - "type": "dashboards", - "url": "" - } - ], - "liveNow": false, - "panels": [ - { - "collapsed": false, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 0 - }, - "id": 2, - "panels": [], - "title": "Overview", - "type": "row" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 6, - "x": 0, - "y": 1 - }, - "id": 8, - "options": { - "colorMode": "value", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "count(sum by (app_kubernetes_io_instance) (k8s_pod_memory_usage_bytes{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name!~\"agamotto|prometheus\"}))", - "legendFormat": "__auto", - "range": true, - "refId": "A" - } - ], - "title": "Clusters", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 6, - "x": 6, - "y": 1 - }, - "id": 10, - "options": { - "colorMode": "value", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "count(sum by (node) (k8s_pod_memory_usage_bytes{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name!~\"agamotto|prometheus\"}))", - "legendFormat": "__auto", - "range": true, - "refId": "A" - } - ], - "title": "Nodes", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 6, - "x": 12, - "y": 1 - }, - "id": 9, - "options": { - "colorMode": "value", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "count(k8s_pod_memory_usage_bytes{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name!~\"agamotto|prometheus\"})", - "legendFormat": "__auto", - "range": true, - "refId": "A" - } - ], - "title": "Instances", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "custom": { - "align": "center", - "displayMode": "auto", - "inspect": false - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 6, - "x": 18, - "y": 1 - }, - "id": 11, - "options": { - "footer": { - "fields": "", - "reducer": [ - "sum" - ], - "show": false - }, - "showHeader": true - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "exemplar": false, - "expr": "count by (app_kubernetes_io_name) (k8s_pod_memory_usage_bytes{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name!~\"agamotto|prometheus\"})", - "format": "table", - "instant": true, - "legendFormat": "__auto", - "range": false, - "refId": "A" - } - ], - "title": "DB Kinds", - "transformations": [ - { - "id": "organize", - "options": { - "excludeByName": { - "Time": true - }, - "indexByName": {}, - "renameByName": { - "Value": "Instances", - "app_kubernetes_io_name": "Kind" - } - } - } - ], - "type": "table" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "percentunit" - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 6, - "x": 0, - "y": 6 - }, - "id": 12, - "options": { - "colorMode": "value", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "sum(rate(k8s_pod_cpu_time_seconds_total{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name!~\"agamotto|prometheus\"}[$__rate_interval]))", - "legendFormat": "__auto", - "range": true, - "refId": "A" - } - ], - "title": "CPU Usage (Cores)", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 6, - "x": 6, - "y": 6 - }, - "id": 13, - "options": { - "colorMode": "value", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "sum(k8s_pod_cpu_limit{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name!~\"agamotto|prometheus\"})", - "legendFormat": "__auto", - "range": true, - "refId": "A" - } - ], - "title": "CPU Limit (Cores)", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "bytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 6, - "x": 12, - "y": 6 - }, - "id": 14, - "options": { - "colorMode": "value", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "sum(k8s_pod_memory_working_set_bytes{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name!~\"agamotto|prometheus\"})", - "legendFormat": "__auto", - "range": true, - "refId": "A" - } - ], - "title": "Memory Usage", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "bytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 6, - "x": 18, - "y": 6 - }, - "id": 15, - "options": { - "colorMode": "value", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "sum(k8s_pod_memory_limit_bytes{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name!~\"agamotto|prometheus\"})", - "legendFormat": "__auto", - "range": true, - "refId": "A" - } - ], - "title": "Memory Limit", - "type": "stat" - }, - { - "collapsed": true, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 11 - }, - "id": 4, - "panels": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 0, - "y": 12 - }, - "id": 16, - "options": { - "colorMode": "value", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "count(sum by (app_kubernetes_io_instance) (k8s_pod_memory_usage_bytes{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"apecloud-mysql\"}))", - "legendFormat": "__auto", - "range": true, - "refId": "A" - } - ], - "title": "Clusters", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 3, - "y": 12 - }, - "id": 19, - "options": { - "colorMode": "value", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "count(sum by (node) (k8s_pod_memory_usage_bytes{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"apecloud-mysql\"}))", - "legendFormat": "__auto", - "range": true, - "refId": "A" - } - ], - "title": "Nodes", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 6, - "y": 12 - }, - "id": 17, - "options": { - "colorMode": "value", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "count(k8s_pod_memory_usage_bytes{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"apecloud-mysql\"})", - "legendFormat": "__auto", - "range": true, - "refId": "A" - } - ], - "title": "Total Instances", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 9, - "y": 12 - }, - "id": 18, - "options": { - "colorMode": "value", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "sum(mysql_up{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"apecloud-mysql\"} <= 0 or vector(0))", - "legendFormat": "__auto", - "range": true, - "refId": "A" - } - ], - "title": "Downs Instances", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "align": "center", - "displayMode": "color-text", - "inspect": false - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - } - }, - "overrides": [ - { - "matcher": { - "id": "byName", - "options": "cluster" - }, - "properties": [ - { - "id": "links", - "value": [ - { - "targetBlank": true, - "title": "MySQL Cluster: ${__data.fields.namespace} | ${__data.fields.cluster}", - "url": "/d/mysql/mysql?orgId=1&var-datasource=default&var-namespace=${__data.fields.namespace}&var-cluster=${__data.fields.cluster}&var-instance=All\n" - } - ] - }, - { - "id": "custom.displayMode", - "value": "color-text" - } - ] - } - ] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 12 - }, - "id": 33, - "options": { - "footer": { - "enablePagination": false, - "fields": "", - "reducer": [ - "sum" - ], - "show": false - }, - "showHeader": true - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "exemplar": false, - "expr": "count by (namespace, app_kubernetes_io_instance) (mysql_up{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"apecloud-mysql\"})", - "format": "table", - "instant": true, - "legendFormat": "__auto", - "range": false, - "refId": "A" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "exemplar": false, - "expr": "count by (namespace, app_kubernetes_io_instance) (mysql_up{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"apecloud-mysql\"} > 0)", - "format": "table", - "hide": false, - "instant": true, - "legendFormat": "__auto", - "range": false, - "refId": "B" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "exemplar": false, - "expr": "count by (app_kubernetes_io_instance) (count by (app_kubernetes_io_instance,node) (mysql_up{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"apecloud-mysql\"}))", - "format": "table", - "hide": false, - "instant": true, - "legendFormat": "__auto", - "range": false, - "refId": "C" - } - ], - "title": "Cluster List", - "transformations": [ - { - "id": "joinByField", - "options": { - "byField": "app_kubernetes_io_instance", - "mode": "outer" - } - }, - { - "id": "organize", - "options": { - "excludeByName": { - "Time 1": true, - "Time 2": true, - "Time 3": true, - "apps_kubeblocks_io_component_name": true, - "namespace 2": true, - "node": true, - "pod": true, - "pod 1": true, - "pod 2": true - }, - "indexByName": { - "Time 1": 2, - "Time 2": 4, - "Time 3": 6, - "Value #A": 3, - "Value #B": 5, - "Value #C": 8, - "app_kubernetes_io_instance": 1, - "namespace 1": 0, - "namespace 2": 10, - "node": 7, - "pod 1": 9, - "pod 2": 11 - }, - "renameByName": { - "Value #A": "total instances", - "Value #B": "running instances", - "Value #C": "nodes", - "app_kubernetes_io_instance": "cluster", - "namespace 1": "namespace", - "pod": "" - } - } - } - ], - "type": "table" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "percentunit" - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 0, - "y": 16 - }, - "id": 20, - "options": { - "colorMode": "value", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "sum(rate(k8s_pod_cpu_time_seconds_total{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"apecloud-mysql\"}[$__rate_interval]))", - "legendFormat": "__auto", - "range": true, - "refId": "A" - } - ], - "title": "CPU Usage (Cores)", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 3, - "y": 16 - }, - "id": 21, - "options": { - "colorMode": "value", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "sum(k8s_pod_cpu_limit{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"apecloud-mysql\"})", - "legendFormat": "__auto", - "range": true, - "refId": "A" - } - ], - "title": "CPU Limit (Cores)", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "bytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 6, - "y": 16 - }, - "id": 22, - "options": { - "colorMode": "value", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "sum(k8s_pod_memory_working_set_bytes{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"apecloud-mysql\"})", - "legendFormat": "__auto", - "range": true, - "refId": "A" - } - ], - "title": "Memory Usage", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "bytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 9, - "y": 16 - }, - "id": 23, - "options": { - "colorMode": "value", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "sum(k8s_pod_memory_limit_bytes{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"apecloud-mysql\"})", - "legendFormat": "__auto", - "range": true, - "refId": "A" - } - ], - "title": "Memory Limit", - "type": "stat" - } - ], - "title": "MySQL", - "type": "row" - }, - { - "collapsed": true, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 12 - }, - "id": 6, - "panels": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 0, - "y": 21 - }, - "id": 24, - "options": { - "colorMode": "value", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "count(sum by (app_kubernetes_io_instance) (k8s_pod_memory_usage_bytes{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"postgresql\"}))", - "legendFormat": "__auto", - "range": true, - "refId": "A" - } - ], - "title": "Clusters", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 3, - "y": 21 - }, - "id": 27, - "options": { - "colorMode": "value", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "count(sum by (node) (k8s_pod_memory_usage_bytes{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"postgresql\"}))", - "legendFormat": "__auto", - "range": true, - "refId": "A" - } - ], - "title": "Nodes", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 6, - "y": 21 - }, - "id": 25, - "options": { - "colorMode": "value", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "count(k8s_pod_memory_usage_bytes{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"postgresql\"})", - "legendFormat": "__auto", - "range": true, - "refId": "A" - } - ], - "title": "Total Instances", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 9, - "y": 21 - }, - "id": 26, - "options": { - "colorMode": "value", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "sum(pg_up{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"postgresql\"} <= 0 or vector(0))", - "legendFormat": "__auto", - "range": true, - "refId": "A" - } - ], - "title": "Downs Instances", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "align": "center", - "displayMode": "color-text", - "inspect": false - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - } - }, - "overrides": [ - { - "matcher": { - "id": "byName", - "options": "cluster" - }, - "properties": [ - { - "id": "links", - "value": [ - { - "targetBlank": true, - "title": "PostgreSQL Cluster: ${__data.fields.namespace} | ${__data.fields.cluster}", - "url": "/d/kubeblocks-postgresql-detail/kubeblocks-postgresql-detail?orgId=1&var-datasource=default&var-namespace=${__data.fields.namespace}&var-cluster=${__data.fields.cluster}&var-instance=All&var-database=All" - } - ] - } - ] - } - ] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 21 - }, - "id": 34, - "options": { - "footer": { - "enablePagination": false, - "fields": "", - "reducer": [ - "sum" - ], - "show": false - }, - "showHeader": true - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "exemplar": false, - "expr": "count by (namespace, app_kubernetes_io_instance) (pg_up{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"postgresql\"})", - "format": "table", - "instant": true, - "legendFormat": "__auto", - "range": false, - "refId": "A" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "exemplar": false, - "expr": "count by (namespace, app_kubernetes_io_instance) (pg_up{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"postgresql\"} > 0)", - "format": "table", - "hide": false, - "instant": true, - "legendFormat": "__auto", - "range": false, - "refId": "B" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "exemplar": false, - "expr": "count by (app_kubernetes_io_instance) (count by (app_kubernetes_io_instance,node) (pg_up{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"postgresql\"}))", - "format": "table", - "hide": false, - "instant": true, - "legendFormat": "__auto", - "range": false, - "refId": "C" - } - ], - "title": "Cluster List", - "transformations": [ - { - "id": "joinByField", - "options": { - "byField": "app_kubernetes_io_instance", - "mode": "outer" - } - }, - { - "id": "organize", - "options": { - "excludeByName": { - "Time 1": true, - "Time 2": true, - "Time 3": true, - "apps_kubeblocks_io_component_name": true, - "namespace 2": true, - "node": true, - "pod": true - }, - "indexByName": { - "Time 1": 2, - "Time 2": 4, - "Time 3": 6, - "Value #A": 3, - "Value #B": 5, - "Value #C": 8, - "app_kubernetes_io_instance": 1, - "namespace 1": 0, - "namespace 2": 9, - "node": 7 - }, - "renameByName": { - "Value #A": "total instances", - "Value #B": "running instances", - "Value #C": "nodes", - "app_kubernetes_io_instance": "cluster", - "namespace 1": "namespace", - "pod": "" - } - } - } - ], - "type": "table" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "percentunit" - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 0, - "y": 25 - }, - "id": 28, - "options": { - "colorMode": "value", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "sum(rate(k8s_pod_cpu_time_seconds_total{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"postgresql\"}[$__rate_interval]))", - "legendFormat": "__auto", - "range": true, - "refId": "A" - } - ], - "title": "CPU Usage (Cores)", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 3, - "y": 25 - }, - "id": 29, - "options": { - "colorMode": "value", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "sum(k8s_pod_cpu_limit{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"postgresql\"})", - "legendFormat": "__auto", - "range": true, - "refId": "A" - } - ], - "title": "CPU Limit (Cores)", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "bytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 6, - "y": 25 - }, - "id": 30, - "options": { - "colorMode": "value", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "sum(k8s_pod_memory_working_set_bytes{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"postgresql\"})", - "legendFormat": "__auto", - "range": true, - "refId": "A" - } - ], - "title": "Memory Usage", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "bytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 9, - "y": 25 - }, - "id": 31, - "options": { - "colorMode": "value", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "sum(k8s_pod_memory_limit_bytes{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"postgresql\"})", - "legendFormat": "__auto", - "range": true, - "refId": "A" - } - ], - "title": "Memory Limit", - "type": "stat" - } - ], - "title": "PostgreSQL", - "type": "row" - } - ], - "schemaVersion": 37, - "style": "dark", - "tags": [ - "kubeblocks", - "overview" - ], - "templating": { - "list": [ - { - "current": { - "selected": false, - "text": "default", - "value": "default" - }, - "hide": 0, - "includeAll": false, - "label": "data source", - "multi": false, - "name": "datasource", - "options": [], - "query": "prometheus", - "queryValue": "", - "refresh": 1, - "regex": "", - "skipUrlSync": false, - "type": "datasource" - } - ] - }, - "time": { - "from": "now-30m", - "to": "now" - }, - "timepicker": {}, - "timezone": "", - "title": "Kubeblocks / Home", - "uid": "kubeblocks_home", - "version": 1, - "weekStart": "" -} diff --git a/deploy/helm/dashboards/kubeblocks-postgresql-detail.json b/deploy/helm/dashboards/kubeblocks-postgresql-detail.json deleted file mode 100644 index e7592e55dc5..00000000000 --- a/deploy/helm/dashboards/kubeblocks-postgresql-detail.json +++ /dev/null @@ -1,8301 +0,0 @@ -{ - "annotations": { - "list": [ - { - "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": "", - "editable": true, - "fiscalYearStartMonth": 0, - "gnetId": 11323, - "graphTooltip": 0, - "id": 23, - "links": [ - { - "asDropdown": false, - "icon": "cloud", - "includeVars": false, - "keepTime": false, - "tags": [], - "targetBlank": true, - "title": "ApeCloud", - "tooltip": "Improved productivity, cost-efficiency and business continuity.", - "type": "link", - "url": "https://kubeblocks.io/" - }, - { - "asDropdown": false, - "icon": "external link", - "includeVars": false, - "keepTime": false, - "tags": [], - "targetBlank": true, - "title": "KubeBlocks", - "tooltip": "An open-source and cloud-neutral DBaaS with Kubernetes.", - "type": "link", - "url": "https://github.com/apecloud/kubeblocks" - } - ], - "liveNow": false, - "panels": [ - { - "collapsed": false, - "datasource": { - "uid": "$datasource" - }, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 0 - }, - "id": 382, - "panels": [], - "targets": [ - { - "datasource": { - "uid": "$datasource" - }, - "refId": "A" - } - ], - "title": "Summary", - "type": "row" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 7, - "x": 0, - "y": 1 - }, - "id": 525, - "options": { - "colorMode": "background", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "name" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "exemplar": false, - "expr": "count by (namespace) (pg_up{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"})", - "format": "time_series", - "instant": true, - "legendFormat": "{{namespace}}", - "range": false, - "refId": "A" - } - ], - "title": "Namespace", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "decimals": 0, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 7, - "y": 1 - }, - "id": 421, - "interval": "", - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "value", - "fieldOptions": { - "calcs": [ - "lastNotNull" - ] - }, - "graphMode": "area", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "count(pg_up{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"} > 0) or vector(0)", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "__auto", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Running Instances", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "custom": { - "align": "center", - "displayMode": "auto", - "filterable": false, - "inspect": false - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - } - }, - "overrides": [ - { - "matcher": { - "id": "byName", - "options": "instance" - }, - "properties": [ - { - "id": "links", - "value": [ - { - "targetBlank": true, - "title": "PostgreSQL Instance: ${__data.fields.cluster} | ${__data.fields.instance}", - "url": "/d/kubeletstats/kubelet-stats?orgId=1&var-datasource=default&var-node=All&var-cluster=${__data.fields.cluster}&var-pod=${__data.fields.instance}" - } - ] - }, - { - "id": "custom.align", - "value": "center" - }, - { - "id": "custom.filterable", - "value": true - }, - { - "id": "custom.displayMode", - "value": "color-text" - } - ] - }, - { - "matcher": { - "id": "byName", - "options": "uptime" - }, - "properties": [ - { - "id": "unit", - "value": "s" - }, - { - "id": "thresholds", - "value": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-green", - "value": null - }, - { - "color": "dark-yellow", - "value": 60 - }, - { - "color": "dark-green", - "value": 120 - } - ] - } - }, - { - "id": "custom.displayMode", - "value": "lcd-gauge" - } - ] - }, - { - "matcher": { - "id": "byName", - "options": "cluster" - }, - "properties": [ - { - "id": "custom.filterable", - "value": true - } - ] - }, - { - "matcher": { - "id": "byName", - "options": "cpu usage (cores)" - }, - "properties": [ - { - "id": "custom.displayMode", - "value": "color-text" - }, - { - "id": "unit", - "value": "percentunit" - } - ] - }, - { - "matcher": { - "id": "byName", - "options": "memory usage" - }, - "properties": [ - { - "id": "custom.displayMode", - "value": "color-text" - }, - { - "id": "unit", - "value": "bytes" - } - ] - } - ] - }, - "gridPos": { - "h": 8, - "w": 14, - "x": 10, - "y": 1 - }, - "id": 527, - "interval": "", - "links": [], - "maxDataPoints": 100, - "options": { - "footer": { - "enablePagination": false, - "fields": "", - "reducer": [ - "sum" - ], - "show": false - }, - "showHeader": true, - "sortBy": [ - { - "desc": true, - "displayName": "uptime" - } - ] - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "exemplar": false, - "expr": "sum by(namespace,app_kubernetes_io_instance,pod) (pg_up{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"})", - "format": "table", - "instant": true, - "interval": "", - "intervalFactor": 1, - "legendFormat": "__auto", - "metric": "", - "range": false, - "refId": "A", - "step": 20 - }, - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "exemplar": false, - "expr": "avg by(namespace,app_kubernetes_io_instance,pod) (time() - pg_postmaster_start_time_seconds{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"})", - "format": "table", - "hide": false, - "instant": true, - "interval": "", - "intervalFactor": 1, - "legendFormat": "__auto", - "metric": "", - "range": false, - "refId": "B", - "step": 20 - }, - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "exemplar": false, - "expr": "count by(short_version,app_kubernetes_io_instance,pod)(pg_static{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"})", - "format": "table", - "hide": false, - "instant": true, - "interval": "", - "intervalFactor": 1, - "legendFormat": "__auto", - "metric": "", - "range": false, - "refId": "C", - "step": 20 - }, - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "exemplar": false, - "expr": "sum by (app_kubernetes_io_instance,pod) (label_replace(rate(k8s_pod_cpu_time_seconds_total{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"postgresql\",k8s_namespace_name=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",k8s_pod_name=~\"$instance\"}[$__rate_interval]), \"pod\", \"$1\", \"k8s_pod_name\", \"(.*)\"))", - "format": "table", - "hide": false, - "instant": true, - "interval": "", - "intervalFactor": 1, - "legendFormat": "__auto", - "metric": "", - "range": false, - "refId": "D", - "step": 20 - }, - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "exemplar": false, - "expr": "sum by (app_kubernetes_io_instance,pod) (label_replace(k8s_pod_memory_working_set_bytes{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"postgresql\",k8s_namespace_name=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",k8s_pod_name=~\"$instance\"}, \"pod\", \"$1\", \"k8s_pod_name\", \"(.*)\"))", - "format": "table", - "hide": false, - "instant": true, - "interval": "", - "intervalFactor": 1, - "legendFormat": "__auto", - "metric": "", - "range": false, - "refId": "E", - "step": 20 - } - ], - "title": "Instances", - "transformations": [ - { - "id": "joinByField", - "options": { - "byField": "pod", - "mode": "outer" - } - }, - { - "id": "organize", - "options": { - "excludeByName": { - "Time 1": true, - "Time 2": true, - "Time 3": true, - "Time 4": true, - "Time 5": true, - "Value #A": true, - "Value #C": true, - "app_kubernetes_io_instance 2": true, - "app_kubernetes_io_instance 3": true, - "app_kubernetes_io_instance 4": true, - "app_kubernetes_io_instance 5": true, - "namespace 1": true, - "namespace 2": true - }, - "indexByName": { - "Time 1": 3, - "Time 2": 5, - "Time 3": 9, - "Time 4": 12, - "Time 5": 15, - "Value #A": 4, - "Value #B": 18, - "Value #C": 11, - "Value #D": 14, - "Value #E": 17, - "app_kubernetes_io_instance 1": 1, - "app_kubernetes_io_instance 2": 6, - "app_kubernetes_io_instance 3": 10, - "app_kubernetes_io_instance 4": 13, - "app_kubernetes_io_instance 5": 16, - "namespace 1": 0, - "namespace 2": 7, - "pod": 2, - "short_version": 8 - }, - "renameByName": { - "Value #B": "uptime", - "Value #D": "cpu usage (cores)", - "Value #E": "memory usage", - "app_kubernetes_io_instance 1": "cluster", - "namespace 1": "namespace", - "pod": "instance" - } - } - } - ], - "type": "table" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 7, - "x": 0, - "y": 5 - }, - "id": 526, - "options": { - "colorMode": "background", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "name" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "exemplar": false, - "expr": "count by (app_kubernetes_io_instance) (pg_up{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"})", - "format": "time_series", - "instant": true, - "legendFormat": "{{app_kubernetes_io_instance}}", - "range": false, - "refId": "A" - } - ], - "title": "Cluster", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "decimals": 0, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - }, - { - "color": "dark-red", - "value": 0.5 - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 7, - "y": 5 - }, - "id": 420, - "interval": "", - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "value", - "fieldOptions": { - "calcs": [ - "lastNotNull" - ] - }, - "graphMode": "area", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "exemplar": false, - "expr": "count(pg_up{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"} <= 0) or vector(0)", - "format": "time_series", - "instant": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "__auto", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Down Instances", - "transformations": [], - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "percentunit" - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 0, - "y": 9 - }, - "id": 516, - "interval": "", - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "value", - "fieldOptions": { - "calcs": [ - "lastNotNull" - ] - }, - "graphMode": "area", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "sum(rate(k8s_pod_cpu_time_seconds_total{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"postgresql\",k8s_namespace_name=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",k8s_pod_name=~\"$instance\"}[$__rate_interval]))", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "__auto", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "CPU Usage (Cores)", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "bytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 3, - "y": 9 - }, - "id": 520, - "interval": "", - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "value", - "fieldOptions": { - "calcs": [ - "lastNotNull" - ] - }, - "graphMode": "area", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "sum(k8s_pod_memory_working_set_bytes{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"postgresql\",k8s_namespace_name=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",k8s_pod_name=~\"$instance\"})", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "__auto", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Memory Usage", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "decimals": 2, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 6, - "y": 9 - }, - "id": 442, - "interval": "", - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "value", - "fieldOptions": { - "calcs": [ - "lastNotNull" - ] - }, - "graphMode": "area", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "exemplar": false, - "expr": "sum(rate(pg_stat_database_xact_commit_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}[$__rate_interval]) + rate(pg_stat_database_xact_rollback_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}[$__rate_interval])) or vector(0)", - "format": "time_series", - "instant": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{label_name}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Total Tps", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "custom": { - "align": "center", - "displayMode": "auto", - "filterable": false, - "inspect": false - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - } - }, - "overrides": [ - { - "matcher": { - "id": "byName", - "options": "instance" - }, - "properties": [ - { - "id": "links", - "value": [ - { - "targetBlank": true, - "title": "PostgreSQL Instance: ${__data.fields.cluster} | ${__data.fields.instance}", - "url": "/d/kubeletstats/kubelet-stats?orgId=1&var-datasource=default&var-node=All&var-cluster=${__data.fields.cluster}&var-pod=${__data.fields.instance}" - } - ] - }, - { - "id": "custom.align", - "value": "center" - }, - { - "id": "custom.filterable", - "value": true - }, - { - "id": "custom.displayMode", - "value": "color-text" - } - ] - }, - { - "matcher": { - "id": "byName", - "options": "cluster" - }, - "properties": [ - { - "id": "custom.filterable", - "value": true - } - ] - }, - { - "matcher": { - "id": "byName", - "options": "volume name" - }, - "properties": [ - { - "id": "custom.filterable", - "value": true - } - ] - }, - { - "matcher": { - "id": "byName", - "options": "volume type" - }, - "properties": [ - { - "id": "custom.filterable", - "value": true - } - ] - }, - { - "matcher": { - "id": "byName", - "options": "usage ratio" - }, - "properties": [ - { - "id": "custom.displayMode", - "value": "color-text" - }, - { - "id": "unit", - "value": "percentunit" - }, - { - "id": "thresholds", - "value": { - "mode": "absolute", - "steps": [ - { - "color": "blue", - "value": null - }, - { - "color": "red", - "value": 0.8 - } - ] - } - } - ] - } - ] - }, - "gridPos": { - "h": 8, - "w": 15, - "x": 9, - "y": 9 - }, - "id": 428, - "interval": "", - "links": [], - "maxDataPoints": 100, - "options": { - "footer": { - "enablePagination": false, - "fields": "", - "reducer": [ - "sum" - ], - "show": false - }, - "showHeader": true, - "sortBy": [ - { - "desc": true, - "displayName": "uptime" - } - ] - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "exemplar": false, - "expr": "1 - (k8s_volume_available_bytes{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"postgresql\",k8s_volume_type=~\"emptyDir|ephemeral-storage|persistentVolumeClaim|hostPath\",k8s_namespace_name=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",k8s_pod_name=~\"$instance\"}/k8s_volume_capacity_bytes{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"postgresql\",k8s_volume_type=~\"emptyDir|ephemeral-storage|persistentVolumeClaim|hostPath\",k8s_namespace_name=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",k8s_pod_name=~\"$instance\"}) > 0.0001", - "format": "table", - "instant": true, - "interval": "", - "intervalFactor": 1, - "legendFormat": "__auto", - "metric": "", - "range": false, - "refId": "A", - "step": 20 - } - ], - "title": "Volumes", - "transformations": [ - { - "id": "organize", - "options": { - "excludeByName": { - "Time": true, - "app_kubernetes_io_component": true, - "app_kubernetes_io_instance": false, - "app_kubernetes_io_managed_by": true, - "app_kubernetes_io_name": true, - "app_kubernetes_io_version": true, - "apps_kubeblocks_io_component_name": true, - "hostname": true, - "instance": true, - "job": true, - "k8s_namespace_name": true, - "kubernetes_io_arch": true, - "kubernetes_io_hostname": true, - "kubernetes_io_os": true, - "node": true, - "receiver": true - }, - "indexByName": { - "Time": 0, - "Value": 20, - "app_kubernetes_io_component": 1, - "app_kubernetes_io_instance": 2, - "app_kubernetes_io_managed_by": 3, - "app_kubernetes_io_name": 4, - "app_kubernetes_io_version": 5, - "apps_kubeblocks_io_component_name": 6, - "hostname": 7, - "instance": 8, - "job": 9, - "k8s_namespace_name": 10, - "k8s_persistentvolumeclaim_name": 14, - "k8s_pod_name": 11, - "k8s_volume_name": 12, - "k8s_volume_type": 13, - "kubernetes_io_arch": 15, - "kubernetes_io_hostname": 16, - "kubernetes_io_os": 17, - "node": 18, - "receiver": 19 - }, - "renameByName": { - "Value": "usage ratio", - "app_kubernetes_io_component": "component type", - "app_kubernetes_io_instance": "cluster", - "app_kubernetes_io_managed_by": "", - "app_kubernetes_io_name": "", - "apps_kubeblocks_io_component_name": "component name", - "k8s_persistentvolumeclaim_name": "pvc name", - "k8s_pod_name": "instance", - "k8s_volume_name": "volume name", - "k8s_volume_type": "volume type" - } - } - } - ], - "type": "table" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 0, - "y": 13 - }, - "id": 518, - "interval": "", - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "value", - "fieldOptions": { - "calcs": [ - "lastNotNull" - ] - }, - "graphMode": "area", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "sum(k8s_pod_cpu_limit{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"postgresql\",k8s_namespace_name=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",k8s_pod_name=~\"$instance\"})", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "__auto", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "CPU Limit (Cores)", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "bytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 3, - "y": 13 - }, - "id": 522, - "interval": "", - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "value", - "fieldOptions": { - "calcs": [ - "lastNotNull" - ] - }, - "graphMode": "area", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "sum(k8s_pod_memory_limit_bytes{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"postgresql\",k8s_namespace_name=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",k8s_pod_name=~\"$instance\"})", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "__auto", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Memory Limit", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "decimals": 2, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 6, - "y": 13 - }, - "id": 443, - "interval": "", - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "value", - "fieldOptions": { - "calcs": [ - "lastNotNull" - ] - }, - "graphMode": "area", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "sum(rate(pg_stat_statements_stats_calls_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}[$__rate_interval])) or vector(0)", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{label_name}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Total Qps", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "custom": { - "align": "center", - "displayMode": "auto", - "inspect": false - }, - "decimals": 2, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "dark-blue", - "value": null - } - ] - }, - "unit": "short" - }, - "overrides": [ - { - "matcher": { - "id": "byName", - "options": "queryid" - }, - "properties": [ - { - "id": "unit", - "value": "long" - }, - { - "id": "custom.inspect", - "value": true - } - ] - }, - { - "matcher": { - "id": "byName", - "options": "avg exec time" - }, - "properties": [ - { - "id": "unit", - "value": "s" - } - ] - }, - { - "matcher": { - "id": "byName", - "options": "instance" - }, - "properties": [ - { - "id": "links", - "value": [] - }, - { - "id": "custom.displayMode", - "value": "auto" - } - ] - }, - { - "matcher": { - "id": "byName", - "options": "query" - }, - "properties": [ - { - "id": "custom.minWidth", - "value": 500 - }, - { - "id": "custom.align", - "value": "left" - }, - { - "id": "custom.displayMode", - "value": "color-text" - }, - { - "id": "custom.inspect", - "value": true - } - ] - } - ] - }, - "gridPos": { - "h": 7, - "w": 24, - "x": 0, - "y": 17 - }, - "id": 441, - "interval": "", - "links": [], - "maxDataPoints": 100, - "options": { - "footer": { - "fields": "", - "reducer": [ - "sum" - ], - "show": false - }, - "showHeader": true, - "sortBy": [] - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "exemplar": false, - "expr": "topk(10, pg_stat_statements_by_mean_exec_time_mean_exec_time_seconds{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"})", - "format": "table", - "instant": true, - "interval": "", - "intervalFactor": 1, - "legendFormat": "", - "metric": "", - "range": false, - "refId": "A", - "step": 20 - } - ], - "title": "Top10 Avg Exec Time Statements", - "transformations": [ - { - "id": "organize", - "options": { - "excludeByName": { - "Time": true, - "__name__": true, - "app_kubernetes_io_component": true, - "app_kubernetes_io_component_name": true, - "app_kubernetes_io_instance": true, - "app_kubernetes_io_managed_by": true, - "app_kubernetes_io_name": true, - "app_kubernetes_io_version": true, - "apps_kubeblocks_io_component_name": true, - "helm_sh_chart": true, - "instance": true, - "job": true, - "namespace": true, - "node": true, - "receiver": true, - "rolname": true, - "server": true, - "service": true - }, - "indexByName": { - "Time": 1, - "Value": 12, - "__name__": 2, - "app_kubernetes_io_component": 15, - "app_kubernetes_io_instance": 3, - "app_kubernetes_io_managed_by": 4, - "app_kubernetes_io_name": 5, - "app_kubernetes_io_version": 16, - "apps_kubeblocks_io_component_name": 17, - "datname": 7, - "helm_sh_chart": 18, - "instance": 8, - "job": 9, - "namespace": 0, - "node": 19, - "pod": 6, - "query": 13, - "queryid": 14, - "receiver": 20, - "rolname": 10, - "server": 11, - "service": 21 - }, - "renameByName": { - "Value": "avg exec time", - "app_kubernetes_io_instance": "cluster", - "pod": "instance", - "rolname": "tablename" - } - } - } - ], - "type": "table" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "custom": { - "align": "center", - "displayMode": "auto", - "inspect": false - }, - "decimals": 2, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "dark-blue", - "value": null - } - ] - }, - "unit": "short" - }, - "overrides": [ - { - "matcher": { - "id": "byName", - "options": "queryid" - }, - "properties": [ - { - "id": "unit", - "value": "long" - }, - { - "id": "custom.inspect", - "value": true - } - ] - }, - { - "matcher": { - "id": "byName", - "options": "instance" - }, - "properties": [ - { - "id": "links", - "value": [] - }, - { - "id": "custom.align", - "value": "center" - }, - { - "id": "custom.displayMode", - "value": "auto" - } - ] - }, - { - "matcher": { - "id": "byName", - "options": "query" - }, - "properties": [ - { - "id": "custom.inspect", - "value": true - }, - { - "id": "custom.displayMode", - "value": "color-text" - }, - { - "id": "custom.align", - "value": "left" - }, - { - "id": "custom.minWidth", - "value": 500 - } - ] - } - ] - }, - "gridPos": { - "h": 7, - "w": 24, - "x": 0, - "y": 24 - }, - "id": 439, - "interval": "", - "links": [], - "maxDataPoints": 100, - "options": { - "footer": { - "fields": "", - "reducer": [ - "sum" - ], - "show": false - }, - "showHeader": true, - "sortBy": [ - { - "desc": true, - "displayName": "count" - } - ] - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "exemplar": false, - "expr": "topk(10, increase(pg_stat_statements_by_calls_calls_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"}[10m]))", - "format": "table", - "instant": true, - "interval": "", - "intervalFactor": 1, - "legendFormat": "", - "metric": "", - "range": false, - "refId": "A", - "step": 20 - } - ], - "title": "Top10 Most Called Statements Within 10 Minites", - "transformations": [ - { - "id": "organize", - "options": { - "excludeByName": { - "Time": true, - "__name__": true, - "app_kubernetes_io_component": true, - "app_kubernetes_io_component_name": true, - "app_kubernetes_io_instance": true, - "app_kubernetes_io_managed_by": true, - "app_kubernetes_io_name": true, - "app_kubernetes_io_version": true, - "apps_kubeblocks_io_component_name": true, - "helm_sh_chart": true, - "instance": true, - "job": true, - "namespace": true, - "node": true, - "receiver": true, - "rolname": true, - "server": true, - "service": true - }, - "indexByName": { - "Time": 1, - "Value": 11, - "app_kubernetes_io_component": 14, - "app_kubernetes_io_instance": 2, - "app_kubernetes_io_managed_by": 3, - "app_kubernetes_io_name": 4, - "apps_kubeblocks_io_component_name": 15, - "datname": 6, - "instance": 7, - "job": 8, - "namespace": 0, - "node": 16, - "pod": 5, - "query": 12, - "queryid": 13, - "rolname": 9, - "server": 10, - "service": 17 - }, - "renameByName": { - "Value": "count", - "app_kubernetes_io_instance": "cluster", - "pod": "instance", - "rolname": "tablename" - } - } - } - ], - "type": "table" - }, - { - "collapsed": true, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 31 - }, - "id": 412, - "panels": [ - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 28 - }, - "id": 413, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "pg_stat_database_numbackends{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{datname}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Current Connections", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 28 - }, - "id": 414, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "pg_stat_activity_count{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",state=\"active\",job=\"$job\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{datname}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Active Connections", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": "percentunit" - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 36 - }, - "id": 512, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "sum by(namespace,app_kubernetes_io_instance,pod) (pg_stat_database_numbackends{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}) / on(namespace,app_kubernetes_io_instance,pod) pg_settings_max_connections{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Used Connections Ratio", - "type": "timeseries" - } - ], - "title": "Connections", - "type": "row" - }, - { - "collapsed": true, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 32 - }, - "id": 431, - "panels": [ - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 88 - }, - "id": 432, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "exemplar": false, - "expr": "rate(pg_stat_user_tables_idx_scan_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "instant": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{datname}} | {{relname}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Index Scans Per Second", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 88 - }, - "id": 434, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "exemplar": false, - "expr": "rate(pg_stat_user_tables_idx_tup_fetch_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"}[$__rate_interval]) / rate(pg_stat_user_tables_idx_scan_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "instant": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{datname}} | {{relname}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Average Index Tuples Fetch", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 96 - }, - "id": 433, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "exemplar": false, - "expr": "rate(pg_stat_user_tables_seq_scan_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "instant": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{datname}} | {{relname}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Seq Scans Per Second", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 96 - }, - "id": 435, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "exemplar": false, - "expr": "rate(pg_stat_user_tables_seq_tup_read_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"}[$__rate_interval]) / rate(pg_stat_user_tables_seq_scan_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "instant": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{datname}} | {{relname}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Average Seq Tuples Read", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 104 - }, - "id": 436, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "exemplar": false, - "expr": "pg_stat_user_tables_n_live_tup{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"}", - "format": "time_series", - "instant": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{datname}} | {{relname}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Estimated Live Tuples", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 104 - }, - "id": 437, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "exemplar": false, - "expr": "pg_stat_user_tables_n_dead_tup{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"}", - "format": "time_series", - "instant": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{datname}} | {{relname}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Estimated Dead Tuples", - "type": "timeseries" - } - ], - "title": "Queries Per Table", - "type": "row" - }, - { - "collapsed": true, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 33 - }, - "id": 393, - "panels": [ - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 113 - }, - "id": 394, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_database_tup_fetched_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{datname}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Fetched Per Second", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 113 - }, - "id": 395, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_database_tup_returned_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{datname}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Returned Per Second", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 121 - }, - "id": 396, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_database_tup_inserted_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{datname}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Inserted Per Second", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 121 - }, - "id": 397, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_database_tup_updated_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{datname}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Updated Per Second", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 129 - }, - "id": 398, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_database_tup_deleted_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{datname}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Deleted Per Second", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": "bytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 129 - }, - "id": 407, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_database_temp_bytes_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{datname}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Data Written to Temp Files Per Second", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 137 - }, - "id": 406, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_database_temp_files_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{datname}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Temp Files Per Second", - "type": "timeseries" - } - ], - "title": "Tuples Per Database", - "type": "row" - }, - { - "collapsed": true, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 34 - }, - "id": 514, - "panels": [ - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 146 - }, - "id": 389, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_database_xact_commit_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{datname}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Commits Per Second", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 146 - }, - "id": 390, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_database_xact_rollback_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{datname}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Rollbacks Per Second", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": "s" - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 154 - }, - "id": 391, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "max without(state) (max_over_time(pg_stat_activity_max_tx_duration{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"}[$__interval]))", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{datname}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Max Duration of Transactions", - "type": "timeseries" - } - ], - "title": "Transactions Per Database", - "type": "row" - }, - { - "collapsed": true, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 35 - }, - "id": 494, - "panels": [ - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 36 - }, - "id": 408, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "sum by(namespace,app_kubernetes_io_instance,pod,state) (pg_stat_activity_detail_count{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"})", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{state}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Server Process By State", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 36 - }, - "id": 489, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "sum by(namespace,app_kubernetes_io_instance,pod,backend_type) (pg_stat_activity_detail_count{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"})", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{backend_type}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Server Process By Backend Type", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 44 - }, - "id": 490, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "sum by(namespace,app_kubernetes_io_instance,pod,wait_event_type) (pg_stat_activity_detail_count{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"})", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{wait_event_type}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Server Process By Wait Event Type", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 44 - }, - "id": 491, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "sum by(namespace,app_kubernetes_io_instance,pod,wait_event_type,wait_event) (pg_stat_activity_detail_count{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"})", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{wait_event_type}} | {{wait_event}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Server Process By Wait Event", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 52 - }, - "id": 492, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "sum by(namespace,app_kubernetes_io_instance,pod,datname) (pg_stat_activity_detail_count{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"})", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{datname}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Server Process By Database", - "type": "timeseries" - } - ], - "title": "Server Processes", - "type": "row" - }, - { - "collapsed": true, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 36 - }, - "id": 511, - "panels": [ - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 61 - }, - "id": 423, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_archiver_archived_count_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "success: {{namespace}} | {{app_kubernetes_io_instance}} | {{pod}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - }, - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_archiver_failed_count_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "fail: {{namespace}} | {{app_kubernetes_io_instance}} | {{pod}}", - "metric": "", - "range": true, - "refId": "B", - "step": 20 - } - ], - "title": "WAL Files Per Second (archiver)", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": "bytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 61 - }, - "id": 487, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "pg_wal_log_file_count{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"} * pg_settings_wal_segment_size_bytes{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "total wal disk size: {{namespace}} | {{app_kubernetes_io_instance}} | {{pod}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - }, - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "pg_settings_wal_segment_size_bytes{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "wal_segment_size: {{namespace}} | {{app_kubernetes_io_instance}} | {{pod}}", - "metric": "", - "range": true, - "refId": "B", - "step": 20 - } - ], - "title": "WAL Files Disk Size (archiver)", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": "ms" - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 69 - }, - "id": 410, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_bgwriter_checkpoint_write_time_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "Written Files to disk: {{namespace}} | {{app_kubernetes_io_instance}} | {{pod}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - }, - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_bgwriter_checkpoint_sync_time_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "Files Synchronization to disk: {{namespace}} | {{app_kubernetes_io_instance}} | {{pod}}", - "metric": "", - "range": true, - "refId": "B", - "step": 20 - } - ], - "title": "Checkpoints Time Per Second (bgwriter)", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 69 - }, - "id": 415, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_bgwriter_checkpoints_timed_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "Scheduled: {{namespace}} | {{app_kubernetes_io_instance}} | {{pod}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - }, - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_bgwriter_checkpoints_req_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "Requested: {{namespace}} | {{app_kubernetes_io_instance}} | {{pod}}", - "metric": "", - "range": true, - "refId": "B", - "step": 20 - } - ], - "title": "Checkpoints Per Second (bgwriter)", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 77 - }, - "id": 403, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_bgwriter_buffers_alloc_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "Allocated: {{namespace}} | {{app_kubernetes_io_instance}} | {{pod}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - }, - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_bgwriter_buffers_backend_fsync_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "Fsync calls by a backend: {{namespace}} | {{app_kubernetes_io_instance}} | {{pod}}", - "metric": "", - "range": true, - "refId": "B", - "step": 20 - }, - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_bgwriter_buffers_backend_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "Written directly by backend: {{namespace}} | {{app_kubernetes_io_instance}} | {{pod}}", - "metric": "", - "range": true, - "refId": "C", - "step": 20 - }, - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_bgwriter_buffers_clean_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "Written by the background writer: {{namespace}} | {{app_kubernetes_io_instance}} | {{pod}}", - "metric": "", - "range": true, - "refId": "D", - "step": 20 - }, - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_bgwriter_buffers_checkpoint_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "Written during checkpoints: {{namespace}} | {{app_kubernetes_io_instance}} | {{pod}}", - "metric": "", - "range": true, - "refId": "E", - "step": 20 - }, - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_bgwriter_maxwritten_clean_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "Written stopped by the background writer: {{namespace}} | {{app_kubernetes_io_instance}} | {{pod}}", - "metric": "", - "range": true, - "refId": "F", - "step": 20 - } - ], - "title": "Buffers Written Per Second (bgwriter)", - "type": "timeseries" - } - ], - "title": "Background Process", - "type": "row" - }, - { - "collapsed": true, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 37 - }, - "id": 496, - "panels": [ - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 86 - }, - "id": 499, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "sum by(namespace,app_kubernetes_io_instance,pod,locktype) (pg_locks_detail_count{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"})", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{locktype}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Locks By Lock Type", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 86 - }, - "id": 498, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "sum by(namespace,app_kubernetes_io_instance,pod,mode) (pg_locks_detail_count{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"})", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{mode}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Locks By Mode", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 94 - }, - "id": 501, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "sum by(namespace,app_kubernetes_io_instance,pod,datname,relation) (pg_locks_detail_count{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\",locktype=\"relation\"})", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{datname}} | {{relation}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Locks By Relation(Table)", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [ - { - "__systemRef": "hideSeriesFrom", - "matcher": { - "id": "byNames", - "options": { - "mode": "exclude", - "names": [ - "Lock Held: default | pg14 | pg14-postgresql-0 " - ], - "prefix": "All except:", - "readOnly": true - } - }, - "properties": [ - { - "id": "custom.hideFrom", - "value": { - "legend": false, - "tooltip": false, - "viz": true - } - } - ] - } - ] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 94 - }, - "id": 500, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "sum by(namespace,app_kubernetes_io_instance,pod) (pg_locks_detail_count{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\",granted=\"1\"})", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "Lock Held: {{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} ", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - }, - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "sum by(namespace,app_kubernetes_io_instance,pod) (pg_locks_detail_count{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\",granted=\"0\"})", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "Lock Awaited: {{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} ", - "metric": "", - "range": true, - "refId": "B", - "step": 20 - } - ], - "title": "Locks Held or Awaited", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": "s" - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 102 - }, - "id": 497, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "max by(namespace,app_kubernetes_io_instance,pod) (max_over_time(pg_locks_detail_max_wait_age_seconds{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}[$__interval]))", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} ", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Max Lock Wait Time (Version >= 14)", - "type": "timeseries" - } - ], - "title": "Locks", - "type": "row" - }, - { - "collapsed": true, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 38 - }, - "id": 503, - "panels": [ - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 111 - }, - "id": 385, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_wal_wal_records_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "WAL Records Generated Per Second", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 111 - }, - "id": 505, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_wal_wal_fpi_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "WAL Full Page Images Generated Per Second", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": "bytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 119 - }, - "id": 506, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_wal_wal_bytes_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "WAL Generated Size Per Second", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 119 - }, - "id": 507, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_wal_wal_buffers_full_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "WAL Buffer Full Per Second", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": "bytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 127 - }, - "id": 508, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_wal_wal_write_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "XLogWrite: {{namespace}} | {{app_kubernetes_io_instance}} | {{pod}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - }, - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_wal_wal_sync_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "XLogFsync: {{namespace}} | {{app_kubernetes_io_instance}} | {{pod}}", - "metric": "", - "range": true, - "refId": "B", - "step": 20 - } - ], - "title": "WAL Written To Disk Per Second", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": "s" - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 127 - }, - "id": 509, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_wal_wal_write_time_seconds_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "XLogWrite: {{namespace}} | {{app_kubernetes_io_instance}} | {{pod}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - }, - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_wal_wal_sync_time_seconds_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "XLogFsync: {{namespace}} | {{app_kubernetes_io_instance}} | {{pod}}", - "metric": "", - "range": true, - "refId": "B", - "step": 20 - } - ], - "title": "Time of WAL Written To Disk Per Second", - "type": "timeseries" - } - ], - "title": "WAL (Version >= 14)", - "type": "row" - }, - { - "collapsed": true, - "datasource": { - "uid": "$datasource" - }, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 39 - }, - "id": 383, - "panels": [ - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 40 - }, - "id": 386, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_database_conflicts_confl_bufferpin_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "Pinned buffers: {{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{datname}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - }, - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_database_conflicts_confl_deadlock_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "Deadlocks: {{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{datname}}", - "metric": "", - "range": true, - "refId": "B", - "step": 20 - }, - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_database_conflicts_confl_lock_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "Lock timeouts: {{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{datname}}", - "metric": "", - "range": true, - "refId": "C", - "step": 20 - }, - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_database_conflicts_confl_snapshot_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "Old snapshots: {{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{datname}}", - "metric": "", - "range": true, - "refId": "D", - "step": 20 - }, - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_database_conflicts_confl_tablespace_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "Dropped tablespaces: {{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{datname}}", - "metric": "", - "range": true, - "refId": "E", - "step": 20 - } - ], - "title": "Canceled Queries Per Second", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 40 - }, - "id": 504, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_database_conflicts_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{datname}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Conflicts Per Second", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 48 - }, - "id": 384, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_database_deadlocks_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{datname}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Deadlocks Per Second", - "type": "timeseries" - } - ], - "targets": [ - { - "datasource": { - "uid": "$datasource" - }, - "refId": "A" - } - ], - "title": "Conflicts & Deadlocks", - "type": "row" - }, - { - "collapsed": true, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 40 - }, - "id": 400, - "panels": [ - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 153 - }, - "id": 488, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_database_blks_hit_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{datname}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Buffer Cache Read Per Second", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 153 - }, - "id": 409, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_database_blks_read_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{datname}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Disk Block Read Per Second", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": "ms" - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 161 - }, - "id": 401, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_database_blk_read_time_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{datname}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Block Read Time", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": "ms" - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 161 - }, - "id": 402, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "rate(pg_stat_database_blk_write_time_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"}[$__rate_interval])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{datname}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Block Write Time", - "type": "timeseries" - } - ], - "title": "Shared Buffers & Blocks", - "type": "row" - }, - { - "collapsed": true, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 41 - }, - "id": 417, - "panels": [ - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": "bytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 170 - }, - "id": 418, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "pg_database_size_bytes{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",datname=~\"$database\",job=\"$job\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} | {{datname}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Disk Size", - "type": "timeseries" - } - ], - "title": "Database Size", - "type": "row" - }, - { - "collapsed": true, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 42 - }, - "id": 459, - "panels": [ - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 179 - }, - "id": 486, - "links": [], - "options": { - "legend": { - "calcs": [], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "sum(pg_replication_is_master{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}) by(namespace,app_kubernetes_io_instance,pod)", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} ", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Master Role", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": "bytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 179 - }, - "id": 484, - "links": [], - "options": { - "legend": { - "calcs": [], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "sum (pg_replication_slots_pg_wal_lsn_diff{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",job=\"$job\"}) by(namespace,app_kubernetes_io_instance,slot_name)", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{slot_name}} ", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Replication Lag Size", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": "s" - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 187 - }, - "id": 483, - "links": [], - "options": { - "legend": { - "calcs": [], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "sum(pg_replication_lag{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}) by(namespace, app_kubernetes_io_instance,pod)", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{pod}} ", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Replication Lag Time", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 2, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "auto", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green" - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 187 - }, - "id": 463, - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "single", - "sort": "none" - } - }, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "sum(pg_replication_slots_active{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",job=\"$job\"}) by(namespace,app_kubernetes_io_instance)", - "interval": "", - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}}", - "range": true, - "refId": "A" - } - ], - "title": "Replication Slots", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": 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": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 195 - }, - "id": 485, - "links": [], - "options": { - "legend": { - "calcs": [], - "displayMode": "table", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "2m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "(time() - sum(pg_stat_replication_reply_time{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",job=\"$job\"}) by(namespace,app_kubernetes_io_instance,application_name)) < bool 2000", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}} | {{application_name}} ", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Replication Status", - "type": "timeseries" - } - ], - "title": "Replication", - "type": "row" - } - ], - "refresh": false, - "schemaVersion": 37, - "style": "dark", - "tags": [ - "postgres", - "db", - "detail", - "kubeblocks" - ], - "templating": { - "list": [ - { - "current": { - "selected": false, - "text": "default", - "value": "default" - }, - "hide": 0, - "includeAll": false, - "label": "data source", - "multi": false, - "name": "datasource", - "options": [], - "query": "prometheus", - "queryValue": "", - "refresh": 1, - "regex": "", - "skipUrlSync": false, - "type": "datasource" - }, - { - "allValue": ".+", - "current": { - "selected": true, - "text": [ - "default" - ], - "value": [ - "default" - ] - }, - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "definition": "label_values(pg_up{job=\"$job\"}, namespace)", - "hide": 2, - "includeAll": true, - "label": "namespace", - "multi": true, - "name": "namespace", - "options": [], - "query": { - "query": "label_values(pg_up{job=\"$job\"}, namespace)", - "refId": "StandardVariableQuery" - }, - "refresh": 1, - "regex": "", - "skipUrlSync": false, - "sort": 5, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false - }, - { - "allValue": ".+", - "current": { - "selected": true, - "text": [ - "pg12multi" - ], - "value": [ - "pg12multi" - ] - }, - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "definition": "label_values(pg_up{job=\"$job\"}, app_kubernetes_io_instance)", - "hide": 2, - "includeAll": true, - "label": "cluster", - "multi": true, - "name": "cluster", - "options": [], - "query": { - "query": "label_values(pg_up{job=\"$job\"}, app_kubernetes_io_instance)", - "refId": "StandardVariableQuery" - }, - "refresh": 1, - "regex": "", - "skipUrlSync": false, - "sort": 5, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false - }, - { - "allValue": ".+", - "current": { - "selected": true, - "text": [ - "All" - ], - "value": [ - "$__all" - ] - }, - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "definition": "label_values(pg_up{job=\"$job\",namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\"}, pod)", - "hide": 0, - "includeAll": true, - "label": "instance", - "multi": true, - "name": "instance", - "options": [], - "query": { - "query": "label_values(pg_up{job=\"$job\",namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\"}, pod)", - "refId": "StandardVariableQuery" - }, - "refresh": 2, - "regex": "", - "skipUrlSync": false, - "sort": 5, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false - }, - { - "allValue": ".+", - "current": { - "selected": true, - "text": [ - "All" - ], - "value": [ - "$__all" - ] - }, - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "definition": "label_values(pg_database_size_bytes{job=\"$job\",namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\"}, datname)", - "hide": 0, - "includeAll": true, - "label": "database", - "multi": true, - "name": "database", - "options": [], - "query": { - "query": "label_values(pg_database_size_bytes{job=\"$job\",namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\"}, datname)", - "refId": "StandardVariableQuery" - }, - "refresh": 2, - "regex": "", - "skipUrlSync": false, - "sort": 5, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false - }, - { - "current": { - "selected": true, - "text": "oteld-app-metrics", - "value": "oteld-app-metrics" - }, - "hide": 0, - "includeAll": false, - "label": "job", - "multi": false, - "name": "job", - "options": [ - { - "selected": true, - "text": "oteld-app-metrics", - "value": "oteld-app-metrics" - } - ], - "query": "oteld-app-metrics", - "queryValue": "", - "skipUrlSync": false, - "type": "custom" - } - ] - }, - "time": { - "from": "now-30m", - "to": "now" - }, - "timepicker": { - "collapse": false, - "enable": true, - "hidden": false, - "notice": false, - "now": true, - "refresh_intervals": [ - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ], - "status": "Stable", - "time_options": [ - "5m", - "15m", - "1h", - "6h", - "12h", - "24h", - "2d", - "7d", - "30d" - ], - "type": "timepicker" - }, - "timezone": "", - "title": "Kubeblocks / PostgreSQL Detail", - "uid": "kubeblocks-postgresql-detail", - "version": 1, - "weekStart": "" -} diff --git a/deploy/helm/dashboards/kubeblocks-postgresql-overview.json b/deploy/helm/dashboards/kubeblocks-postgresql-overview.json deleted file mode 100644 index 34fd40df490..00000000000 --- a/deploy/helm/dashboards/kubeblocks-postgresql-overview.json +++ /dev/null @@ -1,2638 +0,0 @@ -{ - "annotations": { - "list": [ - { - "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": "", - "editable": true, - "fiscalYearStartMonth": 0, - "gnetId": 11323, - "graphTooltip": 0, - "id": 19, - "links": [ - { - "asDropdown": false, - "icon": "cloud", - "includeVars": false, - "keepTime": false, - "tags": [], - "targetBlank": true, - "title": "ApeCloud", - "tooltip": "Improved productivity, cost-efficiency and business continuity.", - "type": "link", - "url": "https://kubeblocks.io/" - }, - { - "asDropdown": false, - "icon": "external link", - "includeVars": false, - "keepTime": false, - "tags": [], - "targetBlank": true, - "title": "KubeBlocks", - "tooltip": "An open-source and cloud-neutral DBaaS with Kubernetes.", - "type": "link", - "url": "https://github.com/apecloud/kubeblocks" - } - ], - "liveNow": false, - "panels": [ - { - "collapsed": false, - "datasource": { - "uid": "$datasource" - }, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 0 - }, - "id": 382, - "panels": [], - "targets": [ - { - "datasource": { - "uid": "$datasource" - }, - "refId": "A" - } - ], - "title": "Summary", - "type": "row" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "decimals": 0, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 2, - "x": 0, - "y": 1 - }, - "id": 424, - "interval": "", - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "value", - "fieldOptions": { - "calcs": [ - "lastNotNull" - ] - }, - "graphMode": "area", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "count(sum by(namespace,app_kubernetes_io_instance)(pg_up{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"})) or vector(0)", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{label_name}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Clusters", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "decimals": 0, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 2, - "x": 2, - "y": 1 - }, - "id": 515, - "interval": "", - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "value", - "fieldOptions": { - "calcs": [ - "lastNotNull" - ] - }, - "graphMode": "area", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "count(sum by(node)(pg_up{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"})) or vector(0)", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "__auto", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Nodes", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "decimals": 0, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 4, - "y": 1 - }, - "id": 421, - "interval": "", - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "value", - "fieldOptions": { - "calcs": [ - "lastNotNull" - ] - }, - "graphMode": "area", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "count(pg_up{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"} > 0) or vector(0)", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "__auto", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Running Instances", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "decimals": 0, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - }, - { - "color": "dark-red", - "value": 0.5 - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 7, - "y": 1 - }, - "id": 420, - "interval": "", - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "value", - "fieldOptions": { - "calcs": [ - "lastNotNull" - ] - }, - "graphMode": "area", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "exemplar": false, - "expr": "count(pg_up{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"} <= 0) or vector(0)", - "format": "time_series", - "instant": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "__auto", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Down Instances", - "transformations": [], - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "decimals": 2, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 2, - "x": 10, - "y": 1 - }, - "id": 443, - "interval": "", - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "value", - "fieldOptions": { - "calcs": [ - "lastNotNull" - ] - }, - "graphMode": "area", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "sum(rate(pg_stat_statements_stats_calls_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}[$__rate_interval])) or vector(0)", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{label_name}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Total Qps", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "align": "center", - "displayMode": "color-text", - "inspect": false - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - } - }, - "overrides": [ - { - "matcher": { - "id": "byName", - "options": "cluster" - }, - "properties": [ - { - "id": "custom.displayMode", - "value": "color-text" - }, - { - "id": "custom.filterable", - "value": true - }, - { - "id": "links", - "value": [ - { - "targetBlank": true, - "title": "PostgreSQL Cluster: ${__data.fields.namespace} | ${__data.fields.cluster}", - "url": "/d/kubeblocks-postgresql-detail/kubeblocks-postgresql-detail?orgId=1&var-datasource=default&var-namespace=${__data.fields.namespace}&var-cluster=${__data.fields.cluster}&var-instance=All&var-database=All" - } - ] - } - ] - } - ] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 1 - }, - "id": 521, - "options": { - "footer": { - "enablePagination": false, - "fields": "", - "reducer": [ - "sum" - ], - "show": false - }, - "showHeader": true - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "exemplar": false, - "expr": "count by (namespace, app_kubernetes_io_instance) (pg_up{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"})", - "format": "table", - "instant": true, - "legendFormat": "__auto", - "range": false, - "refId": "A" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "exemplar": false, - "expr": "count by (app_kubernetes_io_instance) (pg_up{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"} > 0)", - "format": "table", - "hide": false, - "instant": true, - "legendFormat": "__auto", - "range": false, - "refId": "B" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "exemplar": false, - "expr": "count by (app_kubernetes_io_instance) (count by (app_kubernetes_io_instance,node) (pg_up{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}))", - "format": "table", - "hide": false, - "instant": true, - "legendFormat": "__auto", - "range": false, - "refId": "C" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "exemplar": false, - "expr": "count by(short_version,app_kubernetes_io_instance)(pg_static{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"})", - "format": "table", - "hide": false, - "instant": true, - "legendFormat": "__auto", - "range": false, - "refId": "D" - } - ], - "title": "Cluster List", - "transformations": [ - { - "id": "joinByField", - "options": { - "byField": "app_kubernetes_io_instance", - "mode": "outer" - } - }, - { - "id": "organize", - "options": { - "excludeByName": { - "Time 1": true, - "Time 2": true, - "Time 3": true, - "Time 4": true, - "Value #D": true, - "apps_kubeblocks_io_component_name": true, - "node": true, - "pod": true - }, - "indexByName": { - "Time 1": 2, - "Time 2": 5, - "Time 3": 7, - "Time 4": 10, - "Value #A": 4, - "Value #B": 6, - "Value #C": 9, - "Value #D": 8, - "app_kubernetes_io_instance": 1, - "namespace": 0, - "short_version": 3 - }, - "renameByName": { - "Value #A": "total instances", - "Value #B": "running instances", - "Value #C": "node num", - "app_kubernetes_io_instance": "cluster", - "pod": "", - "short_version": "version" - } - } - } - ], - "type": "table" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "decimals": 0, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "percentunit" - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 0, - "y": 5 - }, - "id": 516, - "interval": "", - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "value", - "fieldOptions": { - "calcs": [ - "lastNotNull" - ] - }, - "graphMode": "area", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "sum(rate(k8s_pod_cpu_time_seconds_total{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"postgresql\",k8s_namespace_name=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",k8s_pod_name=~\"$instance\"}[$__rate_interval]))", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "__auto", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "CPU Usage (Cores)", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 3, - "y": 5 - }, - "id": 517, - "interval": "", - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "value", - "fieldOptions": { - "calcs": [ - "lastNotNull" - ] - }, - "graphMode": "area", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "sum(k8s_pod_cpu_limit{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"postgresql\",k8s_namespace_name=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",k8s_pod_name=~\"$instance\"})", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "__auto", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "CPU Limit (Cores)", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "bytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 2, - "x": 6, - "y": 5 - }, - "id": 518, - "interval": "", - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "value", - "fieldOptions": { - "calcs": [ - "lastNotNull" - ] - }, - "graphMode": "area", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "sum(k8s_pod_memory_working_set_bytes{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"postgresql\",k8s_namespace_name=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",k8s_pod_name=~\"$instance\"})", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "__auto", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Memory Usage", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "bytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 2, - "x": 8, - "y": 5 - }, - "id": 519, - "interval": "", - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "value", - "fieldOptions": { - "calcs": [ - "lastNotNull" - ] - }, - "graphMode": "area", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "expr": "sum(k8s_pod_memory_limit_bytes{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"postgresql\",k8s_namespace_name=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",k8s_pod_name=~\"$instance\"})", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "__auto", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Memory Limit", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "decimals": 2, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 2, - "x": 10, - "y": 5 - }, - "id": 442, - "interval": "", - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "value", - "fieldOptions": { - "calcs": [ - "lastNotNull" - ] - }, - "graphMode": "area", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "exemplar": false, - "expr": "sum(rate(pg_stat_database_xact_commit_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}[$__rate_interval]) + rate(pg_stat_database_xact_rollback_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}[$__rate_interval])) or vector(0)", - "format": "time_series", - "instant": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{label_name}}", - "metric": "", - "range": true, - "refId": "A", - "step": 20 - } - ], - "title": "Total Tps", - "type": "stat" - }, - { - "collapsed": false, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 9 - }, - "id": 523, - "panels": [], - "title": "Clusters", - "type": "row" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "custom": { - "align": "center", - "displayMode": "auto", - "inspect": false - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "short" - }, - "overrides": [ - { - "matcher": { - "id": "byName", - "options": "cpu usage (cores)" - }, - "properties": [ - { - "id": "custom.displayMode", - "value": "color-text" - }, - { - "id": "unit", - "value": "percentunit" - } - ] - } - ] - }, - "gridPos": { - "h": 7, - "w": 8, - "x": 0, - "y": 10 - }, - "id": 528, - "interval": "", - "links": [], - "maxDataPoints": 100, - "options": { - "footer": { - "fields": "", - "reducer": [ - "sum" - ], - "show": false - }, - "showHeader": true - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "exemplar": false, - "expr": "topk(10, sum by(k8s_namespace_name,app_kubernetes_io_instance) (rate(k8s_pod_cpu_time_seconds_total{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"postgresql\",k8s_namespace_name=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",k8s_pod_name=~\"$instance\"}[$__rate_interval])))", - "format": "table", - "instant": true, - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}}", - "metric": "", - "range": false, - "refId": "A", - "step": 20 - } - ], - "title": "Top10 CPU Usage", - "transformations": [ - { - "id": "organize", - "options": { - "excludeByName": { - "Time": true - }, - "indexByName": { - "Time": 0, - "Value": 3, - "app_kubernetes_io_instance": 2, - "k8s_namespace_name": 1 - }, - "renameByName": { - "Value": "cpu usage (cores)", - "app_kubernetes_io_instance": "cluster", - "k8s_namespace_name": "namespace" - } - } - } - ], - "type": "table" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "custom": { - "align": "center", - "displayMode": "auto", - "inspect": false - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "short" - }, - "overrides": [ - { - "matcher": { - "id": "byName", - "options": "max cpu usage ratio" - }, - "properties": [ - { - "id": "custom.displayMode", - "value": "color-text" - }, - { - "id": "unit", - "value": "percentunit" - } - ] - } - ] - }, - "gridPos": { - "h": 7, - "w": 8, - "x": 8, - "y": 10 - }, - "id": 427, - "interval": "", - "links": [], - "maxDataPoints": 100, - "options": { - "footer": { - "fields": "", - "reducer": [ - "sum" - ], - "show": false - }, - "showHeader": true - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "exemplar": false, - "expr": "topk(10, max by(k8s_namespace_name,app_kubernetes_io_instance) (rate(k8s_pod_cpu_time_seconds_total{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"postgresql\",k8s_namespace_name=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",k8s_pod_name=~\"$instance\"}[$__rate_interval]) / k8s_pod_cpu_limit{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"postgresql\",k8s_namespace_name=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",k8s_pod_name=~\"$instance\"}))", - "format": "table", - "instant": true, - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}}", - "metric": "", - "range": false, - "refId": "A", - "step": 20 - } - ], - "title": "Top10 Max CPU Usage Ratio", - "transformations": [ - { - "id": "organize", - "options": { - "excludeByName": { - "Time": true - }, - "indexByName": { - "Time": 0, - "Value": 3, - "app_kubernetes_io_instance": 2, - "k8s_namespace_name": 1 - }, - "renameByName": { - "Value": "max cpu usage ratio", - "app_kubernetes_io_instance": "cluster", - "k8s_namespace_name": "namespace" - } - } - } - ], - "type": "table" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "custom": { - "align": "center", - "displayMode": "auto", - "inspect": false - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "short" - }, - "overrides": [ - { - "matcher": { - "id": "byName", - "options": "memory usage" - }, - "properties": [ - { - "id": "custom.displayMode", - "value": "color-text" - }, - { - "id": "unit", - "value": "bytes" - } - ] - } - ] - }, - "gridPos": { - "h": 7, - "w": 8, - "x": 16, - "y": 10 - }, - "id": 524, - "interval": "", - "links": [], - "maxDataPoints": 100, - "options": { - "footer": { - "fields": "", - "reducer": [ - "sum" - ], - "show": false - }, - "showHeader": true - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "exemplar": false, - "expr": "topk(10, sum by(k8s_namespace_name,app_kubernetes_io_instance) (k8s_pod_memory_working_set_bytes{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"postgresql\",k8s_namespace_name=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",k8s_pod_name=~\"$instance\"}))", - "format": "table", - "instant": true, - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}}", - "metric": "", - "range": false, - "refId": "A", - "step": 20 - } - ], - "title": "Top10 Memory Usage", - "transformations": [ - { - "id": "organize", - "options": { - "excludeByName": { - "Time": true - }, - "indexByName": { - "Time": 0, - "Value": 3, - "app_kubernetes_io_instance": 2, - "k8s_namespace_name": 1 - }, - "renameByName": { - "Value": "memory usage", - "app_kubernetes_io_instance": "cluster", - "k8s_namespace_name": "namespace" - } - } - } - ], - "type": "table" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "custom": { - "align": "center", - "displayMode": "auto", - "inspect": false - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "percentunit" - }, - "overrides": [ - { - "matcher": { - "id": "byName", - "options": "max memory usage ratio" - }, - "properties": [ - { - "id": "custom.displayMode", - "value": "color-text" - } - ] - } - ] - }, - "gridPos": { - "h": 7, - "w": 8, - "x": 0, - "y": 17 - }, - "id": 529, - "interval": "", - "links": [], - "maxDataPoints": 100, - "options": { - "footer": { - "fields": "", - "reducer": [ - "sum" - ], - "show": false - }, - "showHeader": true - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "exemplar": false, - "expr": "topk(10, max by(k8s_namespace_name,app_kubernetes_io_instance) (k8s_pod_memory_working_set_bytes{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"postgresql\",k8s_namespace_name=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",k8s_pod_name=~\"$instance\"} / k8s_pod_memory_limit_bytes{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"postgresql\",k8s_namespace_name=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",k8s_pod_name=~\"$instance\"}))", - "format": "table", - "instant": true, - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}}", - "metric": "", - "range": false, - "refId": "A", - "step": 20 - } - ], - "title": "Top10 Max Memory Usage Ratio", - "transformations": [ - { - "id": "organize", - "options": { - "excludeByName": { - "Time": true - }, - "indexByName": { - "Time": 0, - "Value": 3, - "app_kubernetes_io_instance": 2, - "k8s_namespace_name": 1 - }, - "renameByName": { - "Value": "max memory usage ratio", - "app_kubernetes_io_instance": "cluster", - "k8s_namespace_name": "namespace" - } - } - } - ], - "type": "table" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "custom": { - "align": "center", - "displayMode": "auto", - "inspect": false - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "short" - }, - "overrides": [ - { - "matcher": { - "id": "byName", - "options": "max volume usage ratio" - }, - "properties": [ - { - "id": "custom.displayMode", - "value": "color-text" - }, - { - "id": "unit", - "value": "percentunit" - } - ] - } - ] - }, - "gridPos": { - "h": 7, - "w": 8, - "x": 8, - "y": 17 - }, - "id": 527, - "interval": "", - "links": [], - "maxDataPoints": 100, - "options": { - "footer": { - "fields": "", - "reducer": [ - "sum" - ], - "show": false - }, - "showHeader": true - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "exemplar": false, - "expr": "topk(10, max by(k8s_namespace_name,app_kubernetes_io_instance) (1 - (k8s_volume_available_bytes{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"postgresql\",k8s_volume_type=~\"emptyDir|ephemeral-storage|persistentVolumeClaim|hostPath\",k8s_namespace_name=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",k8s_pod_name=~\"$instance\"}/k8s_volume_capacity_bytes{app_kubernetes_io_managed_by=\"kubeblocks\",app_kubernetes_io_name=\"postgresql\",k8s_volume_type=~\"emptyDir|ephemeral-storage|persistentVolumeClaim|hostPath\",k8s_namespace_name=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",k8s_pod_name=~\"$instance\"})))", - "format": "table", - "instant": true, - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}}", - "metric": "", - "range": false, - "refId": "A", - "step": 20 - } - ], - "title": "Top10 Max Volumes Usage Ratio", - "transformations": [ - { - "id": "organize", - "options": { - "excludeByName": { - "Time": true, - "k8s_pod_name": false - }, - "indexByName": { - "Time": 0, - "Value": 4, - "app_kubernetes_io_instance": 2, - "k8s_namespace_name": 1, - "k8s_pod_name": 3 - }, - "renameByName": { - "Value": "max volume usage ratio", - "app_kubernetes_io_instance": "cluster", - "k8s_namespace_name": "namespace", - "k8s_pod_name": "instance" - } - } - } - ], - "type": "table" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "custom": { - "align": "center", - "displayMode": "auto", - "inspect": false - }, - "decimals": 2, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "short" - }, - "overrides": [ - { - "matcher": { - "id": "byName", - "options": "qps" - }, - "properties": [ - { - "id": "custom.displayMode", - "value": "lcd-gauge" - } - ] - } - ] - }, - "gridPos": { - "h": 7, - "w": 8, - "x": 16, - "y": 17 - }, - "id": 438, - "interval": "", - "links": [], - "maxDataPoints": 100, - "options": { - "footer": { - "fields": "", - "reducer": [ - "sum" - ], - "show": false - }, - "showHeader": true - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "exemplar": false, - "expr": "topk(10, sum by(namespace,app_kubernetes_io_instance) (rate(pg_stat_statements_stats_calls_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}[$__rate_interval])))", - "format": "table", - "instant": true, - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}}", - "metric": "", - "range": false, - "refId": "A", - "step": 20 - } - ], - "title": "Top10 Qps", - "transformations": [ - { - "id": "organize", - "options": { - "excludeByName": { - "Time": true - }, - "indexByName": { - "Time": 0, - "Value": 3, - "app_kubernetes_io_instance": 2, - "namespace": 1 - }, - "renameByName": { - "Value": "qps", - "app_kubernetes_io_instance": "cluster" - } - } - } - ], - "type": "table" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "custom": { - "align": "center", - "displayMode": "auto", - "inspect": false - }, - "decimals": 2, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "short" - }, - "overrides": [ - { - "matcher": { - "id": "byName", - "options": "tps" - }, - "properties": [ - { - "id": "custom.displayMode", - "value": "lcd-gauge" - } - ] - } - ] - }, - "gridPos": { - "h": 7, - "w": 8, - "x": 0, - "y": 24 - }, - "id": 530, - "interval": "", - "links": [], - "maxDataPoints": 100, - "options": { - "footer": { - "fields": "", - "reducer": [ - "sum" - ], - "show": false - }, - "showHeader": true - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "exemplar": false, - "expr": "topk(10, sum by(namespace,app_kubernetes_io_instance) (rate(pg_stat_database_xact_commit_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}[$__rate_interval]) + rate(pg_stat_database_xact_rollback_total{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}[$__rate_interval])))", - "format": "table", - "instant": true, - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}}", - "metric": "", - "range": false, - "refId": "A", - "step": 20 - } - ], - "title": "Top10 Tps", - "transformations": [ - { - "id": "organize", - "options": { - "excludeByName": { - "Time": true - }, - "indexByName": { - "Time": 0, - "Value": 3, - "app_kubernetes_io_instance": 2, - "namespace": 1 - }, - "renameByName": { - "Value": "tps", - "app_kubernetes_io_instance": "cluster" - } - } - } - ], - "type": "table" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "custom": { - "align": "center", - "displayMode": "auto", - "inspect": false - }, - "decimals": 2, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "short" - }, - "overrides": [ - { - "matcher": { - "id": "byName", - "options": "connections" - }, - "properties": [ - { - "id": "custom.displayMode", - "value": "lcd-gauge" - } - ] - } - ] - }, - "gridPos": { - "h": 7, - "w": 8, - "x": 8, - "y": 24 - }, - "id": 429, - "interval": "", - "links": [], - "maxDataPoints": 100, - "options": { - "footer": { - "fields": "", - "reducer": [ - "sum" - ], - "show": false - }, - "showHeader": true - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "exemplar": false, - "expr": "topk(10, sum by(namespace,app_kubernetes_io_instance) (pg_stat_database_numbackends{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}))", - "format": "table", - "instant": true, - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}}", - "metric": "", - "range": false, - "refId": "A", - "step": 20 - } - ], - "title": "Top10 Connections", - "transformations": [ - { - "id": "organize", - "options": { - "excludeByName": { - "Time": true - }, - "indexByName": { - "Time": 0, - "Value": 3, - "app_kubernetes_io_instance": 2, - "namespace": 1 - }, - "renameByName": { - "Value": "connections", - "app_kubernetes_io_instance": "cluster", - "namespace": "namespace" - } - } - } - ], - "type": "table" - }, - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "custom": { - "align": "center", - "displayMode": "auto", - "inspect": false - }, - "decimals": 2, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - }, - "unit": "short" - }, - "overrides": [ - { - "matcher": { - "id": "byName", - "options": "size" - }, - "properties": [ - { - "id": "unit", - "value": "bytes" - }, - { - "id": "custom.displayMode", - "value": "lcd-gauge" - } - ] - } - ] - }, - "gridPos": { - "h": 7, - "w": 8, - "x": 16, - "y": 24 - }, - "id": 440, - "interval": "", - "links": [], - "maxDataPoints": 100, - "options": { - "footer": { - "fields": "", - "reducer": [ - "sum" - ], - "show": false - }, - "showHeader": true - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "exemplar": false, - "expr": "topk(10, sum by(namespace,app_kubernetes_io_instance) (pg_database_size_bytes{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"}))", - "format": "table", - "instant": true, - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{namespace}} | {{app_kubernetes_io_instance}}", - "metric": "", - "range": false, - "refId": "A", - "step": 20 - } - ], - "title": "Top10 Database Size", - "transformations": [ - { - "id": "organize", - "options": { - "excludeByName": { - "Time": true - }, - "indexByName": { - "Time": 0, - "Value": 3, - "app_kubernetes_io_instance": 2, - "namespace": 1 - }, - "renameByName": { - "Value": "size", - "app_kubernetes_io_instance": "cluster", - "namespace": "namespace" - } - } - } - ], - "type": "table" - }, - { - "collapsed": true, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 31 - }, - "id": 526, - "panels": [ - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "custom": { - "align": "center", - "displayMode": "auto", - "filterable": false, - "inspect": false - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-blue", - "value": null - } - ] - } - }, - "overrides": [ - { - "matcher": { - "id": "byName", - "options": "instance" - }, - "properties": [ - { - "id": "links", - "value": [ - { - "targetBlank": true, - "title": "PostgreSQL Instance: ${__data.fields.namespace} | ${__data.fields.cluster} | ${__data.fields.instance}", - "url": "/d/kubeletstats/kubelet-stats?orgId=1&var-datasource=default&var-node=All&var-cluster=${__data.fields.cluster}&var-pod=${__data.fields.instance}" - } - ] - }, - { - "id": "custom.align", - "value": "center" - }, - { - "id": "custom.filterable", - "value": true - }, - { - "id": "custom.displayMode", - "value": "color-text" - } - ] - }, - { - "matcher": { - "id": "byName", - "options": "uptime" - }, - "properties": [ - { - "id": "unit", - "value": "s" - }, - { - "id": "custom.displayMode", - "value": "auto" - } - ] - }, - { - "matcher": { - "id": "byName", - "options": "namespace" - }, - "properties": [ - { - "id": "custom.filterable", - "value": true - } - ] - }, - { - "matcher": { - "id": "byName", - "options": "cluster" - }, - "properties": [ - { - "id": "custom.filterable", - "value": true - }, - { - "id": "links", - "value": [ - { - "targetBlank": true, - "title": "PostgreSQL Cluster: ${__data.fields.namespace} | ${__data.fields.cluster}", - "url": "/d/kubeblocks-postgresql-detail/kubeblocks-postgresql-detail?orgId=1&var-datasource=default&var-namespace=${__data.fields.namespace}&var-cluster=${__data.fields.cluster}&var-instance=All&var-database=All" - } - ] - }, - { - "id": "custom.displayMode", - "value": "color-text" - } - ] - }, - { - "matcher": { - "id": "byName", - "options": "database size" - }, - "properties": [ - { - "id": "unit", - "value": "bytes" - } - ] - }, - { - "matcher": { - "id": "byName", - "options": "status" - }, - "properties": [ - { - "id": "mappings", - "value": [ - { - "options": { - "0": { - "color": "dark-yellow", - "index": 1, - "text": "replica" - }, - "1": { - "color": "green", - "index": 0, - "text": "primary" - } - }, - "type": "value" - } - ] - }, - { - "id": "custom.displayMode", - "value": "color-background" - } - ] - } - ] - }, - "gridPos": { - "h": 6, - "w": 24, - "x": 0, - "y": 32 - }, - "id": 428, - "interval": "", - "links": [], - "maxDataPoints": 100, - "options": { - "footer": { - "enablePagination": false, - "fields": "", - "reducer": [ - "sum" - ], - "show": false - }, - "showHeader": true, - "sortBy": [ - { - "desc": true, - "displayName": "uptime" - } - ] - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "exemplar": false, - "expr": "sum by(namespace,app_kubernetes_io_instance,pod) (pg_up{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"})", - "format": "table", - "instant": true, - "interval": "", - "intervalFactor": 1, - "legendFormat": "__auto", - "metric": "", - "range": false, - "refId": "A", - "step": 20 - }, - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "exemplar": false, - "expr": "avg by(namespace,app_kubernetes_io_instance,pod) (time() - pg_postmaster_start_time_seconds{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"})", - "format": "table", - "hide": false, - "instant": true, - "interval": "", - "intervalFactor": 1, - "legendFormat": "__auto", - "metric": "", - "range": false, - "refId": "B", - "step": 20 - }, - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "exemplar": false, - "expr": "sum by(namespace,app_kubernetes_io_instance,pod) (pg_database_size_bytes{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"})", - "format": "table", - "hide": false, - "instant": true, - "interval": "", - "intervalFactor": 1, - "legendFormat": "__auto", - "metric": "", - "range": false, - "refId": "C", - "step": 20 - }, - { - "calculatedInterval": "10m", - "datasource": { - "uid": "$datasource" - }, - "datasourceErrors": {}, - "editorMode": "code", - "errors": {}, - "exemplar": false, - "expr": "sum by(namespace,app_kubernetes_io_instance,pod) (pg_replication_is_master{namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\",job=\"$job\"})", - "format": "table", - "hide": false, - "instant": true, - "interval": "", - "intervalFactor": 1, - "legendFormat": "__auto", - "metric": "", - "range": false, - "refId": "D", - "step": 20 - } - ], - "title": "Instance Details", - "transformations": [ - { - "id": "joinByField", - "options": { - "byField": "pod", - "mode": "outer" - } - }, - { - "id": "organize", - "options": { - "excludeByName": { - "Time 1": true, - "Time 2": true, - "Time 3": true, - "Time 4": true, - "Value #A": true, - "app_kubernetes_io_instance 2": true, - "app_kubernetes_io_instance 3": true, - "app_kubernetes_io_instance 4": true, - "namespace 2": true, - "namespace 3": true, - "namespace 4": true - }, - "indexByName": { - "Time 1": 3, - "Time 2": 5, - "Time 3": 10, - "Time 4": 14, - "Value #A": 4, - "Value #B": 9, - "Value #C": 13, - "Value #D": 8, - "app_kubernetes_io_instance 1": 1, - "app_kubernetes_io_instance 2": 6, - "app_kubernetes_io_instance 3": 11, - "app_kubernetes_io_instance 4": 15, - "namespace 1": 0, - "namespace 2": 7, - "namespace 3": 12, - "namespace 4": 16, - "pod": 2 - }, - "renameByName": { - "Value #B": "uptime", - "Value #C": "database size", - "Value #D": "status", - "app_kubernetes_io_instance 1": "cluster", - "namespace 1": "namespace", - "pod": "instance" - } - } - } - ], - "type": "table" - } - ], - "title": "Instances", - "type": "row" - } - ], - "refresh": false, - "schemaVersion": 37, - "style": "dark", - "tags": [ - "postgres", - "db", - "overview", - "kubeblocks" - ], - "templating": { - "list": [ - { - "current": { - "selected": false, - "text": "default", - "value": "default" - }, - "hide": 0, - "includeAll": false, - "label": "data source", - "multi": false, - "name": "datasource", - "options": [], - "query": "prometheus", - "queryValue": "", - "refresh": 1, - "regex": "", - "skipUrlSync": false, - "type": "datasource" - }, - { - "allValue": ".+", - "current": { - "selected": true, - "text": [ - "All" - ], - "value": [ - "$__all" - ] - }, - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "definition": "label_values(pg_up{job=\"$job\"}, namespace)", - "hide": 2, - "includeAll": true, - "label": "namespace", - "multi": true, - "name": "namespace", - "options": [], - "query": { - "query": "label_values(pg_up{job=\"$job\"}, namespace)", - "refId": "StandardVariableQuery" - }, - "refresh": 1, - "regex": "", - "skipUrlSync": false, - "sort": 5, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false - }, - { - "allValue": ".+", - "current": { - "selected": true, - "text": [ - "All" - ], - "value": [ - "$__all" - ] - }, - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "definition": "label_values(pg_up{job=\"$job\"}, app_kubernetes_io_instance)", - "hide": 2, - "includeAll": true, - "label": "cluster", - "multi": true, - "name": "cluster", - "options": [], - "query": { - "query": "label_values(pg_up{job=\"$job\"}, app_kubernetes_io_instance)", - "refId": "StandardVariableQuery" - }, - "refresh": 1, - "regex": "", - "skipUrlSync": false, - "sort": 5, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false - }, - { - "allValue": ".+", - "current": { - "selected": true, - "text": [ - "All" - ], - "value": [ - "$__all" - ] - }, - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "definition": "label_values(pg_up{job=\"$job\",namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\"}, pod)", - "hide": 2, - "includeAll": true, - "label": "instance", - "multi": true, - "name": "instance", - "options": [], - "query": { - "query": "label_values(pg_up{job=\"$job\",namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\"}, pod)", - "refId": "StandardVariableQuery" - }, - "refresh": 1, - "regex": "", - "skipUrlSync": false, - "sort": 5, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false - }, - { - "allValue": ".+", - "current": { - "selected": true, - "text": [ - "All" - ], - "value": [ - "$__all" - ] - }, - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "definition": "label_values(pg_database_size_bytes{job=\"$job\",namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\"}, datname)", - "hide": 2, - "includeAll": true, - "label": "database", - "multi": true, - "name": "database", - "options": [], - "query": { - "query": "label_values(pg_database_size_bytes{job=\"$job\",namespace=~\"$namespace\",app_kubernetes_io_instance=~\"$cluster\",pod=~\"$instance\"}, datname)", - "refId": "StandardVariableQuery" - }, - "refresh": 1, - "regex": "", - "skipUrlSync": false, - "sort": 5, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false - }, - { - "current": { - "selected": true, - "text": "oteld-app-metrics", - "value": "oteld-app-metrics" - }, - "hide": 0, - "includeAll": false, - "label": "job", - "multi": false, - "name": "job", - "options": [ - { - "selected": true, - "text": "oteld-app-metrics", - "value": "oteld-app-metrics" - } - ], - "query": "oteld-app-metrics", - "queryValue": "", - "skipUrlSync": false, - "type": "custom" - } - ] - }, - "time": { - "from": "now-30m", - "to": "now" - }, - "timepicker": { - "collapse": false, - "enable": true, - "hidden": false, - "notice": false, - "now": true, - "refresh_intervals": [ - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ], - "status": "Stable", - "time_options": [ - "5m", - "15m", - "1h", - "6h", - "12h", - "24h", - "2d", - "7d", - "30d" - ], - "type": "timepicker" - }, - "timezone": "", - "title": "Kubeblocks / PostgreSQL Overview", - "uid": "kubeblocks_postgresql_overview", - "version": 1, - "weekStart": "" -} diff --git a/deploy/helm/dashboards/loki.json b/deploy/helm/dashboards/loki.json deleted file mode 100644 index e7035aa6046..00000000000 --- a/deploy/helm/dashboards/loki.json +++ /dev/null @@ -1,2896 +0,0 @@ -{ - "annotations": { - "list": [ - { - "$$hashKey": "object:7", - "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": "Loki metrics via 2.0", - "editable": true, - "fiscalYearStartMonth": 0, - "gnetId": 13407, - "graphTooltip": 0, - "id": 16, - "links": [], - "liveNow": false, - "panels": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "description": "", - "gridPos": { - "h": 2, - "w": 24, - "x": 0, - "y": 0 - }, - "id": 21, - "interval": "", - "options": { - "code": { - "language": "plaintext", - "showLineNumbers": false, - "showMiniMap": false - }, - "content": "
\n \n Loki Instance Metrics\n
", - "mode": "html" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "loki_build_info", - "format": "table", - "instant": false, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "transparent": true, - "type": "text" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "decimals": 4, - "links": [], - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 3, - "x": 0, - "y": 2 - }, - "id": 75, - "interval": "", - "options": { - "colorMode": "value", - "graphMode": "none", - "justifyMode": "center", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "last" - ], - "fields": "/^instance$/", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "loki_build_info", - "format": "table", - "instant": false, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Loki Instance", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "decimals": 4, - "links": [], - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 3, - "x": 3, - "y": 2 - }, - "id": 59, - "interval": "", - "options": { - "colorMode": "value", - "graphMode": "none", - "justifyMode": "center", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "last" - ], - "fields": "/^version$/", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "loki_build_info", - "format": "table", - "instant": false, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Loki Version", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "description": "", - "fieldConfig": { - "defaults": { - "decimals": 4, - "links": [], - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 3, - "x": 6, - "y": 2 - }, - "id": 76, - "interval": "", - "options": { - "colorMode": "value", - "graphMode": "none", - "justifyMode": "center", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "last" - ], - "fields": "/^goos$/", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "loki_build_info", - "format": "table", - "instant": false, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Loki OS", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "decimals": 4, - "links": [], - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 3, - "x": 9, - "y": 2 - }, - "id": 77, - "interval": "", - "options": { - "colorMode": "value", - "graphMode": "none", - "justifyMode": "center", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "last" - ], - "fields": "/^goarch$/", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "loki_build_info", - "format": "table", - "instant": false, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Loki Arch", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "decimals": 0, - "links": [], - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 3, - "x": 12, - "y": 2 - }, - "id": 10, - "interval": "", - "options": { - "colorMode": "value", - "graphMode": "none", - "justifyMode": "center", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "last" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "sum(loki_log_messages_total)", - "instant": false, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Message Total", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "decimals": 2, - "links": [], - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 3, - "x": 15, - "y": 2 - }, - "id": 23, - "interval": "", - "options": { - "colorMode": "value", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "sum(loki_store_series_total)", - "instant": false, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Store Series Total", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "decimals": 2, - "links": [], - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "bytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 3, - "x": 18, - "y": 2 - }, - "id": 41, - "interval": "", - "options": { - "colorMode": "value", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "sum(loki_ingester_chunk_stored_bytes_total)", - "instant": true, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Store Chunks Total", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "links": [], - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 3, - "x": 21, - "y": 2 - }, - "id": 74, - "interval": "", - "options": { - "colorMode": "value", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "sum(loki_boltdb_shipper_compact_tables_operation_total)", - "instant": true, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Compact Tables Operation", - "type": "stat" - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 5, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 12, - "x": 0, - "y": 5 - }, - "hiddenSeries": false, - "id": 8, - "interval": "", - "legend": { - "avg": false, - "current": true, - "max": false, - "min": false, - "show": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": true, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "sum(irate(loki_log_messages_total[1m])) by (level)", - "interval": "", - "legendFormat": "{{ level }}", - "range": true, - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Messages Input", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:155", - "format": "short", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:156", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 0, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 12, - "x": 12, - "y": 5 - }, - "hiddenSeries": false, - "id": 12, - "interval": "", - "legend": { - "alignAsTable": true, - "avg": false, - "current": true, - "max": false, - "min": false, - "rightSide": true, - "show": true, - "sort": "current", - "sortDesc": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null as zero", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "histogram_quantile(0.95, sum(rate(loki_logql_querystats_latency_seconds_bucket[5m])) by (le,type))", - "interval": "", - "legendFormat": "{{ type }}", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "LogQL Latency", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:155", - "format": "s", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:156", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 0, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 12, - "x": 0, - "y": 11 - }, - "hiddenSeries": false, - "id": 11, - "interval": "", - "legend": { - "alignAsTable": true, - "avg": false, - "current": true, - "max": false, - "min": false, - "rightSide": true, - "show": true, - "sort": "current", - "sortDesc": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null as zero", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "histogram_quantile(0.95, sum(rate(loki_request_duration_seconds_bucket[5m])) by (le,route))", - "interval": "", - "legendFormat": "{{ route }}", - "range": true, - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "API Request Durations", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:155", - "format": "s", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:156", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 0, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 12, - "x": 12, - "y": 11 - }, - "hiddenSeries": false, - "id": 13, - "interval": "", - "legend": { - "alignAsTable": false, - "avg": false, - "current": true, - "max": false, - "min": false, - "rightSide": false, - "show": true, - "sort": "current", - "sortDesc": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null as zero", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "histogram_quantile(0.95, sum(rate(loki_logql_querystats_bytes_processed_per_seconds_bucket[5m])) by (le,type))", - "interval": "", - "legendFormat": "{{ type }}", - "range": true, - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "LogQL Processed bytes", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:155", - "format": "Bps", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:156", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "collapsed": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 17 - }, - "id": 34, - "panels": [], - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "refId": "A" - } - ], - "title": "Cache ", - "type": "row" - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 0, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 12, - "x": 0, - "y": 18 - }, - "hiddenSeries": false, - "id": 45, - "interval": "", - "legend": { - "alignAsTable": true, - "avg": false, - "current": true, - "max": false, - "min": false, - "rightSide": true, - "show": true, - "sort": "current", - "sortDesc": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null as zero", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "histogram_quantile(0.95, sum(rate(loki_cache_request_duration_seconds_bucket[5m])) by (le,name,method))", - "interval": "", - "legendFormat": "{{method}}", - "range": true, - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Cache Request Duration", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:155", - "format": "s", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:156", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 0, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 12, - "x": 12, - "y": 18 - }, - "hiddenSeries": false, - "id": 29, - "interval": "", - "legend": { - "alignAsTable": true, - "avg": false, - "current": true, - "max": false, - "min": false, - "rightSide": true, - "show": true, - "sort": "current", - "sortDesc": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null as zero", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "histogram_quantile(0.95, sum(rate(loki_cache_value_size_bytes_bucket[5m])) by (le,name,method))", - "interval": "", - "legendFormat": "{{name}} / {{method}}", - "range": true, - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Cache Value Size bytes", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:155", - "format": "decbytes", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:156", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 10, - "x": 0, - "y": 24 - }, - "hiddenSeries": false, - "id": 27, - "legend": { - "avg": false, - "current": true, - "max": false, - "min": false, - "show": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "rate(loki_cache_hits[5m])", - "interval": "", - "legendFormat": "{{name}}", - "range": true, - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Hits Keys", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:1092", - "format": "short", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:1093", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 7, - "x": 10, - "y": 24 - }, - "hiddenSeries": false, - "id": 30, - "legend": { - "avg": false, - "current": true, - "max": false, - "min": false, - "show": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "loki_cache_corrupt_chunks_total", - "interval": "", - "legendFormat": "{{name}}", - "range": true, - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Corrupt Chunks Total", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:1092", - "format": "short", - "logBase": 1, - "min": "0", - "show": true - }, - { - "$$hashKey": "object:1093", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 7, - "x": 17, - "y": 24 - }, - "hiddenSeries": false, - "id": 26, - "legend": { - "avg": false, - "current": true, - "max": false, - "min": false, - "show": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "editorMode": "code", - "expr": "loki_cache_fetched_keys", - "interval": "", - "legendFormat": "{{name}}", - "range": true, - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Fetched Keys", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:1092", - "format": "short", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:1093", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "collapsed": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 30 - }, - "id": 19, - "panels": [], - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "refId": "A" - } - ], - "title": "Distributor", - "type": "row" - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 6, - "x": 0, - "y": 31 - }, - "hiddenSeries": false, - "id": 20, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "sum by (tenant) (rate(loki_distributor_lines_received_total[5m]))", - "interval": "", - "legendFormat": "distributor / {{ tenant}}", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Received Lines / sec", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:1092", - "format": "short", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:1093", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 6, - "x": 6, - "y": 31 - }, - "hiddenSeries": false, - "id": 15, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "sum(rate(loki_distributor_bytes_received_total[5m])) by (tenant)", - "interval": "", - "legendFormat": "distributor / {{tenant}}", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Distributor Received bytes / sec", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:837", - "format": "Bps", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:838", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 6, - "x": 12, - "y": 31 - }, - "hiddenSeries": false, - "id": 17, - "legend": { - "avg": false, - "current": true, - "max": false, - "min": false, - "show": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "rate(loki_distributor_ingester_appends_total[5m])", - "interval": "", - "legendFormat": "succeeded", - "refId": "A" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "loki_distributor_ingester_append_failures_total", - "interval": "", - "legendFormat": "failed", - "refId": "B" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "batch appends sent to ingesters / sec", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:1092", - "format": "short", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:1093", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "links": [], - "unit": "short" - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 6, - "x": 18, - "y": 31 - }, - "hiddenSeries": false, - "id": 22, - "interval": "", - "legend": { - "avg": false, - "current": true, - "max": false, - "min": false, - "show": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "sum by (status) (rate(loki_store_series_total[5m]))", - "instant": false, - "interval": "", - "legendFormat": "{{status}}", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Store Series / sec", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:88", - "format": "short", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:89", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "collapsed": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 37 - }, - "id": 66, - "panels": [], - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "refId": "A" - } - ], - "title": "Ingster", - "type": "row" - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 0, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 8, - "x": 0, - "y": 38 - }, - "hiddenSeries": false, - "id": 71, - "interval": "", - "legend": { - "alignAsTable": false, - "avg": false, - "current": true, - "max": false, - "min": false, - "rightSide": false, - "show": true, - "sort": "current", - "sortDesc": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null as zero", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "histogram_quantile(0.95, sum(rate(loki_ingester_blocks_per_chunk_bucket[5m])) by (le))", - "interval": "", - "legendFormat": "blocks", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Blocks / Chunk", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:155", - "format": "none", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:156", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 0, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 8, - "x": 8, - "y": 38 - }, - "hiddenSeries": false, - "id": 68, - "interval": "", - "legend": { - "alignAsTable": false, - "avg": false, - "current": true, - "max": false, - "min": false, - "rightSide": false, - "show": true, - "sort": "current", - "sortDesc": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null as zero", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "histogram_quantile(0.95, sum(rate(loki_ingester_chunk_size_bytes_bucket[5m])) by (le))", - "interval": "", - "legendFormat": "chunk size", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Chunk Size", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:155", - "format": "decbytes", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:156", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 0, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 8, - "x": 16, - "y": 38 - }, - "hiddenSeries": false, - "id": 72, - "interval": "", - "legend": { - "alignAsTable": false, - "avg": false, - "current": true, - "max": false, - "min": false, - "rightSide": false, - "show": true, - "sort": "current", - "sortDesc": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null as zero", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "histogram_quantile(0.95, sum(rate(loki_ingester_chunk_age_seconds_bucket[5m])) by (le))", - "interval": "", - "legendFormat": "ages", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Chunk Age", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:155", - "format": "s", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:156", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 0, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 8, - "x": 0, - "y": 44 - }, - "hiddenSeries": false, - "id": 70, - "interval": "", - "legend": { - "alignAsTable": false, - "avg": false, - "current": true, - "max": false, - "min": false, - "rightSide": false, - "show": true, - "sort": "current", - "sortDesc": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null as zero", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "histogram_quantile(0.95, sum(rate(loki_ingester_chunk_compression_ratio_bucket[5m])) by (le))", - "interval": "", - "legendFormat": "ratio", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Chunk Compression Ratios", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:155", - "format": "percent", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:156", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 0, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 8, - "x": 8, - "y": 44 - }, - "hiddenSeries": false, - "id": 69, - "interval": "", - "legend": { - "alignAsTable": false, - "avg": false, - "current": true, - "max": false, - "min": false, - "rightSide": false, - "show": true, - "sort": "current", - "sortDesc": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null as zero", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "histogram_quantile(0.95, sum(rate(loki_ingester_chunk_encode_time_seconds_bucket[5m])) by (le))", - "interval": "", - "legendFormat": "durations.", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Chunk Encode Time", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:155", - "format": "s", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:156", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 0, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 8, - "x": 16, - "y": 44 - }, - "hiddenSeries": false, - "id": 73, - "interval": "", - "legend": { - "alignAsTable": false, - "avg": false, - "current": true, - "max": false, - "min": false, - "rightSide": false, - "show": true, - "sort": "current", - "sortDesc": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null as zero", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "histogram_quantile(0.95, sum(rate(loki_ingester_chunk_entries_bucket[5m])) by (le))", - "interval": "", - "legendFormat": "lines", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Lines / Chunk", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:155", - "format": "none", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:156", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 12, - "x": 0, - "y": 50 - }, - "hiddenSeries": false, - "id": 60, - "legend": { - "alignAsTable": true, - "avg": false, - "current": true, - "max": false, - "min": false, - "rightSide": true, - "show": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "rate(loki_ingester_chunks_created_total[5m])", - "interval": "", - "legendFormat": "create", - "refId": "A" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "sum by (reason) (rate(loki_ingester_chunks_flushed_total[5m]))", - "interval": "", - "legendFormat": "flush / {{ reason }}", - "refId": "B" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "sum by (fake) (rate(loki_ingester_chunks_stored_total[5m]))", - "interval": "", - "legendFormat": "stored", - "refId": "C" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "", - "interval": "", - "legendFormat": "", - "refId": "D" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Chunk Status", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:1092", - "format": "short", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:1093", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 6, - "x": 12, - "y": 50 - }, - "hiddenSeries": false, - "id": 61, - "legend": { - "avg": false, - "current": true, - "max": false, - "min": false, - "show": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "loki_ingester_memory_chunks", - "interval": "", - "legendFormat": "chunks", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Chunks in Memory", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:1092", - "format": "short", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:1093", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 6, - "x": 18, - "y": 50 - }, - "hiddenSeries": false, - "id": 62, - "legend": { - "avg": false, - "current": true, - "max": false, - "min": false, - "show": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "sum by (tenan) (loki_ingester_memory_streams)", - "interval": "", - "legendFormat": "streams", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Chunks in Streams", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:1092", - "format": "short", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:1093", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 12, - "x": 0, - "y": 56 - }, - "hiddenSeries": false, - "id": 67, - "legend": { - "alignAsTable": true, - "avg": false, - "current": true, - "max": false, - "min": false, - "rightSide": true, - "show": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "rate(loki_ingester_streams_created_total[5m])", - "interval": "", - "legendFormat": "create", - "refId": "A" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "rate(loki_ingester_streams_removed_total[5m])", - "interval": "", - "legendFormat": "delete", - "refId": "B" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Streams Stats", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:1092", - "format": "short", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:1093", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - } - ], - "schemaVersion": 37, - "style": "dark", - "tags": [ - "loki" - ], - "templating": { - "list": [] - }, - "time": { - "from": "now-1h", - "to": "now" - }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ] - }, - "timezone": "", - "title": "Loki", - "uid": "loki", - "version": 1, - "weekStart": "" -} \ No newline at end of file diff --git a/deploy/helm/dashboards/nvidia-gpu-exporter.json b/deploy/helm/dashboards/nvidia-gpu-exporter.json deleted file mode 100644 index d3b2413154c..00000000000 --- a/deploy/helm/dashboards/nvidia-gpu-exporter.json +++ /dev/null @@ -1,2167 +0,0 @@ -{ - "annotations": { - "list": [ - { - "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": "Nvidia GPU Metrics based on the prometheus metrics from github.com/utkuozdemir/nvidia_gpu_exporter", - "editable": true, - "fiscalYearStartMonth": 0, - "gnetId": 14574, - "graphTooltip": 0, - "id": 11, - "links": [], - "liveNow": false, - "panels": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "description": "The official product name of the GPU. This is an alphanumeric string. For all products.", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "decimals": 2, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 4, - "x": 0, - "y": 0 - }, - "id": 23, - "options": { - "colorMode": "value", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "last" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "name" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "exemplar": true, - "expr": "nvidia_smi_gpu_info{uuid=\"$gpu\"}", - "instant": true, - "interval": "", - "legendFormat": "{{name}}", - "refId": "A" - } - ], - "title": "Name", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "description": "The current performance state for the GPU. States range from P0 (maximum performance) to P12 (minimum performance).", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "decimals": 0, - "mappings": [ - { - "options": { - "": { - "text": "" - } - }, - "type": "value" - } - ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "prefix:P" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 2, - "x": 4, - "y": 0 - }, - "id": 22, - "options": { - "colorMode": "value", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "last" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "value" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "exemplar": true, - "expr": "nvidia_smi_pstate{uuid=\"$gpu\"}", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "P-State", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "description": "Percent of time over the past sample period during which one or more kernels was executing on the GPU.\nThe sample period may be between 1 second and 1/6 second depending on the product.", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "max": 1, - "min": 0, - "thresholds": { - "mode": "percentage", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "#EAB839", - "value": 70 - }, - { - "color": "red", - "value": 90 - } - ] - }, - "unit": "percentunit" - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 3, - "x": 6, - "y": 0 - }, - "id": 6, - "options": { - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "last" - ], - "fields": "", - "values": false - }, - "showThresholdLabels": false, - "showThresholdMarkers": true, - "text": {} - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "exemplar": true, - "expr": "nvidia_smi_utilization_gpu_ratio{uuid=\"$gpu\"}", - "interval": "", - "legendFormat": "{{uuid}}", - "refId": "A" - } - ], - "title": "GPU Utilization %", - "transformations": [], - "type": "gauge" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "description": "The last measured power draw for the entire board, in watts. Only available if power management is supported. This reading is accurate to within +/- 5 watts / The software power limit in watts.", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "max": 1, - "min": 0, - "thresholds": { - "mode": "percentage", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "#EAB839", - "value": 70 - }, - { - "color": "red", - "value": 90 - } - ] - }, - "unit": "percentunit" - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 3, - "x": 9, - "y": 0 - }, - "id": 21, - "options": { - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "last" - ], - "fields": "", - "values": false - }, - "showThresholdLabels": false, - "showThresholdMarkers": true, - "text": {} - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "exemplar": true, - "expr": "nvidia_smi_power_draw_watts{uuid=\"$gpu\"} / nvidia_smi_power_default_limit_watts{uuid=\"$gpu\"}", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Power Draw %", - "type": "gauge" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "description": "The fan speed value is the percent of the product's maximum noise tolerance fan speed that the device's fan is currently intended to run at. This value may exceed 100% in certain cases. Note: The reported speed is the intended fan speed. If the fan is physically blocked and unable to spin, this output will not match the actual fan speed. Many parts do not report fan speeds because they rely on cooling via fans in the surrounding enclosure.\n", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "max": 1, - "min": 0, - "thresholds": { - "mode": "percentage", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "#EAB839", - "value": 70 - }, - { - "color": "red", - "value": 90 - } - ] - }, - "unit": "percentunit" - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 3, - "x": 12, - "y": 0 - }, - "id": 4, - "options": { - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "last" - ], - "fields": "", - "values": false - }, - "showThresholdLabels": false, - "showThresholdMarkers": true, - "text": {} - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "exemplar": true, - "expr": "nvidia_smi_fan_speed_ratio{uuid=\"$gpu\"}", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Fan Speed %", - "type": "gauge" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "description": "Core GPU temperature. in degrees C.", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "max": 100, - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "#EAB839", - "value": 70 - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "celsius" - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 3, - "x": 15, - "y": 0 - }, - "id": 16, - "options": { - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "last" - ], - "fields": "", - "values": false - }, - "showThresholdLabels": false, - "showThresholdMarkers": true, - "text": {} - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "exemplar": true, - "expr": "nvidia_smi_temperature_gpu{uuid=\"$gpu\"}", - "interval": "", - "legendFormat": "{{uuid}}", - "refId": "A" - } - ], - "title": "Temperature", - "type": "gauge" - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "description": "Percent of time over the past sample period during which global (device) memory was being read or written.\nThe sample period may be between 1 second and 1/6 second depending on the product.", - "fieldConfig": { - "defaults": { - "unit": "percentunit" - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 5, - "w": 6, - "x": 18, - "y": 0 - }, - "hiddenSeries": false, - "id": 11, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "exemplar": true, - "expr": "nvidia_smi_utilization_memory_ratio{uuid=\"$gpu\"}", - "interval": "", - "legendFormat": "{{uuid}}", - "refId": "A" - } - ], - "thresholds": [ - { - "$$hashKey": "object:1370", - "colorMode": "warning", - "fill": true, - "line": true, - "op": "gt", - "value": 0.7, - "yaxis": "left" - }, - { - "$$hashKey": "object:1376", - "colorMode": "critical", - "fill": true, - "line": true, - "op": "gt", - "value": 0.9, - "yaxis": "left" - } - ], - "timeRegions": [], - "title": "Memory Utilization %", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:1352", - "format": "percentunit", - "label": "", - "logBase": 1, - "max": "1", - "min": "0", - "show": true - }, - { - "$$hashKey": "object:1353", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "description": "The version of the installed NVIDIA display driver. This is an alphanumeric string.", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "decimals": 2, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 2, - "w": 3, - "x": 0, - "y": 3 - }, - "id": 14, - "options": { - "colorMode": "value", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "last" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "name" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "exemplar": true, - "expr": "nvidia_smi_gpu_info{uuid=\"$gpu\"}", - "instant": true, - "interval": "", - "legendFormat": "{{driver_version}}", - "refId": "A" - } - ], - "title": "Driver Version", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "description": "The BIOS of the GPU board.", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "decimals": 2, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 2, - "w": 3, - "x": 3, - "y": 3 - }, - "id": 34, - "options": { - "colorMode": "value", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "last" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "name" - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "exemplar": true, - "expr": "nvidia_smi_gpu_info{uuid=\"$gpu\"}", - "instant": true, - "interval": "", - "legendFormat": "{{vbios_version}}", - "refId": "A" - } - ], - "title": "Vbios Version", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "description": "Information about factors that are reducing the frequency of clocks. If all throttle reasons are returned as \"Not Active\" it means that clocks are running as high as possible.", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "decimals": 0, - "mappings": [ - { - "options": { - "0": { - "text": "Not Active" - }, - "1": { - "text": "Active" - } - }, - "type": "value" - } - ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 6, - "x": 0, - "y": 5 - }, - "id": 32, - "links": [], - "options": { - "displayMode": "gradient", - "minVizHeight": 10, - "minVizWidth": 0, - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "last" - ], - "fields": "", - "values": false - }, - "showUnfilled": true, - "text": {} - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "exemplar": true, - "expr": "nvidia_smi_clocks_throttle_reasons_gpu_idle{uuid=\"$gpu\"}", - "instant": false, - "interval": "", - "legendFormat": "Idle", - "refId": "A" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "exemplar": true, - "expr": "nvidia_smi_clocks_throttle_reasons_hw_thermal_slowdown{uuid=\"$gpu\"}", - "hide": false, - "interval": "", - "legendFormat": "HW Thermal Slowdown", - "refId": "B" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "exemplar": true, - "expr": "nvidia_smi_clocks_throttle_reasons_sw_power_cap{uuid=\"$gpu\"}", - "hide": false, - "interval": "", - "legendFormat": "SW Power Cap", - "refId": "C" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "exemplar": true, - "expr": "nvidia_smi_clocks_throttle_reasons_applications_clocks_setting{uuid=\"$gpu\"}", - "hide": false, - "interval": "", - "legendFormat": "App Clocks Setting", - "refId": "D" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "exemplar": true, - "expr": "nvidia_smi_clocks_throttle_reasons_hw_power_brake_slowdown{uuid=\"$gpu\"}", - "hide": false, - "interval": "", - "legendFormat": "HW Power Brake", - "refId": "E" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "exemplar": true, - "expr": "nvidia_smi_clocks_throttle_reasons_sw_thermal_slowdown{uuid=\"$gpu\"}", - "hide": false, - "interval": "", - "legendFormat": "SW Thermal Slowdown", - "refId": "F" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "exemplar": true, - "expr": "nvidia_smi_clocks_throttle_reasons_sync_boost{uuid=\"$gpu\"}", - "hide": false, - "interval": "", - "legendFormat": "Sync Boost", - "refId": "G" - } - ], - "title": "Throttle Reasons", - "type": "bargauge" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "description": "Current frequency of graphics (shader) clock\n/\nMaximum frequency of graphics (shader) clock.\n", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "max": 1, - "min": 0, - "thresholds": { - "mode": "percentage", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "#EAB839", - "value": 70 - }, - { - "color": "red", - "value": 90 - } - ] - }, - "unit": "percentunit" - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 3, - "x": 6, - "y": 5 - }, - "id": 20, - "options": { - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "last" - ], - "fields": "", - "values": false - }, - "showThresholdLabels": false, - "showThresholdMarkers": true, - "text": {} - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "exemplar": true, - "expr": "nvidia_smi_clocks_current_graphics_clock_hz{uuid=\"$gpu\"} / nvidia_smi_clocks_max_graphics_clock_hz{uuid=\"$gpu\"}", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "GPU Clock Speed %", - "type": "gauge" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "description": "Current frequency of memory clock / Maximum frequency of memory clock", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "max": 1, - "min": 0, - "thresholds": { - "mode": "percentage", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "#EAB839", - "value": 70 - }, - { - "color": "red", - "value": 90 - } - ] - }, - "unit": "percentunit" - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 3, - "x": 9, - "y": 5 - }, - "id": 33, - "options": { - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "last" - ], - "fields": "", - "values": false - }, - "showThresholdLabels": false, - "showThresholdMarkers": true, - "text": {} - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "exemplar": true, - "expr": "nvidia_smi_clocks_current_memory_clock_hz{uuid=\"$gpu\"} / nvidia_smi_clocks_max_memory_clock_hz{uuid=\"$gpu\"}", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Memory Clock Speed %", - "type": "gauge" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "description": "Total memory allocated by active contexts / Total installed GPU memory.", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "max": 1, - "min": 0, - "thresholds": { - "mode": "percentage", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "#EAB839", - "value": 70 - }, - { - "color": "red", - "value": 90 - } - ] - }, - "unit": "percentunit" - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 3, - "x": 12, - "y": 5 - }, - "id": 25, - "options": { - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "last" - ], - "fields": "", - "values": false - }, - "showThresholdLabels": false, - "showThresholdMarkers": true, - "text": {} - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "exemplar": true, - "expr": "nvidia_smi_memory_used_bytes{uuid=\"$gpu\"} / nvidia_smi_memory_total_bytes{uuid=\"$gpu\"}", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Memory Allocation %", - "type": "gauge" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "description": "Percent of time over the past sample period during which global (device) memory was being read or written.\nThe sample period may be between 1 second and 1/6 second depending on the product.", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "max": 1, - "min": 0, - "thresholds": { - "mode": "percentage", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "#EAB839", - "value": 70 - }, - { - "color": "red", - "value": 90 - } - ] - }, - "unit": "percentunit" - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 3, - "x": 15, - "y": 5 - }, - "id": 7, - "options": { - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "last" - ], - "fields": "", - "values": false - }, - "showThresholdLabels": false, - "showThresholdMarkers": true, - "text": {} - }, - "pluginVersion": "9.2.4", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "exemplar": true, - "expr": "nvidia_smi_utilization_memory_ratio{uuid=\"$gpu\"}", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Memory Utilization %", - "type": "gauge" - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "description": "Percent of time over the past sample period during which one or more kernels was executing on the GPU.\nThe sample period may be between 1 second and 1/6 second depending on the product.", - "fieldConfig": { - "defaults": { - "unit": "percentunit" - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 5, - "w": 6, - "x": 18, - "y": 5 - }, - "hiddenSeries": false, - "id": 10, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "exemplar": true, - "expr": "nvidia_smi_utilization_gpu_ratio{uuid=\"$gpu\"}", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [ - { - "$$hashKey": "object:1370", - "colorMode": "warning", - "fill": true, - "line": true, - "op": "gt", - "value": 0.7, - "yaxis": "left" - }, - { - "$$hashKey": "object:1376", - "colorMode": "critical", - "fill": true, - "line": true, - "op": "gt", - "value": 0.9, - "yaxis": "left" - } - ], - "timeRegions": [], - "title": "GPU Utilization %", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:1352", - "format": "percentunit", - "label": "", - "logBase": 1, - "max": "1", - "min": "0", - "show": true - }, - { - "$$hashKey": "object:1353", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "description": "Total memory allocated by active contexts.", - "fieldConfig": { - "defaults": { - "unit": "decbytes" - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 5, - "w": 6, - "x": 0, - "y": 10 - }, - "hiddenSeries": false, - "id": 17, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "exemplar": true, - "expr": "nvidia_smi_memory_used_bytes{uuid=\"$gpu\"}", - "interval": "", - "legendFormat": "{{uuid}}", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Memory Allocation", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:1352", - "format": "decbytes", - "label": "", - "logBase": 1, - "min": "0", - "show": true - }, - { - "$$hashKey": "object:1353", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "description": "Core GPU temperature. in degrees C.", - "fieldConfig": { - "defaults": { - "unit": "celsius" - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 5, - "w": 6, - "x": 6, - "y": 10 - }, - "hiddenSeries": false, - "id": 15, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "exemplar": true, - "expr": "nvidia_smi_temperature_gpu{uuid=\"$gpu\"}", - "interval": "", - "legendFormat": "{{uuid}}", - "refId": "A" - } - ], - "thresholds": [ - { - "$$hashKey": "object:1805", - "colorMode": "warning", - "fill": true, - "line": true, - "op": "gt", - "value": 70, - "yaxis": "left" - }, - { - "$$hashKey": "object:1811", - "colorMode": "critical", - "fill": true, - "line": true, - "op": "gt", - "value": 80, - "yaxis": "left" - } - ], - "timeRegions": [], - "title": "Temperature", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:1761", - "format": "celsius", - "label": "", - "logBase": 1, - "max": "100", - "min": "0", - "show": true - }, - { - "$$hashKey": "object:1762", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "description": "The last measured power draw for the entire board, in watts. Only available if power management is supported. This reading is accurate to within +/- 5 watts", - "fieldConfig": { - "defaults": { - "unit": "watt" - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 5, - "w": 6, - "x": 12, - "y": 10 - }, - "hiddenSeries": false, - "id": 8, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "exemplar": true, - "expr": "nvidia_smi_power_draw_watts{uuid=\"$gpu\"}", - "interval": "", - "legendFormat": "{{uuid}}", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Power Draw", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:658", - "format": "watt", - "logBase": 1, - "min": "0", - "show": true - }, - { - "$$hashKey": "object:659", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "description": "The fan speed value is the percent of the product's maximum noise tolerance fan speed that the device's fan is currently intended to run at. This value may exceed 100% in certain cases. Note: The reported speed is the intended fan speed. If the fan is physically blocked and unable to spin, this output will not match the actual fan speed. Many parts do not report fan speeds because they rely on cooling via fans in the surrounding enclosure.\n", - "fieldConfig": { - "defaults": { - "unit": "percentunit" - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 5, - "w": 6, - "x": 18, - "y": 10 - }, - "hiddenSeries": false, - "id": 9, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "exemplar": true, - "expr": "nvidia_smi_fan_speed_ratio{uuid=\"$gpu\"}", - "interval": "", - "legendFormat": "{{uuid}}", - "refId": "A" - } - ], - "thresholds": [ - { - "$$hashKey": "object:1168", - "colorMode": "critical", - "fill": true, - "line": true, - "op": "gt", - "value": 0.9, - "yaxis": "left" - }, - { - "$$hashKey": "object:1174", - "colorMode": "warning", - "fill": true, - "line": true, - "op": "gt", - "value": 0.7, - "yaxis": "left" - } - ], - "timeRegions": [], - "title": "Fan Speed %", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:1275", - "format": "percentunit", - "logBase": 1, - "max": "1", - "min": "0", - "show": true - }, - { - "$$hashKey": "object:1276", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "description": "Current frequency of graphics (shader) clock.", - "fieldConfig": { - "defaults": { - "unit": "hertz" - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 5, - "w": 6, - "x": 0, - "y": 15 - }, - "hiddenSeries": false, - "id": 12, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "exemplar": true, - "expr": "nvidia_smi_clocks_current_graphics_clock_hz{uuid=\"$gpu\"}", - "format": "time_series", - "interval": "", - "legendFormat": "{{uuid}}", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Graphics Clock Speed", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:1642", - "format": "hertz", - "logBase": 1, - "min": "0", - "show": true - }, - { - "$$hashKey": "object:1643", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "description": "Current frequency of video encoder/decoder clock.", - "fieldConfig": { - "defaults": { - "unit": "hertz" - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 5, - "w": 6, - "x": 6, - "y": 15 - }, - "hiddenSeries": false, - "id": 19, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "exemplar": true, - "expr": "nvidia_smi_clocks_current_video_clock_hz{uuid=\"$gpu\"}", - "format": "time_series", - "interval": "", - "legendFormat": "{{uuid}}", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Video Clock Speed", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:1642", - "format": "hertz", - "logBase": 1, - "min": "0", - "show": true - }, - { - "$$hashKey": "object:1643", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "description": "Current frequency of SM (Streaming Multiprocessor) clock.", - "fieldConfig": { - "defaults": { - "unit": "hertz" - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 5, - "w": 6, - "x": 12, - "y": 15 - }, - "hiddenSeries": false, - "id": 24, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "exemplar": true, - "expr": "nvidia_smi_clocks_current_sm_clock_hz{uuid=\"$gpu\"}", - "format": "time_series", - "interval": "", - "legendFormat": "{{uuid}}", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "SM Clock Speed", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:1642", - "format": "hertz", - "logBase": 1, - "min": "0", - "show": true - }, - { - "$$hashKey": "object:1643", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "description": "Current frequency of memory clock.", - "fieldConfig": { - "defaults": { - "unit": "hertz" - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 5, - "w": 6, - "x": 18, - "y": 15 - }, - "hiddenSeries": false, - "id": 18, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.2.4", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "exemplar": true, - "expr": "nvidia_smi_clocks_current_memory_clock_hz{uuid=\"$gpu\"}", - "format": "time_series", - "interval": "", - "legendFormat": "{{uuid}}", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Memory Clock Speed", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:1642", - "format": "hertz", - "logBase": 1, - "min": "0", - "show": true - }, - { - "$$hashKey": "object:1643", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - } - ], - "refresh": "10s", - "schemaVersion": 37, - "style": "dark", - "tags": [ - "nvidia", - "nvidia-smi", - "nvidia_gpu_exporter", - "prometheus" - ], - "templating": { - "list": [ - { - "current": { - "isNone": true, - "selected": false, - "text": "None", - "value": "" - }, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "definition": "label_values(nvidia_smi_index, node)", - "hide": 0, - "includeAll": false, - "label": "node", - "multi": false, - "name": "node", - "options": [], - "query": { - "query": "label_values(nvidia_smi_index, node)", - "refId": "StandardVariableQuery" - }, - "refresh": 1, - "regex": "", - "skipUrlSync": false, - "sort": 1, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false - }, - { - "current": { - "isNone": true, - "selected": false, - "text": "None", - "value": "" - }, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "definition": "label_values(nvidia_smi_index{node=\"$node\"}, uuid)", - "hide": 0, - "includeAll": false, - "label": "GPU", - "multi": false, - "name": "gpu", - "options": [], - "query": { - "query": "label_values(nvidia_smi_index{node=\"$node\"}, uuid)", - "refId": "StandardVariableQuery" - }, - "refresh": 1, - "regex": "", - "skipUrlSync": false, - "sort": 1, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false - } - ] - }, - "time": { - "from": "now-30m", - "to": "now" - }, - "timepicker": {}, - "timezone": "", - "title": "Nvidia GPU Metrics", - "uid": "vlvPlrgnk", - "version": 7, - "weekStart": "" -} \ No newline at end of file diff --git a/deploy/helm/scripts/change_kb_release.sh b/deploy/helm/scripts/change_kb_release.sh index 2ec92013277..b91a39f9779 100644 --- a/deploy/helm/scripts/change_kb_release.sh +++ b/deploy/helm/scripts/change_kb_release.sh @@ -83,14 +83,7 @@ addons=( "postgresql" "qdrant" "redis" - "alertmanager-webhook-adaptor" - "aws-load-balancer-controller" - "csi-driver-nfs" - "csi-hostpath-driver" - "grafana" - "prometheus" "snapshot-controller" - "victoria-metrics-agent" ) for addon in "${addons[@]}"; do diff --git a/deploy/helm/templates/_helpers.tpl b/deploy/helm/templates/_helpers.tpl index 928983a485c..278290d6485 100644 --- a/deploy/helm/templates/_helpers.tpl +++ b/deploy/helm/templates/_helpers.tpl @@ -148,82 +148,6 @@ Allow the release namespace to be overridden for multi-namespace deployments in {{- end -}} - - -{{/* -Use the prometheus namespace override for multi-namespace deployments in combined charts -*/}} -{{- define "kubeblocks.prometheus.namespace" -}} - {{- if .Values.prometheus.namespaceOverride -}} - {{- .Values.prometheus.namespaceOverride -}} - {{- else -}} - {{- .Release.Namespace -}} - {{- end -}} -{{- end -}} - -{{/* -Use the grafana namespace override for multi-namespace deployments in combined charts -*/}} -{{- define "kubeblocks.grafana.namespace" -}} - {{- if .Values.grafana.namespaceOverride -}} - {{- .Values.grafana.namespaceOverride -}} - {{- else -}} - {{- .Release.Namespace -}} - {{- end -}} -{{- end -}} - -{{/* -Create a fully qualified Prometheus server name. -We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec). -*/}} -{{- define "kubeblocks.prometheus.server.fullname" -}} -{{- if .Values.prometheus.server.fullnameOverride -}} -{{- .Values.prometheus.server.fullnameOverride | trunc 63 | trimSuffix "-" -}} -{{- else -}} -{{- $name := default .Values.prometheus.nameOverride "prometheus" -}} -{{- if contains $name .Release.Name -}} -{{- printf "%s-%s" .Release.Name .Values.prometheus.server.name | trunc 63 | trimSuffix "-" -}} -{{- else -}} -{{- printf "%s-%s-%s" .Release.Name $name .Values.prometheus.server.name | trunc 63 | trimSuffix "-" -}} -{{- end -}} -{{- end -}} -{{- end -}} - -{{/* -Create a fully qualified alertmanager name. -We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec). -*/}} -{{- define "kubeblocks.prometheus.alertmanager.fullname" -}} -{{- if .Values.prometheus.alertmanager.fullnameOverride -}} -{{- .Values.prometheus.alertmanager.fullnameOverride | trunc 63 | trimSuffix "-" -}} -{{- else -}} -{{- $name := default .Values.prometheus.nameOverride "prometheus" -}} -{{- if contains $name .Release.Name -}} -{{- printf "%s-%s" .Release.Name .Values.prometheus.alertmanager.name | trunc 63 | trimSuffix "-" -}} -{{- else -}} -{{- printf "%s-%s-%s" .Release.Name $name .Values.prometheus.alertmanager.name | trunc 63 | trimSuffix "-" -}} -{{- end -}} -{{- end -}} -{{- end -}} - -{{/* -Create a default fully qualified app name. -We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec). -If release name contains chart name it will be used as a full name. -*/}} -{{- define "kubeblocks.grafana.fullname" -}} -{{- if .Values.grafana.fullnameOverride -}} -{{- .Values.grafana.fullnameOverride | trunc 63 | trimSuffix "-" -}} -{{- else -}} -{{- $name := default .Values.grafana.nameOverride "grafana" -}} -{{- if contains $name .Release.Name -}} -{{- .Release.Name | trunc 63 | trimSuffix "-" -}} -{{- else -}} -{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}} -{{- end -}} -{{- end -}} -{{- end -}} - {{/* Specify KubeBlocks Operator deployment with priorityClassName=system-cluster-critical, if deployed to "kube-system" namespace and unspecified priorityClassName. @@ -249,27 +173,6 @@ Get addon controller enabled attributes. {{- end }} {{- end }} -{{/* -Define addon prometheus name -*/}} -{{- define "addon.prometheus.name" -}} -{{- print "prometheus" }} -{{- end }} - -{{/* -Define addon alertmanager-webhook-adaptor name -*/}} -{{- define "addon.alertmanager-webhook-adaptor.name" -}} -{{- print "alertmanager-webhook-adaptor" }} -{{- end }} - -{{/* -Define addon loki name -*/}} -{{- define "addon.loki.name" -}} -{{- print "loki" }} -{{- end }} - {{/* Get cloud provider, now support aws, gcp, aliyun and tencentCloud. TODO: For azure, we should get provider from node.Spec.ProviderID diff --git a/deploy/helm/templates/applications/alertmanager-webhook-adaptor-addon.yaml b/deploy/helm/templates/applications/alertmanager-webhook-adaptor-addon.yaml deleted file mode 100644 index bf9bdd8211d..00000000000 --- a/deploy/helm/templates/applications/alertmanager-webhook-adaptor-addon.yaml +++ /dev/null @@ -1,52 +0,0 @@ -{{- if has "alertmanager-webhook-adaptor" .Values.autoInstalledAddons }} -apiVersion: extensions.kubeblocks.io/v1alpha1 -kind: Addon -metadata: - name: {{ include "addon.alertmanager-webhook-adaptor.name" . }} - labels: - {{- include "kubeblocks.labels" . | nindent 4 }} - "addon.kubeblocks.io/provider": apecloud - "addon.kubeblocks.io/version": "0.1.4" - {{- if .Values.keepAddons }} - annotations: - helm.sh/resource-policy: keep - {{- end }} -spec: - description: 'alertmanager webhook adaptor for extending alertmanager notification channels' - type: Helm - - helm: - {{- include "kubeblocks.addonChartLocationURL" ( dict "name" "alertmanager-webhook-adaptor" "version" "0.1.4" "values" .Values) | indent 4 }} - {{- include "kubeblocks.addonChartsImage" . | indent 4 }} - {{- include "kubeblocks.addonHelmInstallOptions" (dict "version" "0.1.4" "values" .Values) | indent 4 }} - - installValues: - configMapRefs: - - name: {{ include "addon.alertmanager-webhook-adaptor.name" . }}-chart-kubeblocks-values - key: values-kubeblocks-override.yaml - - valuesMapping: - valueMap: - replicaCount: replicaCount - - jsonMap: - tolerations: tolerations - - resources: - cpu: - requests: resources.requests.cpu - limits: resources.limits.cpu - memory: - requests: resources.requests.memory - limits: resources.limits.memory - - defaultInstallValues: - - replicas: 1 - {{- with .Values.tolerations }} - tolerations: {{ toJson . | quote }} - {{- end }} - - installable: - autoInstall: {{ .Values.prometheus.enabled }} -{{- end }} - diff --git a/deploy/helm/templates/applications/alertmanager-webhook-adaptor-values.yaml b/deploy/helm/templates/applications/alertmanager-webhook-adaptor-values.yaml deleted file mode 100644 index dbed0830c1f..00000000000 --- a/deploy/helm/templates/applications/alertmanager-webhook-adaptor-values.yaml +++ /dev/null @@ -1,22 +0,0 @@ -{{- if has "alertmanager-webhook-adaptor" .Values.autoInstalledAddons }} -{{- $imageRegistry := include "kubeblocks.imageRegistry" . }} -apiVersion: v1 -kind: ConfigMap -metadata: - name: {{ include "addon.alertmanager-webhook-adaptor.name" . }}-chart-kubeblocks-values - labels: - {{- include "kubeblocks.labels" . | nindent 4 }} - {{- if .Values.keepAddons }} - annotations: - helm.sh/resource-policy: keep - {{- end }} -data: - values-kubeblocks-override.yaml: |- - {{- $alertmanagerWebhookAdaptor := get .Values "alertmanager-webhook-adaptor" }} - {{- $image := get $alertmanagerWebhookAdaptor "image" }} - {{- if not $image.registry }} - {{- $image = set $image "registry" $imageRegistry }} - {{- end }} - {{- $alertmanagerWebhookAdaptor = set $alertmanagerWebhookAdaptor "image" $image }} - {{- toYaml $alertmanagerWebhookAdaptor | nindent 4 }} -{{- end }} \ No newline at end of file diff --git a/deploy/helm/templates/applications/aws-loadbalancer-controller-addon.yaml b/deploy/helm/templates/applications/aws-loadbalancer-controller-addon.yaml deleted file mode 100644 index e1d8eee56c4..00000000000 --- a/deploy/helm/templates/applications/aws-loadbalancer-controller-addon.yaml +++ /dev/null @@ -1,60 +0,0 @@ -{{- if has "aws-load-balancer-controller" .Values.autoInstalledAddons }} -apiVersion: extensions.kubeblocks.io/v1alpha1 -kind: Addon -metadata: - name: aws-load-balancer-controller - labels: - {{- include "kubeblocks.labels" . | nindent 4 }} - "addon.kubeblocks.io/provider": community - "addon.kubeblocks.io/version": "1.4.8" - {{- if .Values.keepAddons }} - annotations: - helm.sh/resource-policy: keep - {{- end }} -spec: - description: The AWS Load Balancer Controller manages AWS Elastic Load Balancers for a Kubernetes cluster. - type: Helm - - helm: - {{- include "kubeblocks.addonChartLocationURL" ( dict "name" "aws-load-balancer-controller" "version" "1.4.8" "values" .Values) | indent 4 }} - {{- include "kubeblocks.addonChartsImage" . | indent 4 }} - {{- include "kubeblocks.addonHelmInstallOptions" (dict "version" "1.4.8" "values" .Values) | indent 4 }} - - installValues: - configMapRefs: - - name: aws-load-balancer-controller-chart-kubeblocks-values - key: values-kubeblocks-override.yaml - - setValues: - - clusterName={{ index .Values "aws-load-balancer-controller" "clusterName" }} - - valuesMapping: - valueMap: - replicaCount: replicaCount - - jsonMap: - tolerations: tolerations - - resources: - cpu: - requests: resources.requests.cpu - limits: resources.limits.cpu - memory: - requests: resources.requests.memory - limits: resources.limits.memory - - defaultInstallValues: - - replicas: 1 - {{- with .Values.tolerations }} - tolerations: {{ toJson . | quote }} - {{- end }} - - installable: - autoInstall: {{ index .Values "aws-load-balancer-controller" "enabled" }} - selectors: - - key: KubeGitVersion - operator: Contains - values: - - eks -{{- end }} - diff --git a/deploy/helm/templates/applications/aws-loadbalancer-controller-values.yaml b/deploy/helm/templates/applications/aws-loadbalancer-controller-values.yaml deleted file mode 100644 index 5adc2fcedf1..00000000000 --- a/deploy/helm/templates/applications/aws-loadbalancer-controller-values.yaml +++ /dev/null @@ -1,15 +0,0 @@ -{{- if has "aws-load-balancer-controller" .Values.autoInstalledAddons }} -apiVersion: v1 -kind: ConfigMap -metadata: - name: aws-load-balancer-controller-chart-kubeblocks-values - labels: - {{- include "kubeblocks.labels" . | nindent 4 }} - {{- if .Values.keepAddons }} - annotations: - helm.sh/resource-policy: keep - {{- end }} -data: - values-kubeblocks-override.yaml: |- - {{- get ( .Values | toYaml | fromYaml ) "aws-load-balancer-controller" | toYaml | nindent 4 }} -{{- end }} \ No newline at end of file diff --git a/deploy/helm/templates/applications/csi-driver-nfs-addon.yaml b/deploy/helm/templates/applications/csi-driver-nfs-addon.yaml deleted file mode 100644 index fe4a12c196b..00000000000 --- a/deploy/helm/templates/applications/csi-driver-nfs-addon.yaml +++ /dev/null @@ -1,62 +0,0 @@ -{{- if has "csi-driver-nfs" .Values.autoInstalledAddons }} -apiVersion: extensions.kubeblocks.io/v1alpha1 -kind: Addon -metadata: - name: csi-driver-nfs - labels: - {{- include "kubeblocks.labels" . | nindent 4 }} - "addon.kubeblocks.io/provider": community - "addon.kubeblocks.io/version": "4.5.0" - {{- if .Values.keepAddons }} - annotations: - helm.sh/resource-policy: keep - {{- end }} -spec: - description: Container Storage Interface (CSI) driver for NFS based volumes - type: Helm - - helm: - {{- include "kubeblocks.addonChartLocationURL" ( dict "name" "csi-driver-nfs" "version" "4.5.0" "values" .Values) | indent 4 }} - {{- include "kubeblocks.addonChartsImage" . | indent 4 }} - {{- include "kubeblocks.addonHelmInstallOptions" (dict "version" "4.5.0" "values" .Values) | indent 4 }} - - {{- $cloudProvider := (include "kubeblocks.cloudProvider" .) }} - {{- if eq $cloudProvider "huaweiCloud" }} - installValues: - setValues: - - kubeletDir=/mnt/paas/kubernetes/kubelet - {{- else if eq $cloudProvider "gcp" }} - # In GKE, the system-node-critical and system-cluster-critical priority classes - # can't be used for non-system pods, but csi-driver-nfs uses "system-cluster-critical" - # by default, so override them here. - installValues: - setValues: - - controller.priorityClassName="" - - node.priorityClassName="" - - externalSnapshotter.priorityClassName="" - {{- end }} - - valuesMapping: - valueMap: - replicaCount: controller.replicas - jsonMap: - tolerations: controller.tolerations - - defaultInstallValues: - - enabled: true - {{- with .Values.tolerations }} - tolerations: {{ toJson . | quote }} - {{- end }} - - installable: - {{- $autoInstall := false }} - {{- /* auto install csi-driver-nfs if it's required by backup repos */ -}} - {{- if .Values.backupRepo.create }} - {{- if eq .Values.backupRepo.accessMethod "Mount" }} - {{- if eq .Values.backupRepo.storageProvider "nfs" }} - {{- $autoInstall = true }} - {{- end }} - {{- end }} - {{- end }} - autoInstall: {{ $autoInstall }} -{{- end }} diff --git a/deploy/helm/templates/applications/csi-hostpath-driver-addon.yaml b/deploy/helm/templates/applications/csi-hostpath-driver-addon.yaml deleted file mode 100644 index be398dd2400..00000000000 --- a/deploy/helm/templates/applications/csi-hostpath-driver-addon.yaml +++ /dev/null @@ -1,50 +0,0 @@ -{{- if has "csi-hostpath-driver" .Values.autoInstalledAddons }} -apiVersion: extensions.kubeblocks.io/v1alpha1 -kind: Addon -metadata: - name: csi-hostpath-driver - labels: - {{- include "kubeblocks.labels" . | nindent 4 }} - "addon.kubeblocks.io/provider": community - "addon.kubeblocks.io/version": "0.7.0" - {{- if .Values.keepAddons }} - annotations: - helm.sh/resource-policy: keep - {{- end }} -spec: - description: Container Storage Interface (CSI) driver for HostPath volumes - type: Helm - - helm: - {{- include "kubeblocks.addonChartLocationURL" ( dict "name" "csi-hostpath-driver" "version" "0.7.0" "values" .Values) | indent 4 }} - {{- include "kubeblocks.addonChartsImage" . | indent 4 }} - {{- include "kubeblocks.addonHelmInstallOptions" (dict "version" "0.7.0" "values" .Values) | indent 4 }} - - installValues: - configMapRefs: - - name: csi-hostpath-driver-chart-kubeblocks-values - key: values-kubeblocks-override.yaml - - valuesMapping: - jsonMap: - tolerations: tolerations - - defaultInstallValues: - - enabled: true - {{- with .Values.tolerations }} - tolerations: {{ toJson . | quote }} - {{- end }} - - installable: - autoInstall: {{ get ( get ( .Values | toYaml | fromYaml ) "csi-hostpath-driver" ) "enabled" }} - selectors: - - key: KubeGitVersion - operator: DoesNotContain - values: - - eks - - aliyun. - - gke - - tke - - aks - -{{- end }} \ No newline at end of file diff --git a/deploy/helm/templates/applications/csi-hostpath-driver-values.yaml b/deploy/helm/templates/applications/csi-hostpath-driver-values.yaml deleted file mode 100644 index 9280ad346c0..00000000000 --- a/deploy/helm/templates/applications/csi-hostpath-driver-values.yaml +++ /dev/null @@ -1,15 +0,0 @@ -{{- if has "csi-hostpath-driver" .Values.autoInstalledAddons }} -apiVersion: v1 -kind: ConfigMap -metadata: - name: csi-hostpath-driver-chart-kubeblocks-values - labels: - {{- include "kubeblocks.labels" . | nindent 4 }} - {{- if .Values.keepAddons }} - annotations: - helm.sh/resource-policy: keep - {{- end }} -data: - values-kubeblocks-override.yaml: |- - {{- get ( .Values | toYaml | fromYaml ) "csi-hostpath-driver" | toYaml | nindent 4 }} -{{- end }} \ No newline at end of file diff --git a/deploy/helm/templates/applications/grafana-addon.yaml b/deploy/helm/templates/applications/grafana-addon.yaml deleted file mode 100644 index 75b7b88cfd1..00000000000 --- a/deploy/helm/templates/applications/grafana-addon.yaml +++ /dev/null @@ -1,70 +0,0 @@ -{{- if has "grafana" .Values.autoInstalledAddons }} -apiVersion: extensions.kubeblocks.io/v1alpha1 -kind: Addon -metadata: - name: grafana - labels: - {{- include "kubeblocks.labels" . | nindent 4 }} - "addon.kubeblocks.io/provider": community - "addon.kubeblocks.io/version": "6.43.5" - {{- if .Values.keepAddons }} - annotations: - helm.sh/resource-policy: keep - {{- end }} -spec: - description: The leading tool for querying and visualizing time series and metrics. - type: Helm - - helm: - {{- include "kubeblocks.addonChartLocationURL" ( dict "name" "grafana" "version" "6.43.5" "values" .Values) | indent 4 }} - {{- include "kubeblocks.addonChartsImage" . | indent 4 }} - {{- include "kubeblocks.addonHelmInstallOptions" (dict "version" "6.43.5" "values" .Values) | indent 4 }} - - installValues: - configMapRefs: - - name: grafana-chart-kubeblocks-values - key: values-kubeblocks-override.yaml - - valuesMapping: - valueMap: - replicaCount: replicas - storageClass: persistence.storageClassName - persistentVolumeEnabled: persistence.enabled - - jsonMap: - tolerations: tolerations - - resources: - storage: persistence.size - cpu: - requests: resources.requests.cpu - limits: resources.limits.cpu - memory: - requests: resources.requests.memory - limits: resources.limits.memory - - defaultInstallValues: - - replicas: 1 - resources: - requests: - storage: 1Gi - {{- with .Values.tolerations }} - tolerations: {{ toJson . | quote }} - {{- end }} - - - selectors: - - key: KubeGitVersion - operator: Contains - values: - - aliyun - replicas: 1 - resources: - requests: - storage: 20Gi - {{- with .Values.tolerations }} - tolerations: {{ toJson . | quote }} - {{- end }} - - installable: - autoInstall: {{ .Values.grafana.enabled }} -{{- end }} diff --git a/deploy/helm/templates/applications/grafana-values.yaml b/deploy/helm/templates/applications/grafana-values.yaml deleted file mode 100644 index 312a79dd6e7..00000000000 --- a/deploy/helm/templates/applications/grafana-values.yaml +++ /dev/null @@ -1,29 +0,0 @@ -{{- if has "grafana" .Values.autoInstalledAddons }} -{{- $imageRegistry := include "kubeblocks.imageRegistry" . }} -apiVersion: v1 -kind: ConfigMap -metadata: - name: grafana-chart-kubeblocks-values - labels: - {{- include "kubeblocks.labels" . | nindent 4 }} - {{- if .Values.keepAddons }} - annotations: - helm.sh/resource-policy: keep - {{- end }} -data: - values-kubeblocks-override.yaml: |- - {{- $grafana := get .Values "grafana" }} - {{- $image := get $grafana "image" }} - {{- if not $image.repository }} - {{- $image = set $image "repository" (printf "%s/apecloud/grafana" $imageRegistry) }} - {{- end }} - {{- $grafana = set $grafana "image" $image }} - {{- $sidecar := get $grafana "sidecar" }} - {{- $sidecarImage := get $sidecar "image" }} - {{- if not $sidecarImage.repository }} - {{- $sidecarImage = set $sidecarImage "repository" (printf "%s/apecloud/k8s-sidecar" $imageRegistry) }} - {{- end }} - {{- $sidecar = set $sidecar "image" $sidecarImage }} - {{- $grafana = set $grafana "sidecar" $sidecar }} - {{- toYaml $grafana | nindent 4 }} -{{- end }} \ No newline at end of file diff --git a/deploy/helm/templates/applications/prometheus-addon.yaml b/deploy/helm/templates/applications/prometheus-addon.yaml deleted file mode 100644 index b5d959ee415..00000000000 --- a/deploy/helm/templates/applications/prometheus-addon.yaml +++ /dev/null @@ -1,142 +0,0 @@ -{{- if has "prometheus" .Values.autoInstalledAddons }} -apiVersion: extensions.kubeblocks.io/v1alpha1 -kind: Addon -metadata: - name: {{ include "addon.prometheus.name" . }} - labels: - {{- include "kubeblocks.labels" . | nindent 4 }} - "addon.kubeblocks.io/provider": community - "addon.kubeblocks.io/version": "15.16.1" - {{- if .Values.keepAddons }} - annotations: - helm.sh/resource-policy: keep - {{- end }} -spec: - description: Prometheus is a monitoring system and time series database. - type: Helm - - helm: - {{- include "kubeblocks.addonChartLocationURL" ( dict "name" "prometheus" "version" "15.16.1" "values" .Values) | indent 4 }} - {{- include "kubeblocks.addonChartsImage" . | indent 4 }} - {{- include "kubeblocks.addonHelmInstallOptions" (dict "version" "15.16.1" "values" .Values) | indent 4 }} - - installValues: - configMapRefs: - - name: {{ include "addon.prometheus.name" . }}-chart-kubeblocks-values - key: values-kubeblocks-override.yaml - - valuesMapping: - valueMap: - replicaCount: server.replicaCount - storageClass: server.persistentVolume.storageClass - persistentVolumeEnabled: server.persistentVolume.enabled - - jsonMap: - tolerations: server.tolerations - - resources: - storage: server.persistentVolume.size - cpu: - requests: server.resources.requests.cpu - limits: server.resources.limits.cpu - memory: - requests: server.resources.requests.memory - limits: server.resources.limits.memory - extras: - - name: alertmanager - valueMap: - replicaCount: alertmanager.replicaCount - storageClass: alertmanager.persistentVolume.storageClass - persistentVolumeEnabled: alertmanager.persistentVolume.enabled - - jsonMap: - tolerations: alertmanager.tolerations - - resources: - storage: alertmanager.persistentVolume.size - cpu: - requests: alertmanager.resources.requests.cpu - limits: alertmanager.resources.limits.cpu - memory: - requests: alertmanager.resources.requests.memory - limits: alertmanager.resources.limits.memory - - defaultInstallValues: - - replicas: 1 - resources: - requests: - storage: 20Gi - memory: 512Mi - limits: - memory: 4Gi - {{- with .Values.tolerations }} - tolerations: {{ toJson . | quote }} - {{- end }} - - extras: - - name: alertmanager - replicas: 1 - resources: - requests: - storage: 4Gi - {{- with .Values.tolerations }} - tolerations: {{ toJson . | quote }} - {{- end }} - - # for ACK, the smallest storage size is 20Gi, the format of GitVersion is v1.24.6-aliyun.1 - - selectors: - - key: KubeGitVersion - operator: Contains - values: - - aliyun - replicas: 1 - resources: - requests: - storage: 20Gi - memory: 512Mi - limits: - memory: 4Gi - {{- with .Values.tolerations }} - tolerations: {{ toJson . | quote }} - {{- end }} - - extras: - - name: alertmanager - replicas: 1 - resources: - requests: - storage: 20Gi - {{- with .Values.tolerations }} - tolerations: {{ toJson . | quote }} - {{- end }} - - # for TKE, the smallest storage size is 10Gi, the format of GitVersion is v1.24.4-tke.5 - - selectors: - - key: KubeGitVersion - operator: Contains - values: - - tke - replicas: 1 - resources: - requests: - storage: 20Gi - memory: 512Mi - limits: - memory: 4Gi - {{- with .Values.tolerations }} - tolerations: {{ toJson . | quote }} - {{- end }} - - extras: - - name: alertmanager - replicas: 1 - resources: - requests: - storage: 10Gi - {{- with .Values.tolerations }} - tolerations: {{ toJson . | quote }} - {{- end }} - - installable: - autoInstall: {{ .Values.prometheus.enabled }} -{{- end }} diff --git a/deploy/helm/templates/applications/prometheus-values.yaml b/deploy/helm/templates/applications/prometheus-values.yaml deleted file mode 100644 index 8fe54be5a64..00000000000 --- a/deploy/helm/templates/applications/prometheus-values.yaml +++ /dev/null @@ -1,58 +0,0 @@ -{{- if has "prometheus" .Values.autoInstalledAddons }} - {{- $imageRegistry := include "kubeblocks.imageRegistry" . }} -apiVersion: v1 -kind: ConfigMap -metadata: - name: {{ include "addon.prometheus.name" . }}-chart-kubeblocks-values - labels: - {{- include "kubeblocks.labels" . | nindent 4 }} - {{- if .Values.keepAddons }} - annotations: - helm.sh/resource-policy: keep - {{- end }} -data: - values-kubeblocks-override.yaml: |- - {{- $prometheus := get .Values "prometheus" }} - # set prometheus.alertmanager.image.repository - {{- $alertmanager := get $prometheus "alertmanager" }} - {{- $alertmanagerImage := get $alertmanager "image" }} - {{- if not $alertmanagerImage.repository }} - {{- $alertmanagerImage = set $alertmanagerImage "repository" (printf "%s/apecloud/alertmanager" $imageRegistry) }} - {{- end }} - {{- $alertmanager = set $alertmanager "image" $alertmanagerImage }} - {{- $prometheus = set $prometheus "alertmanager" $alertmanager }} - # set prometheus.nodeExporter.image.repository - {{- $nodeExporter := get $prometheus "nodeExporter" }} - {{- $nodeExporterImage := get $nodeExporter "image" }} - {{- if not $nodeExporterImage.repository }} - {{- $nodeExporterImage = set $nodeExporterImage "repository" (printf "%s/apecloud/node-exporter" $imageRegistry) }} - {{- end }} - {{- $nodeExporter = set $nodeExporter "image" $nodeExporterImage }} - {{- $prometheus = set $prometheus "nodeExporter" $nodeExporter }} - # set prometheus configmapReload prometheus and alertmanager image.repository - {{- $configmapReload := get $prometheus "configmapReload" }} - {{- $cmReloadPrometheus := get $configmapReload "prometheus" }} - {{- $cmPrometheusImage := get $cmReloadPrometheus "image" }} - {{- if not $cmPrometheusImage.repository }} - {{- $cmPrometheusImage = set $cmPrometheusImage "repository" (printf "%s/apecloud/configmap-reload" $imageRegistry) }} - {{- end }} - {{- $cmReloadPrometheus = set $cmReloadPrometheus "image" $cmPrometheusImage }} - {{- $configmapReload = set $configmapReload "prometheus" $cmReloadPrometheus }} - {{- $cmReloadalertmanager := get $configmapReload "alertmanager" }} - {{- $cmAlertmanagerImage := get $cmReloadalertmanager "image" }} - {{- if not $cmAlertmanagerImage.repository }} - {{- $cmAlertmanagerImage = set $cmAlertmanagerImage "repository" (printf "%s/apecloud/configmap-reload" $imageRegistry) }} - {{- end }} - {{- $cmReloadalertmanager = set $cmReloadalertmanager "image" $cmAlertmanagerImage }} - {{- $configmapReload = set $configmapReload "prometheus" $cmReloadalertmanager }} - {{- $prometheus = set $prometheus "configmapReload" $configmapReload }} - # set prometheus.server.image.repository - {{- $server := get $prometheus "server" }} - {{- $serverImage := get $server "image" }} - {{- if not $serverImage.repository }} - {{- $serverImage = set $serverImage "repository" (printf "%s/apecloud/prometheus" $imageRegistry) }} - {{- end }} - {{- $server = set $server "image" $serverImage }} - {{- $prometheus = set $prometheus "server" $server }} - {{- toYaml $prometheus | nindent 4 }} -{{- end }} \ No newline at end of file diff --git a/deploy/helm/templates/applications/vmagent-addon.yaml b/deploy/helm/templates/applications/vmagent-addon.yaml deleted file mode 100644 index 7b8fdff1ffe..00000000000 --- a/deploy/helm/templates/applications/vmagent-addon.yaml +++ /dev/null @@ -1,51 +0,0 @@ -{{- if has "victoria-metrics-agent" .Values.autoInstalledAddons }} -apiVersion: extensions.kubeblocks.io/v1alpha1 -kind: Addon -metadata: - name: victoria-metrics-agent - labels: - {{- include "kubeblocks.labels" . | nindent 4 }} - "addon.kubeblocks.io/provider": community - "addon.kubeblocks.io/version": "0.8.41" - {{- if .Values.keepAddons }} - annotations: - helm.sh/resource-policy: keep - {{- end }} -spec: - description: 'vmagent is a tiny agent which helps you collect metrics from various sources, relabel and filter the collected metrics and store them in VictoriaMetrics or any other storage systems via Prometheus remote_write protocol.' - type: Helm - - helm: - {{- include "kubeblocks.addonChartLocationURL" ( dict "name" "victoria-metrics-agent" "version" "0.8.41" "values" .Values) | indent 4 }} - {{- include "kubeblocks.addonChartsImage" . | indent 4 }} - {{- include "kubeblocks.addonHelmInstallOptions" (dict "version" "0.8.41" "values" .Values) | indent 4 }} - - installValues: - configMapRefs: - - name: victoria-metrics-agent-chart-kubeblocks-values - key: values-kubeblocks-override.yaml - - valuesMapping: - valueMap: - replicaCount: replicaCount - - jsonMap: - tolerations: tolerations - - resources: - cpu: - requests: resources.requests.cpu - limits: resources.limits.cpu - memory: - requests: resources.requests.memory - limits: resources.limits.memory - - defaultInstallValues: - - replicas: 1 - {{- with .Values.tolerations }} - tolerations: {{ toJson . | quote }} - {{- end }} - - installable: - autoInstall: false -{{- end }} diff --git a/deploy/helm/templates/applications/vmagent-values.yaml b/deploy/helm/templates/applications/vmagent-values.yaml deleted file mode 100644 index fa457a632d2..00000000000 --- a/deploy/helm/templates/applications/vmagent-values.yaml +++ /dev/null @@ -1,16 +0,0 @@ -{{- if has "victoria-metrics-agent" .Values.autoInstalledAddons }} -{{- $imageRegistry := include "kubeblocks.imageRegistry" . }} -apiVersion: v1 -kind: ConfigMap -metadata: - name: victoria-metrics-agent-chart-kubeblocks-values - labels: - {{- include "kubeblocks.labels" . | nindent 4 }} - {{- if .Values.keepAddons }} - annotations: - helm.sh/resource-policy: keep - {{- end }} -data: - values-kubeblocks-override.yaml: |- - {{- .Values.vmagent | toYaml | nindent 4 }} -{{- end }} \ No newline at end of file diff --git a/deploy/helm/templates/grafana/configmap-dashboards.yaml b/deploy/helm/templates/grafana/configmap-dashboards.yaml deleted file mode 100644 index ed5d689e8e6..00000000000 --- a/deploy/helm/templates/grafana/configmap-dashboards.yaml +++ /dev/null @@ -1,24 +0,0 @@ -{{- if .Values.grafana.sidecar.dashboards.enabled }} -{{- $files := .Files.Glob "dashboards/*.json" }} -{{- if $files }} -apiVersion: v1 -kind: ConfigMapList -items: -{{- range $path, $fileContents := $files }} -{{- $dashboardName := regexReplaceAll "(^.*/)(.*)\\.json$" $path "${2}" }} -- apiVersion: v1 - kind: ConfigMap - metadata: - name: {{ printf "%s-grafana-%s" (include "kubeblocks.fullname" $) $dashboardName | trunc 63 | trimSuffix "-" }} - namespace: {{ template "kubeblocks.grafana.namespace" $ }} - labels: - {{- if $.Values.grafana.sidecar.dashboards.label }} - {{ $.Values.grafana.sidecar.dashboards.label }}: {{ ternary $.Values.grafana.sidecar.dashboards.labelValue "1" (not (empty $.Values.grafana.sidecar.dashboards.labelValue)) | quote }} - {{- end }} - app: {{ template "kubeblocks.name" $ }}-grafana -{{ include "kubeblocks.labels" $ | indent 6 }} - data: - {{ $dashboardName }}.json: {{ $.Files.Get $path | toJson }} -{{- end }} -{{- end }} -{{- end }} diff --git a/deploy/helm/templates/grafana/configmaps-datasources.yaml b/deploy/helm/templates/grafana/configmaps-datasources.yaml deleted file mode 100644 index c84384815d4..00000000000 --- a/deploy/helm/templates/grafana/configmaps-datasources.yaml +++ /dev/null @@ -1,46 +0,0 @@ -{{- if .Values.grafana.sidecar.datasources.enabled }} -apiVersion: v1 -kind: ConfigMap -metadata: - name: {{ template "kubeblocks.fullname" . }}-grafana-datasource - namespace: {{ template "kubeblocks.grafana.namespace" . }} - annotations: -{{ toYaml .Values.grafana.sidecar.datasources.annotations | indent 4 }} - labels: - {{- if $.Values.grafana.sidecar.datasources.label }} - {{ $.Values.grafana.sidecar.datasources.label }}: {{ ternary $.Values.grafana.sidecar.datasources.labelValue "1" (not (empty $.Values.grafana.sidecar.datasources.labelValue)) | quote }} - {{- end }} - app: {{ template "kubeblocks.name" $ }}-grafana-datasource -{{ include "kubeblocks.labels" $ | indent 4 }} -data: - datasource.yaml: |- - apiVersion: 1 - datasources: -{{- $scrapeInterval := default .Values.prometheus.server.global.scrape_interval | default "30s" }} -{{- if .Values.grafana.sidecar.datasources.defaultDatasourceEnabled }} - - name: Prometheus - type: prometheus - uid: {{ .Values.grafana.sidecar.datasources.uid }} - {{- if .Values.grafana.sidecar.datasources.url }} - url: {{ .Values.grafana.sidecar.datasources.url }} - {{- else }} - url: http://kb-addon-{{ include "addon.prometheus.name" . }}-server.{{ template "kubeblocks.prometheus.namespace" . }}:{{ .Values.prometheus.server.service.servicePort }}/{{ trimPrefix "/" .Values.prometheus.server.routePrefix }} - {{- end }} - access: proxy - isDefault: true - jsonData: - timeInterval: {{ $scrapeInterval }} - - name: Prometheus-15s - type: prometheus - uid: {{ .Values.grafana.sidecar.datasources.uid }}-15 - {{- if .Values.grafana.sidecar.datasources.url }} - url: {{ .Values.grafana.sidecar.datasources.url }} - {{- else }} - url: http://kb-addon-{{ include "addon.prometheus.name" . }}-server.{{ template "kubeblocks.prometheus.namespace" . }}:{{ .Values.prometheus.server.service.servicePort }}/{{ trimPrefix "/" .Values.prometheus.server.routePrefix }} - {{- end }} - access: proxy - isDefault: false - jsonData: - timeInterval: 15s -{{- end }} -{{- end }} diff --git a/deploy/helm/templates/prometheus/alertmanager.yaml b/deploy/helm/templates/prometheus/alertmanager.yaml deleted file mode 100644 index 24a8af36e83..00000000000 --- a/deploy/helm/templates/prometheus/alertmanager.yaml +++ /dev/null @@ -1,24 +0,0 @@ -{{- if not (empty .Values.prometheus.alertmanager.configMapOverrideName) }} -apiVersion: v1 -kind: ConfigMap -metadata: - labels: - {{- include "kubeblocks.labels" . | nindent 4 }} - name: kb-addon-{{ include "addon.prometheus.name" . }}-{{ .Values.prometheus.alertmanager.configMapOverrideName }} -data: - alertmanager.yml: | - global: { } - receivers: - - name: default-receiver - route: - group_by: [ 'alertname', 'namespace', 'app_kubernetes_io_instance' ] - group_interval: 30s - group_wait: 5s - receiver: default-receiver - repeat_interval: 10m - routes: - - receiver: default-receiver - group_by: ['alertname', 'instance', 'pod'] - matchers: - - alertname=~"Container.*" - {{- end -}} \ No newline at end of file diff --git a/deploy/helm/templates/prometheus/monitor.yaml b/deploy/helm/templates/prometheus/monitor.yaml deleted file mode 100644 index e2e5d5103ac..00000000000 --- a/deploy/helm/templates/prometheus/monitor.yaml +++ /dev/null @@ -1,21 +0,0 @@ -{{- if and (.Capabilities.APIVersions.Has "monitoring.coreos.com/v1/ServiceMonitor") .Values.serviceMonitor.enabled }} -# Prometheus Monitor Service (Metrics) -apiVersion: monitoring.coreos.com/v1 -kind: ServiceMonitor -metadata: - labels: - {{- include "kubeblocks.labels" . | nindent 4 }} - control-plane: controller-manager - name: {{ include "kubeblocks.fullname" . }}-controller-manager-metrics-monitor -spec: - endpoints: - - path: /metrics - port: metrics - scheme: https - bearerTokenFile: /var/run/secrets/kubernetes.io/serviceaccount/token - tlsConfig: - insecureSkipVerify: true - selector: - matchLabels: - control-plane: controller-manager -{{- end }} \ No newline at end of file diff --git a/deploy/helm/templates/prometheus/webhook-adaptor.yaml b/deploy/helm/templates/prometheus/webhook-adaptor.yaml deleted file mode 100644 index aa89a6e0cd9..00000000000 --- a/deploy/helm/templates/prometheus/webhook-adaptor.yaml +++ /dev/null @@ -1,11 +0,0 @@ -{{- if not (empty (index .Values "alertmanager-webhook-adaptor" "configMapOverrideName")) }} -apiVersion: v1 -kind: ConfigMap -metadata: - labels: - {{- include "kubeblocks.labels" . | nindent 4 }} - name: kb-addon-{{ include "addon.alertmanager-webhook-adaptor.name" . }}-{{index .Values "alertmanager-webhook-adaptor" "configMapOverrideName"}} -data: - config.yml: | - receivers: [ ] -{{- end -}} \ No newline at end of file diff --git a/deploy/helm/values.yaml b/deploy/helm/values.yaml index b41b4bd952a..8d13c48f79c 100644 --- a/deploy/helm/values.yaml +++ b/deploy/helm/values.yaml @@ -317,6 +317,13 @@ dataPlane: values: - "true" +# dynamically replace instance's registry. ref: https://github.com/apecloud/kubeblocks/pull/8018 +# e.g. +# registryConfig: +# defaultRegistry: apecloud-registry.cn-zhangjiakou.cr.aliyuncs.com +# defaultNamespace: apecloud +registryConfig: {} + # Add extra pod labels to KubeBlocks Deployment extraLabels: {} @@ -489,1199 +496,7 @@ autoInstalledAddons: - "qdrant" - "redis" - "rabbitmq" - - "alertmanager-webhook-adaptor" - - "aws-load-balancer-controller" - - "csi-hostpath-driver" - - "csi-driver-nfs" - - "grafana" - - "prometheus" - "snapshot-controller" - - "victoria-metrics-agent" - -## Prometheus Addon -## -prometheus: - ## If false, prometheus sub-chart will not be installed - ## - enabled: false - - alertmanager: - ## If false, alertmanager will not be installed - ## - enabled: false - - ## alertmanager container image - ## - image: - # If the value of prometheus.alertmanager.image.repository is not specified using --set, it will be set to the value of '${image.registry}/apecloud/alertmanager'. - repository: "" - tag: v0.24.0 - - ## ConfigMap override where fullname is {{.Release.Name}}-{{.Values.alertmanager.configMapOverrideName}} - ## Defining configMapOverrideName will cause templates/alertmanager-configmap.yaml - ## to NOT generate a ConfigMap resource - ## - configMapOverrideName: "alertmanager-config" - - ## Node tolerations for alertmanager scheduling to nodes with taints - ## Ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ - ## - tolerations: - - key: kb-controller - operator: Equal - value: "true" - effect: NoSchedule - - affinity: - nodeAffinity: - preferredDuringSchedulingIgnoredDuringExecution: - - weight: 100 - preference: - matchExpressions: - - key: kb-controller - operator: In - values: - - "true" - - persistentVolume: - ## If true, alertmanager will create/use a Persistent Volume Claim - ## If false, use emptyDir - ## - enabled: false - - ## alertmanager data Persistent Volume size - ## - size: 1Gi - - ## alertmanager data Persistent Volume Storage Class - ## If defined, storageClassName: - ## If set to "-", storageClassName: "", which disables dynamic provisioning - ## If undefined (the default) or set to null, no storageClassName spec is - ## set, choosing the default provisioner. (gp2 on AWS, standard on - ## GKE, AWS & OpenStack) - ## - # storageClass: "-" - - ## Use a StatefulSet if replicaCount needs to be greater than 1 (see below) - ## - replicaCount: 1 - - statefulSet: - ## If true, use a statefulset instead of a deployment for pod management. - ## This allows to scale replicas to more than 1 pod - ## - enabled: true - - ## Alertmanager headless service to use for the statefulset - ## - headless: - ## Enabling peer mesh service end points for enabling the HA alert manager - ## Ref: https://github.com/prometheus/alertmanager/blob/master/README.md - enableMeshPeer: true - - ## alertmanager resource requests and limits - ## Ref: http://kubernetes.io/docs/user-guide/compute-resources/ - ## - resources: {} - # limits: - # cpu: 10m - # memory: 32Mi - # requests: - # cpu: 10m - # memory: 32Mi - - ## Security context to be added to alertmanager pods - ## - securityContext: - runAsUser: 0 - runAsNonRoot: false - runAsGroup: 65534 - fsGroup: 65534 - - containerSecurityContext: - allowPrivilegeEscalation: false - - ingress: - ## If true, alertmanager Ingress will be created - ## - enabled: false - - # For Kubernetes >= 1.18 you should specify the ingress-controller via the field ingressClassName - # See https://kubernetes.io/blog/2020/04/02/improvements-to-the-ingress-api-in-kubernetes-1.18/#specifying-the-class-of-an-ingress - # ingressClassName: nginx - - ## alertmanager Ingress annotations - ## - annotations: {} - # kubernetes.io/ingress.class: nginx - # kubernetes.io/tls-acme: 'true' - - ## alertmanager Ingress additional labels - ## - extraLabels: {} - - ## alertmanager Ingress hostnames with optional path - ## Must be provided if Ingress is enabled - ## - hosts: [] - # - alertmanager.domain.com - # - domain.com/alertmanager - - path: / - - # pathType is only for k8s >= 1.18 - pathType: Prefix - - ## Extra paths to prepend to every host configuration. This is useful when working with annotation based services. - extraPaths: [] - # - path: /* - # backend: - # serviceName: ssl-redirect - # servicePort: use-annotation - - ## alertmanager Ingress TLS configuration - ## Secrets must be manually created in the namespace - ## - tls: [] - # - secretName: prometheus-alerts-tls - # hosts: - # - alertmanager.domain.com - - service: - annotations: {} - labels: {} - clusterIP: "" - - ## Enabling peer mesh service end points for enabling the HA alert manager - ## Ref: https://github.com/prometheus/alertmanager/blob/master/README.md - # enableMeshPeer : true - - ## List of IP addresses at which the alertmanager service is available - ## Ref: https://kubernetes.io/docs/user-guide/services/#external-ips - ## - externalIPs: [] - - loadBalancerIP: "" - loadBalancerSourceRanges: [] - servicePort: 80 - # nodePort: 30000 - sessionAffinity: None - type: ClusterIP - - - kubeStateMetrics: - ## If false, kube-state-metrics sub-chart will not be installed - ## - enabled: false - - nodeExporter: - ## If false, node-exporter will not be installed - ## - enabled: false - - ## node-exporter container image - ## - image: - # If the value of prometheus.nodeExporter.image.repository is not specified using --set, it will be set to the value of '${image.registry}/apecloud/node-exporter'. - repository: "" - tag: v1.3.1 - - configmapReload: - prometheus: - ## configmap-reload container image - ## - image: - # If the value of prometheus.configmapReload.prometheus.image.repository is not specified using --set, - # it will be set to the value of '${image.registry}/apecloud/configmap-reload'. - repository: "" - tag: v0.5.0 - alertmanager: - ## configmap-reload container image - ## - image: - # If the value of prometheus.configmapReload.alertmanager.image.repository is not specified using --set, - # it will be set to the value of '${image.registry}/apecloud/configmap-reload'. - repository: "" - tag: v0.5.0 - - server: - ## Prometheus server container name - ## - enabled: true - - ## Prometheus server container image - ## - image: - # If the value of prometheus.server.image.repository is not specified using --set, - # it will be set to the value of '${image.registry}/apecloud/prometheus'. - repository: "" - tag: v2.44.0 - - global: - ## How frequently to scrape targets by default - ## - scrape_interval: 15s - ## How long until a scrape request times out - ## - scrape_timeout: 10s - ## How frequently to evaluate rules - ## - evaluation_interval: 15s - - ## Additional Prometheus server container flags - ## - extraFlags: - - web.enable-lifecycle - - web.enable-remote-write-receiver - - ## Additional Prometheus server container arguments - ## - extraArgs: - log.level: info - storage.tsdb.min-block-duration: 30m - enable-feature: memory-snapshot-on-shutdown - storage.tsdb.retention.size: 10GB - - ## https://prometheus.io/docs/prometheus/latest/configuration/configuration/#remote_write - ## - remoteWrite: [] - - ## Prefix used to register routes, overriding externalUrl route. - ## Useful for proxies that rewrite URLs. - ## - routePrefix: / - - ## Node tolerations for server scheduling to nodes with taints - ## Ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ - ## - tolerations: - - key: kb-controller - operator: Equal - value: "true" - effect: NoSchedule - - affinity: - nodeAffinity: - preferredDuringSchedulingIgnoredDuringExecution: - - weight: 100 - preference: - matchExpressions: - - key: kb-controller - operator: In - values: - - "true" - - persistentVolume: - ## If true, Prometheus server will create/use a Persistent Volume Claim - ## If false, use emptyDir - ## - enabled: false - - ## Prometheus server data Persistent Volume size - ## - size: 20Gi - - ## Prometheus server data Persistent Volume Storage Class - ## If defined, storageClassName: - ## If set to "-", storageClassName: "", which disables dynamic provisioning - ## If undefined (the default) or set to null, no storageClassName spec is - ## set, choosing the default provisioner. (gp2 on AWS, standard on - ## GKE, AWS & OpenStack) - ## - # storageClass: "-" - - ## Use a StatefulSet if replicaCount needs to be greater than 1 (see below) - ## - replicaCount: 1 - - statefulSet: - ## If true, use a statefulset instead of a deployment for pod management. - ## This allows to scale replicas to more than 1 pod - ## - enabled: true - - ## Prometheus server resource requests and limits - ## Ref: http://kubernetes.io/docs/user-guide/compute-resources/ - ## - resources: {} - # limits: - # cpu: 500m - # memory: 512Mi - # requests: - # cpu: 500m - # memory: 512Mi - - ## Prometheus' data retention period (default if not specified is 15 days) - ## - retention: "2d" - - ## Security context to be added to server pods - ## - securityContext: - runAsUser: 0 - runAsNonRoot: false - runAsGroup: 65534 - fsGroup: 65534 - - containerSecurityContext: - allowPrivilegeEscalation: false - - service: - ## If false, no Service will be created for the Prometheus server - ## - enabled: true - - annotations: {} - labels: {} - clusterIP: "" - - ## List of IP addresses at which the Prometheus server service is available - ## Ref: https://kubernetes.io/docs/user-guide/services/#external-ips - ## - externalIPs: [] - - loadBalancerIP: "" - loadBalancerSourceRanges: [] - servicePort: 80 - sessionAffinity: None - type: ClusterIP - - ## Enable gRPC port on service to allow auto discovery with thanos-querier - gRPC: - enabled: false - servicePort: 10901 - # nodePort: 10901 - - ## If using a statefulSet (statefulSet.enabled=true), configure the - ## service to connect to a specific replica to have a consistent view - ## of the data. - statefulsetReplica: - enabled: false - replica: 0 - - ingress: - ## If true, Prometheus server Ingress will be created - ## - enabled: false - - # For Kubernetes >= 1.18 you should specify the ingress-controller via the field ingressClassName - # See https://kubernetes.io/blog/2020/04/02/improvements-to-the-ingress-api-in-kubernetes-1.18/#specifying-the-class-of-an-ingress - # ingressClassName: nginx - - ## Prometheus server Ingress annotations - ## - annotations: {} - # kubernetes.io/ingress.class: nginx - # kubernetes.io/tls-acme: 'true' - - ## Prometheus server Ingress additional labels - ## - extraLabels: {} - - ## Prometheus server Ingress hostnames with optional path - ## Must be provided if Ingress is enabled - ## - hosts: [] - # - prometheus.domain.com - # - domain.com/prometheus - - path: / - - # pathType is only for k8s >= 1.18 - pathType: Prefix - - ## Extra paths to prepend to every host configuration. This is useful when working with annotation based services. - extraPaths: [] - # - path: /* - # backend: - # serviceName: ssl-redirect - # servicePort: use-annotation - - ## Prometheus server Ingress TLS configuration - ## Secrets must be manually created in the namespace - ## - tls: [] - # - secretName: prometheus-server-tls - # hosts: - # - prometheus.domain.com - - ## AlertManager ConfigMap Entries - ## NOTE: Please review these carefully as thresholds and behavior may not meet - ## your SLOs or labels. - ## - alertmanagerFiles: - alertmanager.yml: - global: {} - - receivers: - - name: default-receiver - - route: - receiver: default-receiver - group_wait: 5s - group_interval: 30s - repeat_interval: 10m - - ## Sample prometheus rules/alerts - ## NOTE: Please review these carefully as thresholds and behavior may not meet - ## your SLOs or labels. - ## - ruleFiles: - kubelet_alert_rules.yml: | - groups: - - name: KubeletSummary - rules: - - alert: ContainerCpuUsageWarning - expr: 'rate(container_cpu_time_seconds_total[2m]) / container_cpu_limit * 100 > 70' - for: 2m - labels: - severity: warning - annotations: - summary: 'Container CPU usage is high (> 70%)' - description: 'Container CPU usage is {{ $value | printf "%.2f" }} percent. (pod: {{ $labels.k8s_pod_name }}, container: {{ $labels.k8s_container_name }})' - - - alert: ContainerCpuUsageCritical - expr: 'rate(container_cpu_time_seconds_total[2m]) / container_cpu_limit * 100 > 90' - for: 1m - labels: - severity: critical - annotations: - summary: 'Container CPU usage is very high (> 90%)' - description: 'Container CPU usage is {{ $value | printf "%.2f" }} percent. (pod: {{ $labels.k8s_pod_name }}, container: {{ $labels.k8s_container_name }})' - - - alert: ContainerMemoryUsage - expr: 'container_memory_working_set_bytes / container_memory_limit_bytes * 100 > 90' - for: 2m - labels: - severity: warning - annotations: - summary: 'Container Memory usage is high (> 90%)' - description: 'Container Memory usage is {{ $value | printf "%.2f" }} percent. (pod: {{ $labels.k8s_pod_name }}, container: {{ $labels.k8s_container_name }})' - - - alert: ContainerMemoryUsagePredict - expr: 'predict_linear(container_memory_working_set_bytes[15m], 30*60) - container_memory_limit_bytes > 0' - for: 5m - labels: - severity: critical - annotations: - summary: 'Container Memory predict usage may exceed the limit 30 minutes later' - description: 'Container Memory predict usage may exceed the limit 30 minutes later, the predict value is {{ $value | humanize1024 }}. (pod: {{ $labels.k8s_pod_name }}, container: {{ $labels.k8s_container_name }})' - - - alert: ContainerVolumeUsage - expr: '(k8s_volume_capacity_bytes - k8s_volume_available_bytes) / k8s_volume_capacity_bytes * 100 > 90' - for: 2m - labels: - severity: warning - annotations: - summary: 'Volume usage is high (> 90%)' - description: 'Volume usage is {{ $value | printf "%.2f" }} percent. (pod: {{ $labels.k8s_pod_name }}, volume: {{ $labels.k8s_volume_name }})' - - mysql_alert_rules.yml: | - groups: - - name: MysqldExporter - rules: - - alert: MysqlDown - expr: 'max_over_time(mysql_up[1m]) == 0' - for: 0m - labels: - severity: critical - annotations: - summary: 'MySQL is down' - description: 'MySQL is down. (instance: {{ $labels.pod }})' - - - alert: MysqlRestarted - expr: 'mysql_global_status_uptime < 60' - for: 0m - labels: - severity: info - annotations: - summary: 'MySQL has just been restarted (< 60s)' - description: 'MySQL has just been restarted {{ $value | printf "%.1f" }} seconds ago. (instance: {{ $labels.pod }})' - - - alert: MysqlTooManyConnections - expr: 'sum(max_over_time(mysql_global_status_threads_connected[1m]) / mysql_global_variables_max_connections) BY (namespace,app_kubernetes_io_instance,pod) * 100 > 80' - for: 2m - labels: - severity: warning - annotations: - summary: 'MySQL has too many connections (> 80%)' - description: '{{ $value | printf "%.2f" }} percent of MySQL connections are in use. (instance: {{ $labels.pod }})' - - - alert: MysqlReplicationLag - expr: |- - max by(namespace,app_kubernetes_io_instance,pod) ( - max_over_time(mysql_replication_heartbeat_relay_delay_seconds{replication_role=~"slave"}[2m]) - ) > 3600 - for: 2m - labels: - severity: warning - annotations: - summary: 'MySQL replication lag delay exceeds one hour' - description: 'mysql replication relay latency: {{ $value | printf "%.2f" }}. (instance: {{ $labels.pod }})' - - - alert: MysqlConnectionErrors - expr: 'sum(increase(mysql_global_status_connection_errors_total[1m])) BY (namespace,app_kubernetes_io_instance,pod) > 0' - for: 2m - labels: - severity: warning - annotations: - summary: 'MySQL connection errors' - description: 'MySQL has connection errors and the value is {{ $value | printf "%.2f" }}. (instance: {{ $labels.pod }})' - - - alert: MysqlHighThreadsRunning - expr: 'sum(max_over_time(mysql_global_status_threads_running[1m]) / mysql_global_variables_max_connections) BY (namespace,app_kubernetes_io_instance,pod) * 100 > 60' - for: 2m - labels: - severity: warning - annotations: - summary: 'MySQL high threads running (> 60%)' - description: '{{ $value | printf "%.2f" }} percent of MySQL connections are in running state. (instance: {{ $labels.pod }})' - - - alert: MysqlSlowQueries - expr: 'sum(increase(mysql_global_status_slow_queries[1m])) BY (namespace,app_kubernetes_io_instance,pod) > 0' - for: 2m - labels: - severity: info - annotations: - summary: 'MySQL slow queries' - description: 'MySQL server has {{ $value | printf "%.2f" }} slow query. (instance: {{ $labels.pod }})' - - - alert: MysqlInnodbLogWaits - expr: 'sum(rate(mysql_global_status_innodb_log_waits[5m])) BY (namespace,app_kubernetes_io_instance,pod) > 10' - for: 2m - labels: - severity: warning - annotations: - summary: 'MySQL InnoDB log waits (> 10)' - description: 'MySQL innodb log writes stalling and the value is {{ $value | printf "%.2f" }}. (instance: {{ $labels.pod }})' - - - alert: MysqlInnodbBufferPoolHits - expr: 'sum(rate(mysql_global_status_innodb_buffer_pool_reads[5m]) / rate(mysql_global_status_innodb_buffer_pool_read_requests[5m])) BY (namespace,app_kubernetes_io_instance,pod) * 100 > 5' - for: 2m - labels: - severity: warning - annotations: - summary: 'MySQL InnoDB high read requests rate hitting disk (> 5%)' - description: 'High number of logical reads that InnoDB could not satisfy from the buffer pool, and had to read directly from disk. The value is {{ $value | printf "%.2f" }} percent. (instance: {{ $labels.pod }})' - - postgresql_alert_rules.yml: | - groups: - - name: PostgreSQLExporter - rules: - - alert: PostgreSQLDown - expr: 'max_over_time(pg_up[1m]) == 0' - for: 0m - labels: - severity: critical - annotations: - summary: 'PostgreSQL is down' - description: 'PostgreSQL is down. (instance: {{ $labels.pod }})' - - - alert: PGReplicationLag - expr: |- - max by(namespace,app_kubernetes_io_instance,pod) ( - max_over_time(pg_replication_lag[2m]) - ) > 3600 - for: 2m - labels: - severity: warning - annotations: - summary: 'PG replication lag delay exceeds one hour' - description: 'PostgresSQL replication relay latency: {{ $value | printf "%.2f" }}. (instance: {{ $labels.pod }})' - - - alert: PostgreSQLRestarted - expr: 'time() - pg_postmaster_start_time_seconds < 60' - for: 0m - labels: - severity: info - annotations: - summary: 'PostgreSQL has just been restarted (< 60s)' - description: 'PostgreSQL has just been restarted {{ $value | printf "%.1f" }} seconds ago. (instance: {{ $labels.pod }})' - - - alert: PostgreSQLExporterError - expr: 'pg_exporter_last_scrape_error > 0' - for: 0m - labels: - severity: warning - annotations: - summary: 'PostgreSQL exporter scrape error' - description: 'PostgreSQL exporter has {{ $value | printf "%.2f" }} scrape errors. A query may be buggy in query.yaml. (instance: {{ $labels.pod }})' - - - alert: PostgreSQLTooManySlowQueries - expr: | - max by(namespace,app_kubernetes_io_instance,pod,datname) ( - max_over_time(pg_stat_activity_max_tx_duration{datname!~"template.*"}[2m]) - ) > 60 - for: 2m - labels: - severity: warning - annotations: - summary: 'PostgreSQL database has high number of slow queries' - description: 'PostgreSQL database has slow queries and the value is {{ $value | printf "%.2f" }}. (instance: {{ $labels.pod }}, database: {{ $labels.datname }})' - - - alert: PostgreSQLTooManyConnections - expr: | - sum by (namespace,app_kubernetes_io_instance,pod) (pg_stat_activity_count{datname!~"template.*"}) - > on(namespace,app_kubernetes_io_instance,pod) - (pg_settings_max_connections - pg_settings_superuser_reserved_connections) * 0.8 - for: 2m - labels: - severity: warning - annotations: - summary: 'PostgreSQL too many connections (> 80%)' - description: 'PostgreSQL has too many connections and the value is {{ $value | printf "%.2f" }} percent. (instance: {{ $labels.pod }})' - - - alert: PostgreSQLDeadLocks - expr: 'increase(pg_stat_database_deadlocks_total{datname!~"template.*", datname!=""}[2m]) > 5' - for: 2m - labels: - severity: warning - annotations: - summary: 'PostgreSQL database has dead locks (> 5)' - description: 'PostgreSQL database has {{ $value | printf "%.2f"}} dead locks. (instance: {{ $labels.pod }}, database: {{ $labels.datname }})' - - - alert: PostgreSQLHighRollbackRate - expr: | - rate(pg_stat_database_xact_rollback_total{datname!~"template.*", datname!=""}[2m]) - / - rate(pg_stat_database_xact_commit_total{datname!~"template.*", datname!=""}[2m]) - > 0.1 - for: 2m - labels: - severity: warning - annotations: - summary: 'PostgreSQL database has high rollback rate (> 10%)' - description: 'Ratio of transactions being aborted compared to committed is {{ $value | printf "%.2f"}} percent. (instance: {{ $labels.pod }}, database: {{ $labels.datname }})' - - - alert: PostgreSQLTooManyLocksAcquired - expr: | - sum by (namespace,app_kubernetes_io_instance,pod) (pg_locks_count) - / on(namespace,app_kubernetes_io_instance,pod) - (pg_settings_max_locks_per_transaction * pg_settings_max_connections) - > 0.2 - for: 2m - labels: - severity: warning - annotations: - summary: 'PostgreSQL has too many locks acquired (> 20%)' - description: 'Too many locks acquired on the database and the value is {{ $value | printf "%.2f" }} percent. (instance: {{ $labels.pod }})' - - - alert: PostgreSQLCacheHitRatio - expr: | - avg by (namespace,app_kubernetes_io_instance,pod,datname) ( - rate(pg_stat_database_blks_hit_total{datname!~"template.*", datname!=""}[2m]) - / - ( - rate( - pg_stat_database_blks_hit_total{datname!~"template.*", datname!=""}[2m] - ) - + - rate( - pg_stat_database_blks_read_total{datname!~"template.*", datname!=""}[2m] - ) - ) - ) < 0.9 - for: 2m - labels: - severity: warning - annotations: - summary: 'PostgreSQL database has low cache hit rate (< 90%)' - description: 'Low cache hit rate and the value is {{ $value | printf "%.2f" }} percent. (instance: {{ $labels.pod }}, database: {{ $labels.datname }})' - - - alert: PostgreSQLMaxWriteBufferReached - expr: 'rate(pg_stat_bgwriter_maxwritten_clean_total[2m]) > 0' - for: 2m - labels: - severity: warning - annotations: - summary: 'PostgreSQL write buffers reached max' - description: 'PostgreSQL background writer stops for max and the value is {{ $value | printf "%.2f" }}. (instance: {{ $labels.pod }})' - - - alert: PostgreSQLHighWALFilesArchiveErrorRate - expr: | - rate(pg_stat_archiver_failed_count_total[2m]) - / ( - rate(pg_stat_archiver_archived_count_total[2m]) + rate(pg_stat_archiver_failed_count_total[2m]) - ) > 0.1 - for: 2m - labels: - severity: warning - annotations: - summary: 'PostgreSQL has high error rate in WAL files archiver(> 10%)' - description: 'PostgreSQL high error rate in WAL files archiver and the value is {{ $value | printf "%.2f" }} percent. (instance: {{ $labels.pod }})' - - - alert: PostgreSQLTableNotAutoVacuumed - expr: | - (pg_stat_user_tables_last_autovacuum > 0) - and - (time() - pg_stat_user_tables_last_autovacuum) - > 24 * 60 * 60 * 10 - for: 0m - labels: - severity: warning - annotations: - summary: 'PostgreSQL table in database has not been auto vacuumed for 10 days' - description: 'Table {{ $labels.relname }} in database has not been auto vacuumed for 10 days. (instance: {{ $labels.pod }}, database: {{ $labels.datname }})' - - - alert: PostgreSQLTableNotAutoAnalyzed - expr: | - (pg_stat_user_tables_last_autoanalyze > 0) - and - (time() - pg_stat_user_tables_last_autoanalyze) - > 24 * 60 * 60 * 10 - for: 0m - labels: - severity: warning - annotations: - summary: 'PostgreSQL table in database has not been auto analyzed for 10 days' - description: 'Table {{ $labels.relname }} in database has not been auto analyzed for 10 days. (instance: {{ $labels.pod }}, database: {{ $labels.datname }})' - - - alert: PostgreSQLTableTooManyDeadTuples - expr: | - (pg_stat_user_tables_n_dead_tup > 10000) - / - (pg_stat_user_tables_n_live_tup + pg_stat_user_tables_n_dead_tup) - >= 0.1 - for: 2m - labels: - severity: warning - annotations: - summary: 'PostgreSQL table in database has too many dead tuples (> 10%)' - description: 'Table {{ $labels.relname }} in database dead tuples is too large and the value is {{ $value | printf "%.2f" }} percent. (instance: {{ $labels.pod }}, database: {{ $labels.datname }})' - - redis_alert_rules.yml: | - groups: - - name: RedisExporter - rules: - - alert: RedisDown - expr: 'redis_up == 0' - for: 5m - labels: - severity: critical - annotations: - summary: 'Redis is down' - description: 'Redis is down. (instance: {{ $labels.pod }})' - - - alert: RedisCPUHigh - expr: '(rate(redis_cpu_sys_seconds_total[1m]) + rate(redis_cpu_user_seconds_total[1m])) * 100 > 80' - for: 2m - labels: - severity: warning - annotations: - summary: 'Out of CPU (> 80%)' - description: 'Redis is running out of CPU and the value is {{ $value | printf "%.2f" }} percent. (instance: {{ $labels.pod }})' - - - alert: RedisMemoryHigh - expr: '(redis_memory_max_bytes == 0 or redis_memory_used_bytes * 100 / redis_memory_max_bytes) > 90' - for: 5m - labels: - severity: warning - annotations: - summary: 'Out of memory (> 90%)' - description: 'Redis is running out of memory and the value is {{ $value | printf "%.2f" }} percent. (instance: {{ $labels.pod }})' - - - alert: RedisTooManyConnections - expr: 'redis_connected_clients * 100 / redis_config_maxclients > 80' - for: 1m - labels: - severity: warning - annotations: - summary: 'Redis has too many connections (> 80%)' - description: 'Redis has too many connections and the value is {{ $value | printf "%.2f" }} percent. (instance: {{ $labels.pod }})' - - - alert: RedisRejectedConnections - expr: 'increase(redis_rejected_connections_total[1m]) > 0' - for: 5m - labels: - severity: error - annotations: - summary: 'Redis has rejected connections' - description: '{{ $value | printf "%.2f" }} connections to Redis has been rejected. (instance: {{ $labels.pod }})' - - - alert: RedisKeyEviction - expr: 'increase(redis_evicted_keys_total[5m]) > 0' - for: 1s - labels: - severity: error - annotations: - summary: 'Redis has evicted keys' - description: 'Redis has evicted keys in the last 5 minutes and the value is {{ $value | printf "%.2f" }}. (instance: {{ $labels.pod }})' - - - alert: RedisMissingMaster - expr: 'count by (app_kubernetes_io_instance) (redis_instance_info{role="master"}) < 1' - for: 30s - labels: - severity: critical - annotations: - summary: 'Redis missing master' - description: 'Redis cluster has no node marked as master.' - - - alert: RedisDisconnectedSlaves - expr: 'count without (instance, job) (redis_connected_slaves) - sum without (instance, job) (redis_connected_slaves) - 1 > 1' - for: 0m - labels: - severity: critical - annotations: - summary: 'Redis disconnected slaves' - description: 'Redis not replicating for all slaves. Consider reviewing the redis replication status. (instance: {{ $labels.pod }})' - - - alert: RedisReplicationBroken - expr: 'delta(redis_connected_slaves[1m]) < 0' - for: 0m - labels: - severity: critical - annotations: - summary: 'Redis replication broken' - description: 'Redis instance lost a slave. (instance: {{ $labels.pod }})' - - mongodb_alert_rules.yml: |- - groups: - - name: MongodbExporter - rules: - - alert: MongodbDown - expr: 'max_over_time(mongodb_up[1m]) == 0' - for: 0m - labels: - severity: critical - annotations: - summary: 'MongoDB is Down' - description: 'MongoDB instance is down\n VALUE = {{ $value }}\n LABELS = {{ $labels }}' - - - alert: MongodbRestarted - expr: 'mongodb_instance_uptime_seconds < 60' - for: 0m - labels: - severity: info - annotations: - summary: 'Mongodb has just been restarted (< 60s)' - description: 'Mongodb has just been restarted {{ $value | printf "%.1f" }} seconds ago\n LABELS = {{ $labels }}' - - - alert: MongodbReplicaMemberUnhealthy - expr: 'max_over_time(mongodb_rs_members_health[1m]) == 0' - for: 0m - labels: - severity: critical - annotations: - summary: 'Mongodb replica member is unhealthy' - description: 'MongoDB replica member is not healthy\n VALUE = {{ $value }}\n LABELS = {{ $labels }}' - - - alert: MongodbReplicationLag - expr: '(mongodb_rs_members_optimeDate{member_state="PRIMARY"} - on (pod) group_right mongodb_rs_members_optimeDate{member_state="SECONDARY"}) / 1000 > 10' - for: 0m - labels: - severity: critical - annotations: - summary: 'MongoDB replication lag (> 10s)' - description: 'Mongodb replication lag is more than 10s\n VALUE = {{ $value }}\n LABELS = {{ $labels }}' - - - alert: MongodbReplicationHeadroom - expr: 'sum(avg(mongodb_mongod_replset_oplog_head_timestamp - mongodb_mongod_replset_oplog_tail_timestamp)) - sum(avg(mongodb_rs_members_optimeDate{member_state="PRIMARY"} - on (pod) group_right mongodb_rs_members_optimeDate{member_state="SECONDARY"})) <= 0' - for: 0m - labels: - severity: critical - annotations: - summary: 'MongoDB replication headroom (< 0)' - description: 'MongoDB replication headroom is <= 0\n VALUE = {{ $value }}\n LABELS = {{ $labels }}' - - - alert: MongodbNumberCursorsOpen - expr: 'mongodb_ss_metrics_cursor_open{csr_type="total"} > 10 * 1000' - for: 2m - labels: - severity: warning - annotations: - summary: 'MongoDB opened cursors num (> 10k)' - description: 'Too many cursors opened by MongoDB for clients (> 10k)\n VALUE = {{ $value }}\n LABELS = {{ $labels }}' - - - alert: MongodbCursorsTimeouts - expr: 'increase(mongodb_ss_metrics_cursor_timedOut[1m]) > 100' - for: 2m - labels: - severity: warning - annotations: - summary: 'MongoDB cursors timeouts (>100/minute)' - description: 'Too many cursors are timing out (> 100/minute)\n VALUE = {{ $value }}\n LABELS = {{ $labels }}' - - - alert: MongodbTooManyConnections - expr: 'avg by(pod) (rate(mongodb_ss_connections{conn_type="current"}[1m])) / avg by(pod) (sum (mongodb_ss_connections) by(pod)) * 100 > 80' - for: 2m - labels: - severity: warning - annotations: - summary: 'MongoDB too many connections (> 80%)' - description: 'Too many connections (> 80%)\n VALUE = {{ $value }}\n LABELS = {{ $labels }}' - - - alert: MongodbVirtualMemoryUsage - expr: '(sum(mongodb_ss_mem_virtual) BY (pod) / sum(mongodb_ss_mem_resident) BY (pod)) > 100' - for: 2m - labels: - severity: warning - annotations: - summary: MongoDB virtual memory usage high - description: "High memory usage: the quotient of (mem_virtual / mem_resident) is more than 100\n VALUE = {{ $value }}\n LABELS = {{ $labels }}" - - kafka_alert_rules.yaml: |- - group: - - name: KafkaExporter - rules: - - alert: KafkaTopicsReplicas - expr: 'sum(kafka_topic_partition_in_sync_replica) by (topic) < 3' - for: 0m - labels: - severity: critical - annotations: - summary: 'Kafka topics replicas (instance {{ $labels.app_kubernetes_io_instance }})' - description: 'Kafka topic in-sync partition\n VALUE = {{ $value }}\n LABELS = {{ $labels }}' - - alert: KafkaConsumersGroup - expr: 'sum(kafka_consumergroup_lag) by (consumergroup) > 50' - for: 1m - labels: - severity: critical - annotations: - summary: 'Kafka consumers group (instance {{ $labels.app_kubernetes_io_instance }})' - description: 'Kafka consumers group\n VALUE = {{ $value }}\n LABELS = {{ $labels }}' - - alert: KafkaBrokerDown - expr: 'kafka_brokers < 3' - for: 0m - labels: - severity: critical - annotations: - Summary: 'Kafka broker *{{ $labels.app_kubernetes_io_instance }}* alert status' - description: 'One of the Kafka broker *{{ $labels.app_kubernetes_io_instance }}* is down.' - - serverFiles: - prometheus.yml: - rule_files: - - /etc/config/recording_rules.yml - - /etc/config/alerting_rules.yml - - /etc/config/kubelet_alert_rules.yml - - /etc/config/mysql_alert_rules.yml - - /etc/config/postgresql_alert_rules.yml - - /etc/config/redis_alert_rules.yml - - /etc/config/kafka_alert_rules.yml - - /etc/config/mongodb_alert_rules.yml - - scrape_configs: - - job_name: prometheus - static_configs: - - targets: - - localhost:9090 - - # Scrape config for kubeblocks managed service endpoints. - # - # The relabeling allows the actual service scrape endpoint to be configured - # via the following annotations: - # - # * `monitor.kubeblocks.io/scrape`: Only scrape services that have a value of - # `true`. - # * `monitor.kubeblocks.io/scheme`: If the metrics endpoint is secured then you will need - # to set this to `https` & most likely set the `tls_config` of the scrape config. - # * `monitor.kubeblocks.io/path`: If the metrics path is not `/metrics` override this. - # * `monitor.kubeblocks.io/port`: If the metrics are exposed on a different port to the - # service then set this appropriately. - # * `monitor.kubeblocks.io/param_`: If the metrics endpoint uses parameters - # then you can set any parameter - - job_name: 'kubeblocks-service' - honor_labels: true - - kubernetes_sd_configs: - - role: endpoints - - relabel_configs: - - source_labels: [__meta_kubernetes_service_label_app_kubernetes_io_managed_by] - action: keep - regex: kubeblocks - - source_labels: [__meta_kubernetes_service_annotation_monitor_kubeblocks_io_scrape] - action: keep - regex: true - - source_labels: [__meta_kubernetes_service_annotation_monitor_kubeblocks_io_scheme] - action: replace - target_label: __scheme__ - regex: (https?) - - source_labels: [__meta_kubernetes_service_annotation_monitor_kubeblocks_io_path] - action: replace - target_label: __metrics_path__ - regex: (.+) - - source_labels: [__address__, __meta_kubernetes_service_annotation_monitor_kubeblocks_io_port] - action: replace - target_label: __address__ - regex: (.+?)(?::\d+)?;(\d+) - replacement: $1:$2 - - action: labelmap - regex: __meta_kubernetes_service_annotation_monitor_kubeblocks_io_param_(.+) - replacement: __param_$1 - - action: labelmap - regex: __meta_kubernetes_service_label_(.+) - - source_labels: [__meta_kubernetes_namespace] - action: replace - target_label: namespace - - source_labels: [__meta_kubernetes_service_name] - action: replace - target_label: service - - source_labels: [__meta_kubernetes_pod_node_name] - action: replace - target_label: node - - source_labels: [__meta_kubernetes_pod_name] - action: replace - target_label: pod - - source_labels: [__meta_kubernetes_pod_phase] - regex: Succeeded|Failed|Completed - action: drop - - pushgateway: - ## If false, pushgateway will not be installed - ## - enabled: false - -grafana: - ## If false, grafana sub-chart will not be installed - ## - enabled: false - - rbac: - pspEnabled: false - - replicas: 1 - - image: - # If the value of grafana.image.repository is not specified using --set, - # it will be set to the value of '${image.registry}/apecloud/grafana'. - repository: "" - # Overrides the Grafana image tag whose default is the chart appVersion - tag: 9.2.4 - - ## Grafana server resource requests and limits - ## Ref: http://kubernetes.io/docs/user-guide/compute-resources/ - ## - resources: {} - # limits: - # cpu: 100m - # memory: 128Mi - # requests: - # cpu: 100m - # memory: 128Mi - - ## Node tolerations for grafana scheduling to nodes with taints - ## Ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ - ## - tolerations: - - key: kb-controller - operator: Equal - value: "true" - effect: NoSchedule - - affinity: - nodeAffinity: - preferredDuringSchedulingIgnoredDuringExecution: - - weight: 100 - preference: - matchExpressions: - - key: kb-controller - operator: In - values: - - "true" - - ## Timezone for the default dashboards - ## Other options are: browser or a specific timezone, i.e. Europe/Luxembourg - ## - defaultDashboardsTimezone: - - adminUser: admin - - sidecar: - image: - # If the value of grafana.sidecar.image.repository is not specified using --set, - # it will be set to the value of '${image.registry}/apecloud/k8s-sidecar'. - repository: "" - tag: 1.19.2 - - dashboards: - enabled: true - label: grafana_dashboard - labelValue: "1" - searchNamespace: ALL - resource: configmap - - datasources: - enabled: true - label: grafana_datasource - labelValue: "1" - searchNamespace: ALL - resource: configmap - - defaultDatasourceEnabled: true - uid: prometheus - - skipReload: false - initDatasources: true - - testFramework: - enabled: false - - grafana.ini: - # Basic auth is enabled by default and works with the builtin Grafana user password authentication system and LDAP authentication integration. - auth.basic: - enabled: false - - auth.anonymous: - enabled: true - # Hide the Grafana version text from the footer and help tooltip for unauthenticated users (default: false) - hide_version: true - - ingress: - enabled: false - # For Kubernetes >= 1.18 you should specify the ingress-controller via the field ingressClassName - # See https://kubernetes.io/blog/2020/04/02/improvements-to-the-ingress-api-in-kubernetes-1.18/#specifying-the-class-of-an-ingress - # ingressClassName: nginx - # Values can be templated - annotations: {} - # kubernetes.io/ingress.class: nginx - # kubernetes.io/tls-acme: "true" - labels: {} - path: / - - # pathType is only for k8s >= 1.1= - pathType: Prefix - - hosts: - - chart-example.local - ## Extra paths to prepend to every host configuration. This is useful when working with annotation based services. - extraPaths: [] - # - path: /* - # backend: - # serviceName: ssl-redirect - # servicePort: use-annotation - ## Or for k8s > 1.19 - # - path: /* - # pathType: Prefix - # backend: - # service: - # name: ssl-redirect - # port: - # name: use-annotation - - - tls: [] - # - secretName: chart-example-tls - # hosts: - # - chart-example.local - - ## Expose the grafana service to be accessed from outside the cluster (LoadBalancer service). - ## or access it from within the cluster (ClusterIP service). Set the service type and the port to serve it. - ## ref: http://kubernetes.io/docs/user-guide/services/ - ## - service: - enabled: true - type: ClusterIP - port: 80 - targetPort: 3000 - # targetPort: 4181 To be used with a proxy extraContainer - ## Service annotations. Can be templated. - annotations: {} - labels: {} - portName: service - # Adds the appProtocol field to the service. This allows to work with istio protocol selection. Ex: "http" or "tcp" - appProtocol: "" - ### snapshot-controller settings ### ref: https://artifacthub.io/packages/helm/piraeus-charts/snapshot-controller#configuration @@ -1724,71 +539,6 @@ snapshot-controller: values: - "true" - -alertmanager-webhook-adaptor: - ## Linkage with prometheus.enabled - ## - # enabled: false - ## Webhook-Adaptor container image - ## - image: - # if the value of alertmanager-webhook-adaptor.image.registry is not specified using `--set`, it will be set to the value of 'image.registry' by default - registry: "" - - affinity: - nodeAffinity: - preferredDuringSchedulingIgnoredDuringExecution: - - weight: 100 - preference: - matchExpressions: - - key: kb-controller - operator: In - values: - - "true" - - ## ConfigMap override where fullname is {{.Release.Name}}-{{.Values.configMapOverrideName}} - ## - configMapOverrideName: "config" - - ## Webhook-Adaptor ConfigMap Entries - configFiles: - config.yaml: {} - -csi-hostpath-driver: - ## @param csi-hostpath-driver.enabled -- Enable csi-hostpath-driver chart. - ## - enabled: false - ## csi-hostpath-driver storageClass setting - ## @param csi-hostpath-driver.storageClass.create -- Specifies whether the storage class should be created. - ## @param csi-hostpath-driver.storageClass.default -- Specifies whether the storage class should be default after created. - ## - storageClass: - create: true - default: true - -aws-load-balancer-controller: - clusterName: "" - enabled: false - replicaCount: 1 - tolerations: - - key: kb-controller - operator: Equal - value: "true" - effect: NoSchedule - serviceAccount: - create: true - name: kubeblocks-service-account-aws-load-balancer-controller - affinity: - nodeAffinity: - preferredDuringSchedulingIgnoredDuringExecution: - - weight: 100 - preference: - matchExpressions: - - key: kb-controller - operator: In - values: - - "true" - ## k8s cluster feature gates, ref: https://kubernetes.io/docs/reference/command-line-tools-reference/feature-gates/ enabledAlphaFeatureGates: ## @param enabledAlphaFeatureGates.recoverVolumeExpansionFailure -- Specifies whether feature gates RecoverVolumeExpansionFailure is enabled in k8s cluster. @@ -1880,70 +630,4 @@ featureGates: inPlacePodVerticalScaling: enabled: false -vmagent: - - ## overwrite vmagent scrape_configs - config: - scrape_configs: - # Scrape config for kubeblocks managed service endpoints. - # - # The relabeling allows the actual service scrape endpoint to be configured - # via the following annotations: - # - # * `monitor.kubeblocks.io/scrape`: Only scrape services that have a value of - # `true`. - # * `monitor.kubeblocks.io/scheme`: If the metrics endpoint is secured then you will need - # to set this to `https` & most likely set the `tls_config` of the scrape config. - # * `monitor.kubeblocks.io/path`: If the metrics path is not `/metrics` override this. - # * `monitor.kubeblocks.io/port`: If the metrics are exposed on a different port to the - # service then set this appropriately. - # * `monitor.kubeblocks.io/param_`: If the metrics endpoint uses parameters - # then you can set any parameter - - job_name: 'kubeblocks-service' - honor_labels: true - - kubernetes_sd_configs: - - role: endpoints - - relabel_configs: - - source_labels: [ __meta_kubernetes_service_label_app_kubernetes_io_managed_by ] - action: keep - regex: kubeblocks - - source_labels: [ __meta_kubernetes_service_annotation_monitor_kubeblocks_io_scrape ] - action: keep - regex: true - - source_labels: [ __meta_kubernetes_service_annotation_monitor_kubeblocks_io_scheme ] - action: replace - target_label: __scheme__ - regex: (https?) - - source_labels: [ __meta_kubernetes_service_annotation_monitor_kubeblocks_io_path ] - action: replace - target_label: __metrics_path__ - regex: (.+) - - source_labels: [ __address__, __meta_kubernetes_service_annotation_monitor_kubeblocks_io_port ] - action: replace - target_label: __address__ - regex: (.+?)(?::\d+)?;(\d+) - replacement: $1:$2 - - action: labelmap - regex: __meta_kubernetes_service_annotation_monitor_kubeblocks_io_param_(.+) - replacement: __param_$1 - - action: labelmap - regex: __meta_kubernetes_service_label_(.+) - - source_labels: [ __meta_kubernetes_namespace ] - action: replace - target_label: namespace - - source_labels: [ __meta_kubernetes_service_name ] - action: replace - target_label: service - - source_labels: [ __meta_kubernetes_pod_node_name ] - action: replace - target_label: node - - source_labels: [ __meta_kubernetes_pod_name ] - action: replace - target_label: pod - - source_labels: [ __meta_kubernetes_pod_phase ] - regex: Pending|Succeeded|Failed|Completed - action: drop - userAgent: kubeblocks