]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
monitoring: show N/A for compression metrics when physical used < 100 GiB 70802/head
authorAfreen Misbah <afreen@ibm.com>
Mon, 3 Aug 2026 21:13:39 +0000 (02:43 +0530)
committerAfreen Misbah <afreen@ibm.com>
Mon, 3 Aug 2026 21:13:39 +0000 (02:43 +0530)
On fresh clusters with no user data, internal metadata compresses
at ~10:1, producing misleading ratio/efficiency values. Gate
compression ratio, efficiency, storage saved, and ratio trend
panels on physical used exceeding 100 GiB.

Signed-off-by: Afreen Misbah <afreen23@gmail.com>
monitoring/ceph-mixin/dashboards_out/ceph-hardware-compression.json

index 7c1a5a51e26770b38631e36098d11f904541bbca..c16f460bd3d24da70eb5ec1bda8c40dff0a1bcf5 100644 (file)
@@ -85,7 +85,7 @@
         "type": "prometheus",
         "uid": "${datasource}"
       },
-      "description": "Amount of physical storage capacity saved through hardware compression.",
+      "description": "Amount of physical storage capacity saved through hardware compression. Displays N/A when physical used is below 100 GiB, as small amounts of internal metadata can produce misleading values.",
       "fieldConfig": {
         "defaults": {
           "color": {
             "uid": "${datasource}"
           },
           "editorMode": "code",
-          "expr": "sum(ceph_extblkdev_dev_log_util{cluster=~\"$cluster\", instance=~\"$instance\", ceph_daemon=~\"$osd\"}) - sum(ceph_extblkdev_dev_phy_util{cluster=~\"$cluster\", instance=~\"$instance\", ceph_daemon=~\"$osd\"})",
+          "expr": "(sum(ceph_extblkdev_dev_log_util{cluster=~\"$cluster\", instance=~\"$instance\", ceph_daemon=~\"$osd\"}) - sum(ceph_extblkdev_dev_phy_util{cluster=~\"$cluster\", instance=~\"$instance\", ceph_daemon=~\"$osd\"})) and (sum(ceph_extblkdev_dev_phy_util{cluster=~\"$cluster\", instance=~\"$instance\", ceph_daemon=~\"$osd\"}) > 107374182400)",
           "instant": false,
           "legendFormat": "Storage Saved",
           "range": true,
         "type": "prometheus",
         "uid": "${datasource}"
       },
-      "description": "Ratio of logical data to physical storage after compression. Higher values indicate better compression efficiency.",
+      "description": "Ratio of logical data to physical storage after compression. Higher values indicate better compression efficiency. Displays N/A when physical used is below 100 GiB, as small amounts of internal metadata can produce misleading values.",
       "fieldConfig": {
         "defaults": {
           "color": {
             "uid": "${datasource}"
           },
           "editorMode": "code",
-          "expr": "sum(ceph_extblkdev_dev_log_util{cluster=~\"$cluster\", instance=~\"$instance\", ceph_daemon=~\"$osd\"}) / clamp_min(sum(ceph_extblkdev_dev_phy_util{cluster=~\"$cluster\", instance=~\"$instance\", ceph_daemon=~\"$osd\"}), 1)",
+          "expr": "(sum(ceph_extblkdev_dev_log_util{cluster=~\"$cluster\", instance=~\"$instance\", ceph_daemon=~\"$osd\"}) / clamp_min(sum(ceph_extblkdev_dev_phy_util{cluster=~\"$cluster\", instance=~\"$instance\", ceph_daemon=~\"$osd\"}), 1)) and (sum(ceph_extblkdev_dev_phy_util{cluster=~\"$cluster\", instance=~\"$instance\", ceph_daemon=~\"$osd\"}) > 107374182400)",
           "instant": false,
           "legendFormat": "Compression Ratio",
           "range": true,
         "type": "prometheus",
         "uid": "${datasource}"
       },
-      "description": "Percentage of storage capacity saved through compression. Shows cost savings and infrastructure efficiency.",
+      "description": "Percentage of storage capacity saved through compression. Shows cost savings and infrastructure efficiency. Displays N/A when physical used is below 100 GiB, as small amounts of internal metadata can produce misleading values.",
       "fieldConfig": {
         "defaults": {
           "color": {
             "uid": "${datasource}"
           },
           "editorMode": "code",
-          "expr": "100 * (1 - sum(ceph_extblkdev_dev_phy_util{cluster=~\"$cluster\", instance=~\"$instance\", ceph_daemon=~\"$osd\"}) / clamp_min(sum(ceph_extblkdev_dev_log_util{cluster=~\"$cluster\", instance=~\"$instance\", ceph_daemon=~\"$osd\"}), 1))",
+          "expr": "(100 * (1 - sum(ceph_extblkdev_dev_phy_util{cluster=~\"$cluster\", instance=~\"$instance\", ceph_daemon=~\"$osd\"}) / clamp_min(sum(ceph_extblkdev_dev_log_util{cluster=~\"$cluster\", instance=~\"$instance\", ceph_daemon=~\"$osd\"}), 1))) and (sum(ceph_extblkdev_dev_phy_util{cluster=~\"$cluster\", instance=~\"$instance\", ceph_daemon=~\"$osd\"}) > 107374182400)",
           "instant": false,
           "legendFormat": "Efficiency",
           "range": true,
         "type": "prometheus",
         "uid": "${datasource}"
       },
-      "description": "Historical compression effectiveness over time. Stable trend indicates consistent workload. Declining ratios suggest more incompressible data.",
+      "description": "Historical compression effectiveness over time. Stable trend indicates consistent workload. Declining ratios suggest more incompressible data. No data shown when physical used is below 100 GiB.",
       "fieldConfig": {
         "defaults": {
           "color": {
             "uid": "${datasource}"
           },
           "editorMode": "code",
-          "expr": "round(sum(ceph_extblkdev_dev_log_util{cluster=~\"$cluster\", instance=~\"$instance\", ceph_daemon=~\"$osd\"}) / sum(ceph_extblkdev_dev_phy_util{cluster=~\"$cluster\", instance=~\"$instance\", ceph_daemon=~\"$osd\"}), 0.01)",
+          "expr": "(round(sum(ceph_extblkdev_dev_log_util{cluster=~\"$cluster\", instance=~\"$instance\", ceph_daemon=~\"$osd\"}) / sum(ceph_extblkdev_dev_phy_util{cluster=~\"$cluster\", instance=~\"$instance\", ceph_daemon=~\"$osd\"}), 0.01)) and (sum(ceph_extblkdev_dev_phy_util{cluster=~\"$cluster\", instance=~\"$instance\", ceph_daemon=~\"$osd\"}) > 107374182400)",
           "instant": false,
           "legendFormat": "Compression Ratio",
           "range": true,