Skip to content
This repository has been archived by the owner on Mar 18, 2024. It is now read-only.

Commit

Permalink
temp fix for redis server startup fail
Browse files Browse the repository at this point in the history
  • Loading branch information
petervolvowinz committed Feb 29, 2024
1 parent 0aff616 commit 26fc41f
Showing 1 changed file with 9 additions and 7 deletions.
16 changes: 9 additions & 7 deletions server/vissv2server/serviceMgr/serviceMgr.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ import (
"net"
"net/http"
"os"
"os/exec"
"strconv"
"strings"

Expand Down Expand Up @@ -958,13 +959,14 @@ func ServiceMgrInit(mgrId int, serviceMgrChan chan string, stateStorageType stri
utils.Error.Printf("redis-server ,ping err = %s", err)
if utils.FileExists("redis.log") {
os.Remove("redis.log")
} /*
cmd := exec.Command("/usr/bin/bash", "redisNativeInit.sh")
err := cmd.Run()
if err != nil {
utils.Error.Printf("redis-server startup failed, err=%s", err)
os.Exit(1)
}*/
}
cmd := exec.Command("/usr/bin/bash", "redisNativeInit.sh")
err := cmd.Run()
if err != nil {
utils.Error.Printf("redis-server startup failed, err=%s", err)
// os.Exit(1) should terminate the process
return
}
} else {
utils.Info.Printf("Redis state ping is ok")
}
Expand Down

0 comments on commit 26fc41f

Please sign in to comment.