在catalina.sh中添加
CATALINA_OPTS="$CATALINA_OPTS
-Dcom.sun.management.jmxremote
-Dcom.sun.management.jmxremote.port=20002
-Dcom.sun.management.jmxremote.ssl=false
-Dcom.sun.management.jmxremote.authenticate=false
-Djava.rmi.server.hostname=172.17.40.253"
-Dcom.sun.management.jmxremote jmx 端口
-Dcom.sun.management.jmxremote.ssl 是否使用ssl(线上需使用)
-Dcom.sun.management.jmxremote.authenticate 是否需要认证(线上需要认证)
-Djava.rmi.server.hostname 服务器ip