vnpy/kill_celery.sh
msincenselee df17ecccb4 []
2020-03-26 00:07:14 +08:00

14 lines
252 B
Bash

#!/bin/bash
PROGRAM_NAME=celery
# Kill old processes
echo "-------PROGRAM_NAME1--------"
ID=`ps -ef | grep $PROGRAM_NAME | grep -v "$0" | grep -v "grep" | grep "python" | awk '{print $2}'`
echo $ID
for id in $ID
do
kill -9 $id
echo "killed $id"
done