From 909176f87a0322ac54e21acef3666c35f2b6c0f0 Mon Sep 17 00:00:00 2001 From: aaasssddd <1107893276@qq.com> Date: Sat, 6 Dec 2025 10:35:08 +0800 Subject: [PATCH 1/4] Add a stress test in collecting --- src/start_mcpserver.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/start_mcpserver.py b/src/start_mcpserver.py index 6431465..a489e2a 100644 --- a/src/start_mcpserver.py +++ b/src/start_mcpserver.py @@ -37,6 +37,7 @@ delay = config["servers"][0]["delay"] slo_goal = config["feature"][0]["slo_goal"] tune_system_param = config["feature"][0]["tune_system_param"] tune_app_param = config["feature"][0]["tune_app_param"] +pressure_test_mode = config["feature"][0]["pressure_test_mode"] # ================= Collector 接口 =================== @@ -66,11 +67,12 @@ def run_collector(): ) static_profile = static_collector.run() + run_pressure_test_if_needed(config["servers"][0], ssh_client, pressure_test_mode) # 2. 动态指标 metric_collector = MetricCollector( ssh_client=ssh_client, app=app_name, - pressure_test_mode=False, + pressure_test_mode=pressure_test_mode, ) metrics = metric_collector.run() -- Gitee From 5d3c98223ce4cd9ff9f27e576549d61d8d902706 Mon Sep 17 00:00:00 2001 From: aaasssddd <1107893276@qq.com> Date: Sat, 6 Dec 2025 08:46:47 +0000 Subject: [PATCH 2/4] Fix the error in the rdbchecksum field in the Redis knowledge base. Signed-off-by: aaasssddd <1107893276@qq.com> --- src/knowledge_base/knob_params/redis/v6.0.20.json | 6 +++--- src/knowledge_base/knob_params/redis/v6.0.20_zh.json | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/knowledge_base/knob_params/redis/v6.0.20.json b/src/knowledge_base/knob_params/redis/v6.0.20.json index 96077be..7afe7db 100644 --- a/src/knowledge_base/knob_params/redis/v6.0.20.json +++ b/src/knowledge_base/knob_params/redis/v6.0.20.json @@ -214,10 +214,10 @@ "type": "discrete", "dtype": "string", "range": [ - "crc64", - "none" + "yes", + "no" ], - "default_value": "crc64" + "default_value": "yes" }, "rdbcompression": { "desc": "This parameter determines whether to use LZF algorithm to compress strings when backing up RDB files. Enabling compression reduces disk I/O and memory usage, suitable for scenarios storing large amounts of data. Value 'yes' enables compression, 'no' disables. Enabling compression increases CPU burden but significantly reduces disk space usage.", diff --git a/src/knowledge_base/knob_params/redis/v6.0.20_zh.json b/src/knowledge_base/knob_params/redis/v6.0.20_zh.json index 2519b06..e33aa3f 100644 --- a/src/knowledge_base/knob_params/redis/v6.0.20_zh.json +++ b/src/knowledge_base/knob_params/redis/v6.0.20_zh.json @@ -214,10 +214,10 @@ "type": "discrete", "dtype": "string", "range": [ - "crc64", - "none" + "yes", + "no" ], - "default_value": "crc64" + "default_value": "yes" }, "rdbcompression": { "desc": "该参数决定在备份RDB文件时是否使用LZF算法压缩字符串。启用压缩可以减少磁盘IO和内存使用,适合存储大量数据的场景。取值为'yes'表示启用压缩,'no'表示不启用。启用压缩会增加CPU负担,但可以显著减少磁盘空间的使用。", -- Gitee From fcbeb62329cb9aa1faa241325cad70024a9ac30e Mon Sep 17 00:00:00 2001 From: aaasssddd <1107893276@qq.com> Date: Sat, 6 Dec 2025 17:14:45 +0800 Subject: [PATCH 3/4] update prompt --- config/defaults.yaml | 1 - config/defaults_zh.yaml | 1 - 2 files changed, 2 deletions(-) diff --git a/config/defaults.yaml b/config/defaults.yaml index bc0b322..1ac46a9 100644 --- a/config/defaults.yaml +++ b/config/defaults.yaml @@ -66,7 +66,6 @@ common: &common {params_set_str} Please answer in JSON format, key is the adjustable parameter name, please provide adjustable parameters based on the above environment configuration information. If parameters are irrelevant, do not include them. value is the recommended value for the adjustable parameter, please provide reasonable specific values based on the above environment configuration information, carefully confirm whether each value can be used, avoid application startup failures after setting. - Remember that the value of value should not contain any expressions. If there is an expression involving multiplication of two numbers, please calculate their result. Do not provide any response other than JSON, avoid adding comments. Please output in English. recommender_negative: value: | diff --git a/config/defaults_zh.yaml b/config/defaults_zh.yaml index 0632603..6c1bace 100644 --- a/config/defaults_zh.yaml +++ b/config/defaults_zh.yaml @@ -65,7 +65,6 @@ common: &common {params_set_str} 请以json格式回答问题,key为可调参数名称,请根据上述的环境配置信息给出可调整的参数,若参数不相关则不要给出 value是可调参数的推荐取值,请根据上面的环境配置信息给出合理的具体取值,请仔细确认各个值是否可以被使用,有避免设置后应用无法启动。 - 切记value的取值不要带有表达式,如果有两数相乘的表达式,请计算他们的结果。如果是数字,不能包含单位(如 "20M"、"512MB" 等) 请勿给出除了json以外其他的回复,切勿增加注释。 recommender_negative: value: | -- Gitee From ee75fa0cfc39ff61d412f75ab6e861ef44ef1b65 Mon Sep 17 00:00:00 2001 From: aaasssddd <1107893276@qq.com> Date: Mon, 8 Dec 2025 10:54:35 +0800 Subject: [PATCH 4/4] update mysql knowledge base --- src/knowledge_base/knob_params/mysql/v5.7.json | 12 ------------ src/knowledge_base/knob_params/mysql/v5.7_zh.json | 12 ------------ src/knowledge_base/knob_params/mysql/v8.0.21.json | 12 ------------ src/knowledge_base/knob_params/mysql/v8.0.21_zh.json | 12 ------------ 4 files changed, 48 deletions(-) diff --git a/src/knowledge_base/knob_params/mysql/v5.7.json b/src/knowledge_base/knob_params/mysql/v5.7.json index b7c4e92..be75b8f 100644 --- a/src/knowledge_base/knob_params/mysql/v5.7.json +++ b/src/knowledge_base/knob_params/mysql/v5.7.json @@ -230,18 +230,6 @@ "dtype": "int", "default_value": 5000 }, - "innodb_default_row_format": { - "desc": "This parameter defines the default row format for InnoDB tables and user-created temporary tables. Choosing the appropriate row format can optimize storage and performance, helping to alleviate disk I/O bottlenecks. Optional row formats include DYNAMIC, COMPRESSED, REDUNDANT, and COMPACT.", - "type": "discrete", - "range": [ - "REDUNDANT", - "COMPACT", - "DYNAMIC", - "COMPRESSED" - ], - "dtype": "enumeration", - "default_value": "DYNAMIC" - }, "innodb_disable_sort_file_cache": { "desc": "This parameter is used to disable the operating system file system cache for temporary files during merge sorts to improve performance. Enabling this parameter (value ON) can help alleviate disk I/O bottlenecks, while disabling the cache (value OFF) may lead to performance degradation.", "type": "discrete", diff --git a/src/knowledge_base/knob_params/mysql/v5.7_zh.json b/src/knowledge_base/knob_params/mysql/v5.7_zh.json index 28afe76..53a1516 100644 --- a/src/knowledge_base/knob_params/mysql/v5.7_zh.json +++ b/src/knowledge_base/knob_params/mysql/v5.7_zh.json @@ -230,18 +230,6 @@ "dtype": "int", "default_value": 5000 }, - "innodb_default_row_format": { - "desc": "该参数定义了InnoDB表和用户创建的临时表的默认行格式。选择合适的行格式可以优化存储和性能,帮助缓解磁盘IO瓶颈。可选的行格式包括DYNAMIC、COMPRESSED、REDUNDANT和COMPACT。", - "type": "discrete", - "range": [ - "REDUNDANT", - "COMPACT", - "DYNAMIC", - "COMPRESSED" - ], - "dtype": "enumeration", - "default_value": "DYNAMIC" - }, "innodb_disable_sort_file_cache": { "desc": "该参数用于禁用操作系统文件系统缓存,以便在进行合并排序的临时文件时提高性能。启用该参数(值为ON)可以帮助缓解磁盘IO瓶颈,而禁用缓存(值为OFF)可能会导致性能下降。", "type": "discrete", diff --git a/src/knowledge_base/knob_params/mysql/v8.0.21.json b/src/knowledge_base/knob_params/mysql/v8.0.21.json index 32c6364..c4d9ff9 100644 --- a/src/knowledge_base/knob_params/mysql/v8.0.21.json +++ b/src/knowledge_base/knob_params/mysql/v8.0.21.json @@ -250,18 +250,6 @@ "dtype": "int", "default_value": 4 }, - "innodb_default_row_format": { - "desc": "This parameter defines the default row format for InnoDB tables and user-created temporary tables. Choosing the appropriate row format can optimize storage and performance, helping to alleviate disk I/O bottlenecks. Optional row formats include DYNAMIC, COMPRESSED, REDUNDANT, and COMPACT.", - "type": "discrete", - "range": [ - "REDUNDANT", - "COMPACT", - "DYNAMIC", - "COMPRESSED" - ], - "dtype": "enumeration", - "default_value": "DYNAMIC" - }, "innodb_disable_sort_file_cache": { "desc": "This parameter is used to disable the operating system file system cache for temporary files during merge sorts to improve performance. Enabling this parameter (value ON) can help alleviate disk I/O bottlenecks, while disabling the cache (value OFF) may lead to performance degradation.", "type": "discrete", diff --git a/src/knowledge_base/knob_params/mysql/v8.0.21_zh.json b/src/knowledge_base/knob_params/mysql/v8.0.21_zh.json index 949c1b5..f75b63f 100644 --- a/src/knowledge_base/knob_params/mysql/v8.0.21_zh.json +++ b/src/knowledge_base/knob_params/mysql/v8.0.21_zh.json @@ -250,18 +250,6 @@ "dtype": "int", "default_value": 4 }, - "innodb_default_row_format": { - "desc": "该参数定义了InnoDB表和用户创建的临时表的默认行格式。选择合适的行格式可以优化存储和性能,帮助缓解磁盘IO瓶颈。可选的行格式包括DYNAMIC、COMPRESSED、REDUNDANT和COMPACT。", - "type": "discrete", - "range": [ - "REDUNDANT", - "COMPACT", - "DYNAMIC", - "COMPRESSED" - ], - "dtype": "enumeration", - "default_value": "DYNAMIC" - }, "innodb_disable_sort_file_cache": { "desc": "该参数用于禁用操作系统文件系统缓存,以便在进行合并排序的临时文件时提高性能。启用该参数(值为ON)可以帮助缓解磁盘IO瓶颈,而禁用缓存(值为OFF)可能会导致性能下降。", "type": "discrete", -- Gitee