|
马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。
您需要 登录 才可以下载或查看,没有帐号?立即注册
x
欢迎大家来到仓酷云论坛!open_file.sh:
按次运转liferay,jira,confluence,bamboo,fisheye,可单个运转,可检测某个步伐是不是已运转
#!/bin/sh
#openfile:liferay,jira,confluence,bamboo,fisheye
#portrunning
port_l=`netstat-an|grepLISTEN|grep:8082`
port_j=`netstat-an|grepLISTEN|grep:8088`
port_c=`netstat-an|grepLISTEN|grep:8090`
port_b=`netstat-an|grepLISTEN|grep:8085`
port_f=`netstat-an|grepLISTEN|grep:8060`
#openliferay
cd/usr/local/atlassian/liferay/tomcat-7.0.27/bin
if["$port_l"!=""];then
echo"=================liferayisruning!================="
else
if[$(whoami)=="root"];then
shstartup.sh
else
echo"w4u.com.au"|sudoshstartup.sh
fi
wait
port_ll=`netstat-an|grepLISTEN|grep:8082`
if["$port_ll"==""];then
echo"=================liferayrunfailed!exitopenfile================="
echo"=================jira,confluence,bamboo,fisheyenostart!================="
exit
fi
fi
#openjira
cd/usr/local/atlassian/jira/bin
if["$port_j"!=""];then
echo"=================jiraisruning!================"
else
if[$(whoami)=="root"];then
rm-rf/var/atlassian/application-data/jira/plugins/.osgi-plugins/felix/felix-cache
echo"=================cleanjiracachecomplete!================"
rm/var/atlassian/application-data/jira/.jira-home.lock
shstart-jira.sh
else
echo"w4u.com.au"|sudoshstart-jira.sh
fi
wait
port_jj=`netstat-an|grepLISTEN|grep:8082`
if["$port_jj"==""];then
echo"=================jirarunfailed!exitopenfile================="
echo"=================confluence,bamboo,fisheyenostart!================="
exit
fi
fi
#openconfluence
cd/usr/local/atlassian/confluence/bin
if["$port_c"!=""];then
echo"=================confluenceisruning!================"
else
if[$(whoami)=="root"];then
shstartup.sh
else
echo"w4u.com.au"|sudoshstartup.sh
fi
wait
port_cc=`netstat-an|grepLISTEN|grep:8082`
if["$port_cc"==""];then
echo"=================confluencerunfailed!exitopenfile================="
echo"=================bamboo,fisheyenostart!================="
exit
fi
fi
#openbamboo
cd/usr/local/atlassian/bamboo
if["$port_b"!=""];then
echo"=================bambooisruning!================"
else
if[$(whoami)=="root"];then
shbamboo.shstart
else
echo"w4u.com.au"|sudoshbamboo.shstart
fi
wait
port_bb=`netstat-an|grepLISTEN|grep:8082`
if["$port_bb"==""];then
echo"=================bamboorunfailed!exitopenfile================="
echo"=================fisheyenostart!================="
exit
fi
fi
#openfisheye
cd/usr/local/atlassian/fecru/bin
if["$port_f"!=""];then
echo"=================fisheyeisruning!================"
else
if[$(whoami)=="root"];then
shstart.sh
else
echo"w4u.com.au"|sudoshstart.sh
fi
wait
port_ff=`netstat-an|grepLISTEN|grep:8082`
if["$port_ff"==""];then
echo"=================fisheyerunfailed!exitopenfile================="
exit
fi
fi
欢迎大家来到仓酷云论坛! |
|