30 lines
1.3 KiB
Diff
30 lines
1.3 KiB
Diff
From 41bf507ca6cbbdf5e646a405de6b8d5b9be4bd28 Mon Sep 17 00:00:00 2001
|
|
From: =?UTF-8?q?=E8=B4=BA=E6=9C=89=E5=BF=97?= <1037617413@qq.com>
|
|
Date: Wed, 16 Oct 2024 17:20:01 +0800
|
|
Subject: [PATCH] enrich alert info about kernel stack
|
|
|
|
---
|
|
src/python/sentryPlugins/ai_block_io/detector.py | 6 ++++--
|
|
1 file changed, 4 insertions(+), 2 deletions(-)
|
|
|
|
diff --git a/src/python/sentryPlugins/ai_block_io/detector.py b/src/python/sentryPlugins/ai_block_io/detector.py
|
|
index ed8b64a..8536f7a 100644
|
|
--- a/src/python/sentryPlugins/ai_block_io/detector.py
|
|
+++ b/src/python/sentryPlugins/ai_block_io/detector.py
|
|
@@ -103,8 +103,10 @@ class DiskDetector:
|
|
elif len(diagnosis_info["rq_driver"]) != 0:
|
|
root_cause = "[Root Cause: disk slow]"
|
|
elif len(diagnosis_info["io_stage"]) != 0:
|
|
- stage = diagnosis_info["io_stage"][0][1].stage_name
|
|
- root_cause = f"[Root Cause: io stage slow, stage: {stage}]"
|
|
+ stage_list = []
|
|
+ for io_stage in diagnosis_info["io_stage"]:
|
|
+ stage_list.append(io_stage[0].stage_name)
|
|
+ root_cause = f"[Root Cause: io stage slow, stage: {stage_list}]"
|
|
if root_cause is None:
|
|
root_cause = "[Root Cause: high io pressure]"
|
|
return True, diagnosis_info["bio"][0][0], diagnosis_info["bio"][0][1], root_cause
|
|
--
|
|
2.23.0
|
|
|