![]() |
![]() |
Subject: | JMX monitoring through SSH tunnel |
Author: | Rob |
Posted: | 2015-01-09 11:22 |
Hello Zenoss Community,
I've recently been thrown into managing our Zenoss instance and have come up to speed on everything without too much trouble, but this latest task is going over my head.
We would like to monitor a java process on a remote, cloud server. JMX has been enabled but is only listening for local connections.
I've created some SSH tunnels from the zenoss system to the cloud server, added a device to zenoss with the ZenJMX template, a management address of 127.0.0.1, and zJmx properties set appropriate (zJmxManagementPort set to the tunnel forwarded jmxrmi port)
This is giving me an event with the following:
Error Connecting to Server ; Failed to connect to service:jmx:rmi:///jndi/rmi://127.0.0.1:9696/jmxrmi [Nested Exception: java.io.IOException: Failed to retrieve RMIServer stub: javax.naming.CommunicationException [Root exception is java.rmi.UnmarshalException: error unmarshalling return; nested exception is: java.lang.ClassNotFoundException: org.apache.catalina.mbeans.JmxRemoteLifecycleListener$RmiClientLocalhostSocketFactory (no security manager: RMI class loader disabled)]].
The thing that stands out to me about this error is that the given address doesn't seem to have an jndi host specified;
When I connect using jconsole I see the the address as:
service:jmx:rmi://localhost:9697/jndi/rmi://localhost:9696/jmxrmi
Where is that first host:port pair in the Zenoss error message Is there any way to add that to Zenoss' connection target Or am I looking at it completely the wrong way, and missing another solution to my error
Thank you.
Subject: | JMX monitoring through SSH tunnel |
Author: | [Not Specified] |
Posted: | 2015-01-14 08:29 |
Not to familiar with this zenpack, but some of the solutions point to using the 'Raw Service URL' option on each datapoint withing the template, which in your case would be 'service:jmx:rmi://localhost:9697/jndi/rmi://localhost:9696/jmxrmi'.
Hope this helps,
--Rob
Subject: | Thanks, Rob. I actually had |
Author: | Rob |
Posted: | 2015-01-15 23:32 |
Thanks, Rob. I actually had found the raw service URL in the datasource since my original post, and modified that to match the address my jConsole is successfully connecting to.
The event error message shows the URL i'd expect now, but is otherwise the same error.
If it makes any difference, I set up my SSH tunnels with the following command (repeated for port 9697):
ssh -f zenoss@
Subject: | I've also tried specifying my |
Author: | Rob |
Posted: | 2015-01-16 13:46 |
I've also tried specifying my SSH tunnel with:
ssh -L 9696:
< |
Previous checks the status of FTP sites |
Next Rabbitmq Blocking Zenoss Connections |
> |