4

I am having some issues getting remote JMX working under JBoss 4.2.0, EAP version. I am having some Java OOM errors in my application, and am attempting to set this up specifically to run VisualVM against it.

JBoss is running against JDK 1.5

I have attempted to get this working by adding the following to my JAVA_OPTS at startup (with linebreaks here for readability):

-Djavax.management.builder.initial=org.jboss.system.server.jmx.MBeanServerBuilderImpl
-Djboss.platform.mbeanserver
-Dcom.sun.management.jmxremote.port=6789
-Dcom.sun.management.jmxremote.authenticate=false
-Dcom.sun.management.jmxremote.ssl=false

When I start JBoss, I see entries in boot.log indicating the JMX is enabled on port 6789 and that auth and ssl are set to false. However, netstat does not show anything listening on port 6789 and I cannot get a telnet connection to the port. Not surprisingly, VisualVM also fails to connect (running both local and remote).

The default /jmx-console context that ships with JBoss appears to load fine, if that matters.

Is there something I am missing here? Was remote JMX support added at a later time or something?

EDIT: I forgot to mention that JBoss is running with an SSL connector, so for example I access the jmx-console via https://localhost:8888/jmx-console. Maybe this has an effect on the JMX connection?

Brendan Hannemann
  • 2,084
  • 1
  • 18
  • 33

1 Answers1

2

try adding

-Djava.rmi.server.hostname=thedomain.com
hvgotcodes
  • 118,147
  • 33
  • 203
  • 236
  • Thanks. According to http://hillert.blogspot.com/2010/01/remote-profiling-of-jboss-using.html it looks like I should try the IP as well. I'll give both a shot tomorrow around 10am EST. – Brendan Hannemann Nov 03 '10 at 00:53
  • No dice. I tried the both the hostname and the IP and couldn't get anywhere. I did manage to get VisualVM to connect locally if I run JBoss as my user, if that matters, but not over JMX. – Brendan Hannemann Nov 03 '10 at 13:39