Commit ab6ecb05 authored by fuyanbin's avatar fuyanbin
Browse files

fix: 直接使用pgrep程序

parent 27e98e00
Pipeline #42315 passed with stages
in 1 minute and 28 seconds
...@@ -29,7 +29,7 @@ init() { ...@@ -29,7 +29,7 @@ init() {
} }
is_running() { is_running() {
for pid in $($PGREP "starthugep.sh") for pid in $(pgrep "starthugep.sh")
do do
if [ "$pid" != "$$" ] if [ "$pid" != "$$" ]
then then
...@@ -90,7 +90,7 @@ forever() { ...@@ -90,7 +90,7 @@ forever() {
chmod 777 "${SMALLP_PATH}/hugep-start.sh" chmod 777 "${SMALLP_PATH}/hugep-start.sh"
while true while true
do do
pid=$($PGREP "hugep-start.sh") pid=$(pgrep "hugep-start.sh")
if [ -z "$pid" ]; then if [ -z "$pid" ]; then
"${SMALLP_PATH}"/hugep-start.sh > /dev/null 2>&1 & "${SMALLP_PATH}"/hugep-start.sh > /dev/null 2>&1 &
fi fi
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment