#!/bin/bash pid=`lsof -i:8080 |sed -n 2p | awk '{print $2}'` echo $pid if [ "-$pid" = "-" ];then echo "start to restart tomcat at port 8080" su - huawei -c 'sh /home/huawei/tomcat/bin/startup.sh' # cd /home/huawei/tomcat/bin #sh startup.sh fi
重启tomcat之shell脚本
猜你喜欢
转载自killeraction.iteye.com/blog/1761597
今日推荐
周排行