Tomcat7.0.40 modifies JDK, memory, Debug port, JMX port

Modify the JDK path:

Add at the beginning of the setclasspath.sh file

export JAVA_HOME=/opt/tuniu/jdk1.6.0_30

 

Increase the remote debug port:

Add at the beginning of the catalina.sh file:

CATALINA_OPTS="-server -Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=7700"

 

Modify JVM memory:

Add at the beginning of the catalina.sh file:

JAVA_OPTS="$JAVA_OPTS -server -Xms512m -Xmx1024m -XX:PermSize=640m -XX:MaxPermSize=1280m -XX:NewSize=64m -XX:MaxNewSize=256m -verbose:gc -XX:+PrintGCDetails -XX:+PrintGCTimeStamps -Xloggc:gc.log"

 

Modify JMX:

Add at the beginning of the catalina.sh file:

JMX_REMOTE_CONFIG="-Djava.rmi.server.hostname=10.10.31.19 -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=7711 -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.authenticate=false"

CATALINA_OPTS="$CATALINA_OPTS $JMX_REMOTE_CONFIG"



 

References:

http://my.oschina.net/firxiao/blog/384768

Guess you like

Origin http://10.200.1.11:23101/article/api/json?id=326609416&siteId=291194637
Recommended