From 8c83f229c93b1d5e4dd05361894b8f3ffaf9de55 Mon Sep 17 00:00:00 2001 From: xiepaup Date: Wed, 8 Jan 2025 10:50:21 +0800 Subject: [PATCH] =?UTF-8?q?fix(redis):=20=E5=AF=86=E7=A0=81=E7=89=B9?= =?UTF-8?q?=E6=AE=8A=E5=AD=97=E7=AC=A6=E5=AF=BC=E8=87=B4=E5=B7=A5=E5=85=B7?= =?UTF-8?q?=E8=BF=90=E8=A1=8C=E5=BC=82=E5=B8=B8=20#8954?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- dbm-services/redis/db-tools/dbmon/pkg/keylifecycle/task.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/dbm-services/redis/db-tools/dbmon/pkg/keylifecycle/task.go b/dbm-services/redis/db-tools/dbmon/pkg/keylifecycle/task.go index 090c0b43e2..5ffec26fa7 100644 --- a/dbm-services/redis/db-tools/dbmon/pkg/keylifecycle/task.go +++ b/dbm-services/redis/db-tools/dbmon/pkg/keylifecycle/task.go @@ -168,7 +168,7 @@ func (t *Task) hotKeyWithMonitor(server Instance) (string, error) { t.rotateFile(hkfile) mylog.Logger.Info(fmt.Sprintf("do hot key analyse : %s", server.Addr)) - hkCmd := fmt.Sprintf("%s hotkeys -A %s -S %s -a %s -D %s --raw -o %s > %s 2>&1", + hkCmd := fmt.Sprintf("%s hotkeys -A %s -S %s -a '%s' -D %s --raw -o %s > %s 2>&1", consts.TendisKeyLifecycleBin, server.App, server.Addr, server.Password, server.Domain, t.logFile, hkfile) mylog.Logger.Info(fmt.Sprintf("exec cmd : %s", hkCmd)) @@ -245,7 +245,7 @@ func (t *Task) bigKeyWithAof4Cache(server Instance, bkfile, kmfile string) (int6 step, slptime, sample, confidence, adjfactor := getStatToolParams(dbsize) cmdExec := fmt.Sprintf( - "cat %s | %s keystat --stdin --raw -B %s -M %s -o %s -S %s -a %s -A %s -D %s "+ + "cat %s | %s keystat --stdin --raw -B %s -M %s -o %s -S %s -a '%s' -A %s -D %s "+ "--step %d --keymodetop 100 --samples %d --confidence %d --adjfactor %d --duration %d > %s 2>&1", allkeys, consts.TendisKeyLifecycleBin, bkfile, kmfile, t.logFile, server.Addr, server.Password, server.App, server.Domain, @@ -301,7 +301,7 @@ func (t *Task) statRawKeysFileDetail(keysFile string, bkFile string, kmFile stri step, slptime, sample, confidence, adjfactor := getStatToolParams(keyLines) cmdExec := fmt.Sprintf( - "cat %s | %s keystat --ssd --stdin --raw -B %s -M %s -o %s -S %s -a %s -A %s -D %s "+ + "cat %s | %s keystat --ssd --stdin --raw -B %s -M %s -o %s -S %s -a '%s' -A %s -D %s "+ "--step %d --keymodetop 100 --samples %d --confidence %d --adjfactor %d --duration %d > %s 2>&1", keysFile, consts.TendisKeyLifecycleBin, bkFile, kmFile, t.logFile, server.Addr, server.Password, server.App, server.Domain,