From 0b0fd8ea6782b0df5ec819c9fbbdc2632bd4279e Mon Sep 17 00:00:00 2001 From: dami Date: Wed, 25 Jun 2025 16:25:48 +0800 Subject: [PATCH] Update index.py --- plugins/mysql/index.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/plugins/mysql/index.py b/plugins/mysql/index.py index b9e1eb6d7..19d08ab4d 100755 --- a/plugins/mysql/index.py +++ b/plugins/mysql/index.py @@ -2988,7 +2988,12 @@ def setSlaveStatus(version=''): mode = mw.readFile(mode_file) pdb = pMysqlDb() - dlist = pdb.query('show slave status') + + cmd = 'show slave status' + mdb8 = getMdb8Ver() + if mw.inArray(mdb8, version): + cmd = 'show replica status' + dlist = pdb.query(cmd) if len(dlist) == 0: return mw.returnJson(False, '需要手动添加同步账户或者执行初始化!')