1

I'm using JavaMelody on Tomcat 7 in order to monitor memory usage. When I fire up Tomcat and navigate to the /monitoring page, all is fine and dandy. However, when I try and generate a Memory Histogram, a pop-up appears informing me that 'Memory histogram is not supported because the server uses the JRE and not the JDK. This is confirmed in the start up section of the logs:

INFO: Java Home: C:\Program Files\Java\jdk1.8.0_151\jre

However, my JAVA_HOME variable is set to C:\Program Files\Java\jdk1.8.0_151\ Why does Tomcat append 'jre' to the JAVA_HOME, and how do I stop it from doing it?

Thanks

Angus

angusrose
  • 143
  • 1
  • 3
  • 13

1 Answers1

2

Looking at the catalina.bat start script of tomcat 7:

rem   JAVA_HOME       Must point at your Java Development Kit installation.
rem                   Required to run the with the "debug" argument.
rem
rem   JRE_HOME        Must point at your Java Runtime installation.
rem                   Defaults to JAVA_HOME if empty. If JRE_HOME and JAVA_HOME
rem                   are both set, JRE_HOME is used.

Please check if you have set a JRE_HOME variable, because that would explain your problem

Jorge_B
  • 9,712
  • 2
  • 17
  • 22