In $TOMCAT_HOME/bin/setenv.sh :

CATALINA_OPTS="$CATALINA_OPTS -Djava.rmi.server.hostname=my-server-hostname"
CATALINA_OPTS="$CATALINA_OPTS -Dcom.sun.management.jmxremote=true"
CATALINA_OPTS="$CATALINA_OPTS -Dcom.sun.management.jmxremote.port=9090"
CATALINA_OPTS="$CATALINA_OPTS -Dcom.sun.management.jmxremote.ssl=false"
CATALINA_OPTS="$CATALINA_OPTS -Dcom.sun.management.jmxremote.ssl.need.client.auth=false"
CATALINA_OPTS="$CATALINA_OPTS -Dcom.sun.management.jmxremote.authenticate=false"

export CATALINA_OPTS=$CATALINA_OPTS
export JAVA_OPTS=$JAVA_OPTS
Advertisements