You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by André Warnier <aw...@ice-sa.com> on 2008/11/26 17:45:12 UTC
Jconsole through firewall
Hi.
Here :
http://java.sun.com/javase/6/docs/technotes/guides/management/faq.html#rmi1
it says
quote
7.
The com.sun.management.jmxremote.port management property
specifies the port where the RMI Registry can be reached but the ports
where the RMIServer and RMIConnection remote objects are exported is
chosen by the RMI stack. To export the remote objects (RMIServer and
RMIConnection) on a given port you need to create your own RMI connector
server programmatically, as described in the section Mimicking
Out-of-the-Box Management Using the JMX Remote API in the Java SE
Monitoring and Management Guide. You must specify the JMXServiceURL as
follows:
JMXServiceURL url = new
JMXServiceURL("service:jmx:rmi://localhost:" + port1 +
"/jndi/rmi://localhost:" + port2 + "/jmxrmi");
In the command above, port1 is the port number on which the
RMIServer and RMIConnection remote objects are exported and port2 is the
port number of the RMI Registry.
unquote
My simple questions are :
1) does someone understand what it says above ?
2) if I want to monitor a Tomcat server from a remote location through a
firewall using jconsole, can I do it ?
Thanks.
---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
Re: Jconsole through firewall
Posted by Mark Thomas <ma...@apache.org>.
Caldarale, Charles R wrote:
>> From: André Warnier [mailto:aw@ice-sa.com]
>> Subject: Re: Jconsole through firewall
>>
>> With the announced thing above, would I be able to monitor
>> them with jconsole behind their respective firewalls, and
>> if yes what would I need to do for that ?
>
> However, the change would have to be back-ported to 5.5, and I have no idea how difficult that would be.
Looking at the code, I don't see any reason why it shouldn't just work.
Haven't tried it though.
Mark
---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
RE: Jconsole through firewall
Posted by "Caldarale, Charles R" <Ch...@unisys.com>.
> From: André Warnier [mailto:aw@ice-sa.com]
> Subject: Re: Jconsole through firewall
>
> With the announced thing above, would I be able to monitor
> them with jconsole behind their respective firewalls, and
> if yes what would I need to do for that ?
Yes, the patch Mark T spoke of does exactly what we need, allowing use of pre-defined ports for JConsole rather than the randomly allocated ones that JMX currently insists on. However, the change would have to be back-ported to 5.5, and I have no idea how difficult that would be.
Is there any particular reason you're stuck on 5.5?
- Chuck
THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers.
---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
Re: Jconsole through firewall
Posted by André Warnier <aw...@ice-sa.com>.
Caldarale, Charles R wrote:
>> From: Mark Thomas [mailto:markt@apache.org]
>> Subject: Re: Jconsole through firewall
>>
>> There is some code in trunk to do this.
>
> Life just became easier. Thanks very much.
>
I'll say thanks first too, not that anyone would think I am ungrateful.
But could someone explain what it means to me in the practice ?
I have a couple of Tomcat 5.5.x that I would like to monitor for what a
specific app does to them (not pretty right now). One is "in-house"
(but behind a firewall) and is a test system under Linux Debian Etch;
the other one is a customer HPUX 11.11 system, currently running the
Tomcat 5.5.x that came in their HP "HPWS" package together with Apache
2.x and mod_jk1.2.x. That one is also, for us, behind a firewall.
What I mean is that the first one above we can rather easily "do things
to", while the second one is more delicate. And in neither case can we
easily upgrade to Tomcat 6.
With the announced thing above, would I be able to monitor them with
jconsole behind their respective firewalls, and if yes what would I need
to do for that ?
Or, can I / should I use another tool ?
Thanks in advance.
---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
RE: Jconsole through firewall
Posted by "Caldarale, Charles R" <Ch...@unisys.com>.
> From: Mark Thomas [mailto:markt@apache.org]
> Subject: Re: Jconsole through firewall
>
> There is some code in trunk to do this.
Life just became easier. Thanks very much.
- Chuck
THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers.
---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
Re: Jconsole through firewall
Posted by Mark Thomas <ma...@apache.org>.
André Warnier wrote:
> 1) does someone understand what it says above ?
Yes. :)
> 2) if I want to monitor a Tomcat server from a remote location through a
> firewall using jconsole, can I do it ?
There is some code in trunk to do this. You'll need to build the extras
package for tomcat trunk and then use the catalina-jmx-remote.jar
It will need to be in Tomcat's lib directory and on JConsole's classpath.
You can look at the docs in svn:
http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/config/listeners.xml?revision=700734&view=markup
Mark
---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org