vi kafka-server-stop.sh
把PIDS=$(ps ax | grep -i 'kafka.Kafka' | grep java | grep -v grep | awk '{print $1}')这行代码修改为
PIDS=$(jps -lm | grep -i 'kafka.Kafka' | awk '{print $1}')
vi kafka-server-stop.sh
把PIDS=$(ps ax | grep -i 'kafka.Kafka' | grep java | grep -v grep | awk '{print $1}')这行代码修改为
PIDS=$(jps -lm | grep -i 'kafka.Kafka' | awk '{print $1}')