From 7a800b0307cd83b51aa72f7ef87e518e9ec23d5b Mon Sep 17 00:00:00 2001 From: Hungerdream <1710233908@qq.com> Date: Tue, 28 Jul 2026 14:28:53 +0800 Subject: [PATCH] fix(ansible): treat empty or auto redo capacity as unset innodb_redo_log_capacity passed as '' or 'auto' from the delivery payload previously bypassed the memory-based tier calculation and was rendered verbatim into the instance config. Fall back to the automatic tier when the value is empty or 'auto'. --- ansible/mysql-deploy.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ansible/mysql-deploy.yml b/ansible/mysql-deploy.yml index 03184e7..db3badf 100644 --- a/ansible/mysql-deploy.yml +++ b/ansible/mysql-deploy.yml @@ -334,7 +334,7 @@ # InnoDB redo log 容量:按内存梯度递增 # ≤4G→128M、≤16G→256M、≤32G→512M、>32G→1G mysql_redo_capacity: >- - {{ innodb_redo_log_capacity if (innodb_redo_log_capacity is defined) + {{ innodb_redo_log_capacity if (innodb_redo_log_capacity is defined and (innodb_redo_log_capacity | string | lower) not in ['', 'auto']) else ('128M' if (mysql_memory_gb | int) <= 4 else '256M' if (mysql_memory_gb | int) <= 16 else '512M' if (mysql_memory_gb | int) <= 32