tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Paolo Santarsiero <paolo.santarsi...@gmail.com>
Subject remote monitoring JVM by VisualVM
Date Mon, 14 Dec 2009 09:11:33 GMT
Hello, I'm tryng to monitor my JVM and so Tomcat HeapMemory usage by remote
access using VisualVM. I configured all, but my client always display an
error message (" Cannoct connect using
service:jmx:rmi:///jndi/rmi://xxx.xxx.xxx.xxx.:8080:jmxrmi").
I added in catalina.sh this Java options:
elif [ "$1" = "start" ] ; then

  shift
  touch "$CATALINA_BASE"/logs/catalina.out
  if [ "$1" = "-security" ] ; then
    echo "Using Security Manager"
    shift
     "$_RUNJAVA" "$LOGGING_CONFIG" $JAVA_OPTS \
     #START JMXREMOTE OPTIONS
      -Dcom.sun.management.jmxremote.port=8080 \
      -Dcom.sun.management.jmxremote.ssl=false \
      -Dcom.sun.management.jmxremote.authenticate=true \
     #END JMXREMOTE OPTIONS
      $CATALINA_OPTS \
      -Djava.endorsed.dirs="$JAVA_ENDORSED_DIRS" -classpath "$CLASSPATH" \
      -Djava.security.manager \
      -Djava.security.policy=="$CATALINA_BASE"/conf/catalina.policy \
      -Dcatalina.base="$CATALINA_BASE" \
      -Dcatalina.home="$CATALINA_HOME" \
      -Djava.io.tmpdir="$CATALINA_TMPDIR" \
      org.apache.catalina.startup.Bootstrap "$@" start \
      >> "$CATALINA_BASE"/logs/catalina.out 2>&1 &

      if [ ! -z "$CATALINA_PID" ]; then
        echo $! > $CATALINA_PID
      fi
  else
      "$_RUNJAVA" "$LOGGING_CONFIG" $JAVA_OPTS \
     #START JMXREMOTE OPTIONS
      -Dcom.sun.management.jmxremote.port=8080 \
      -Dcom.sun.management.jmxremote.ssl=false \
      -Dcom.sun.management.jmxremote.authenticate=true \
      #END JMXREMOTE OPTIONS
      $CATALINA_OPTS \
      -Djava.endorsed.dirs="$JAVA_ENDORSED_DIRS" -classpath "$CLASSPATH" \
      -Dcatalina.base="$CATALINA_BASE" \
      -Dcatalina.home="$CATALINA_HOME" \
      -Djava.io.tmpdir="$CATALINA_TMPDIR" \
      org.apache.catalina.startup.Bootstrap "$@" start \
      >> "$CATALINA_BASE"/logs/catalina.out 2>&1 &

      if [ ! -z "$CATALINA_PID" ]; then
        echo $! > $CATALINA_PID
      fi
  fi
-----------------------------------------------------------------------------------------------------------------------------------------------
In JRE_Home/management i modified jmxremote.password and added rights
passwords for access roles.
My Tomcat version is 6 and Java1.5. In server.xml  I disabled HTTP connector
in order to free use 8080 port for jmx.
I hope you can help me, thanks.

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message