From dca43f812d56c553fa10e325e7f1038a6afb9dd3 Mon Sep 17 00:00:00 2001 From: midoks Date: Thu, 4 Feb 2021 18:59:50 +0800 Subject: [PATCH] Update index.py --- plugins/mysql/index.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/plugins/mysql/index.py b/plugins/mysql/index.py index 832864ca0..6529c1b44 100755 --- a/plugins/mysql/index.py +++ b/plugins/mysql/index.py @@ -160,6 +160,7 @@ def initDreplace(version=''): content = contentReplace(content) mw.writeFile(mysql_conf, content) + mw.execShell('chown -R mysql mysql ' + getServerDir()) return file_bin @@ -450,7 +451,7 @@ def setMyDbPos(): # mw.execShell('/etc/init.d/mysqld stop') stop() mw.execShell('cp -rf ' + s_datadir + '/* ' + t_datadir + '/') - mw.execShell('chown -R mysql.mysql ' + t_datadir) + mw.execShell('chown -R mysql mysql ' + t_datadir) mw.execShell('chmod -R 755 ' + t_datadir) mw.execShell('rm -f ' + t_datadir + '/*.pid') mw.execShell('rm -f ' + t_datadir + '/*.err')