开发者

Monitoring a J2EE application running in Tomcat with JMX

All,

If i want to enable JMX on Tomcat for monitoring from the same machine, (i.e. not remotely) are these properties still required?

com.sun.management.jmxremot开发者_开发技巧e.authenticate=false
com.sun.management.jmxremote.port=12345

Isnt it the case that the authenticate and port number properties are only relevant if monitoring remotely? Do i need the above if monitoring locally?

If the port number is not required, how does the client know who to contact Tomcat? Does it listen to a port number that TOmcat has open by default?


You are correct, these parameters only required when monitoring remote application via JMX. When monitoring locally, you can skip them. Obviously the process needs to be started by the same user.

I think there are some exceptions to this rule, see http://download.oracle.com/javase/1.5.0/docs/guide/management/agent.html#local

Q:"If the port number is not required, how does the client know who to contact Tomcat?"
A: jconsole, jps and the likes simply looks for any Java processes that are running on the system and owned by the same user.

Read here: http://download.oracle.com/javase/6/docs/technotes/guides/management/jconsole.html (chapter about attachable applications).


Here is a writeup i did on this subject. JMX setup for external access

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜