print pid

#!/bin/bash
port=8011
pid=$(netstat -nlp | grep :$port | awk '{print $7}' | awk -F"/" '{ print $1 }');
echo $pid
if [ -n "$pid" ]; then
	kill -9 $pid
fi
java -jar allinone-0.0.1-SNAPSHOT.jar > csm.log &
exit

  

posted @ 2020-04-20 10:26  忧伤还是快乐EL  阅读(127)  评论(0编辑  收藏  举报