码迷,mamicode.com
首页 > 编程语言 > 详细

java war run

时间:2016-09-10 20:50:55      阅读:160      评论:0      收藏:0      [点我收藏+]

标签:

#!/bin/bash
date=`date +‘%Y%m%d %T‘`
pid=`ps -ef |grep Credit | grep -v grep|awk ‘{print $2}‘`
damocles_home=/usr/local/damocles-webapp/
logdir=/home/wwwad
chown wwwad:yizhen /usr/local/damocles-webapp/
chown wwwad. /usr/local/damocles-webapp/conf/*
[ -n "$pid" ] && kill -9 $pid
cd $damocles_home
nohup java -Xms4096m -Xmx4096m -XX:PermSize=512M -XX:MaxPermSize=1024m -Djava.awt.headless=true -XX:SurvivorRatio=4 -XX:ParallelGCThreads=4 -XX:+UseConcMarkSweepGC -XX:+UseParNewGC -XX:CMSInitiatingOccupancyFraction=68 -Dcom.sun.management.jmxremote.port=1099 -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Djmagick.systemclassloader=no -Djava.rmi.server.hostname=10.23.24.104 -classpath ".:classes:conf:lib/*" com.yizhenmoney.damocles.common.app.CreditApplication >> $logdir/damocles.out &
[ "$?" -eq 0 ] && echo "$date credit restart successful!" >> $logdir/restart.log
[ "$?" -eq 1 ] && echo "$date credit restart failed,please check and run again!" >>$logdir/restart.log
ps -ef |grep Credit
tail $logdir/restart.log -n 1
sleep 5
tail -f $logdir/damocles.out -n 100

 

java war run

标签:

原文地址:http://www.cnblogs.com/adolfmc/p/5860151.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!