guluo2016 commented on code in PR #7139:
URL: https://github.com/apache/hbase/pull/7139#discussion_r2188386340


##########
bin/hbase-daemon.sh:
##########
@@ -345,15 +346,14 @@ case $startStop in
     rm -f "$HBASE_AUTOSTART_FILE"
     if [ -f $HBASE_PID ]; then
       pidToKill=`cat $HBASE_PID`
-      # kill -0 == see if the PID exists
-      if kill -0 $pidToKill > /dev/null 2>&1; then
+      if is_process_alive $pidToKill $HBASE_PROC_KEYWORD; then
         echo -n stopping $command
         echo "`date` Terminating $command" >> $HBASE_LOGLOG
         kill $pidToKill > /dev/null 2>&1
         waitForProcessEnd $pidToKill $command
       else
         retval=$?
-        echo no $command to stop because kill -0 of pid $pidToKill failed with 
status $retval
+        echo no $command to stop because process $pidToKill is not alive or is 
not $command

Review Comment:
   As above



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to