From d6fdd9cd1615546e2f7ed407dc826c0520d87b0e Mon Sep 17 00:00:00 2001 From: GoEdgeLab Date: Sun, 12 May 2024 08:56:28 +0800 Subject: [PATCH] =?UTF-8?q?=E5=AE=89=E8=A3=85MySQL=E4=B9=8B=E5=89=8D?= =?UTF-8?q?=E5=B0=9D=E8=AF=95=E5=AE=89=E8=A3=85libnuma1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../setup/mysql/mysqlinstallers/mysql_installer.go | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/internal/web/actions/default/setup/mysql/mysqlinstallers/mysql_installer.go b/internal/web/actions/default/setup/mysql/mysqlinstallers/mysql_installer.go index ac4fc215..ef18cea1 100644 --- a/internal/web/actions/default/setup/mysql/mysqlinstallers/mysql_installer.go +++ b/internal/web/actions/default/setup/mysql/mysqlinstallers/mysql_installer.go @@ -90,7 +90,7 @@ func (this *MySQLInstaller) InstallFromFile(xzFilePath string, targetDir string) // ubuntu apt aptGetExe, err := exec.LookPath("apt-get") if err == nil && len(aptGetExe) > 0 { - for _, lib := range []string{"libaio1", "libncurses5"} { + for _, lib := range []string{"libaio1", "libncurses5", "libnuma1"} { this.log("checking " + lib + " ...") var cmd = utils.NewCmd(aptGetExe, "-y", "install", lib) cmd.WithStderr() @@ -105,7 +105,11 @@ func (this *MySQLInstaller) InstallFromFile(xzFilePath string, targetDir string) } if err != nil { - return errors.New("install " + lib + " failed: " + cmd.Stderr()) + if lib == "libnuma1" { + err = nil + } else { + return errors.New("install " + lib + " failed: " + cmd.Stderr()) + } } } time.Sleep(1 * time.Second)