/bin/bash
PID=ps -ef | grep statistics-0.0.1-SNAPSHOT | grep -v grep | grep -v root | grep -v bash |awk '{print $2}'
echo $PID
echo "----------------------------"
echo "ps -ef | grep statistics | grep -v grep | grep -v root | grep -v bash
"
echo "----------------------------"
if [ -n "PID
echo "before: 2}'`
echo "now : $P"
else
echo "starting"
nohup /usr/local/jdk1.8.0_92/bin/java -jar -Dserver.port=8091 /usr/local/statistics/statistics-0.0.1-SNAPSHOT.jar >> /usr/local/statistics/logs/stat.log 2>&1 &
fi