tomcat打开远程调试和jmx远程监控
远程Debug打开
在catalina.sh中去掉CATALINA_OPTS="$CATALINA_OPTS "-server" "-Xdebug" "-Xnoagent" "-Djava.compiler=NONE" "-Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=12345的注释,重启后生效。
远程jvm监控
在setenv.sh中加入CATALINA_OPTS="$CATALINA_OPTS -Djava.rmi.server.hostname=10.171.113.244 -Dcom.sun.management.jmxremote.port=8999 -Dcom.sun.management.jmxremote.rmi.port=8999 -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.authenticate=false",在setenv.sh里面写是为了不影响catalina.sh本身结构,重启后生效,通过jconsole连接时需要填写tomcat所属用户的用户名,不需要填写密码。
posted on 2018-10-12 10:26 master-huang 阅读(977) 评论(0) 收藏 举报
浙公网安备 33010602011771号