×

tomcat 检测运行

96
lucode
2017.12.27 15:16* 字数 0
port=$(lsof -i:8080)
str="java"
result=$(echo $port | grep ${str})
if test $result!=""
then
   echo "启动 tomcat "
   sh /www/server/tomcat/bin/catalina.sh run
else
   echo "tomcat正常运行"
fi
技术杂货
Web note ad 1