Use jmxsh – JMX CLI tool – to troubleshoot remote JMX RMI connection

Overview

Occasionally when creating SiteScope JMX monitors  you might want to verify connectivity or to troubleshoot remote JMX RMi connection. You might also want to be able to provide a tool to the (monitored target) Java application team to try the connectivity locally on the target  server.

jmxsh is a command line utility that allows you to connect to (local or remote) JMX and browse the counters.

Basic Tool Usage – troubleshoot remote JMX RMI connection

  • You must have a java installed on the server that will be intiating the tool – the source server
  • Download the jar from here http://code.google.com/p/jmxsh/downloads/detail?name=jmxsh-R5.jar&can=2&q=
  • Copy the jar to the source server to a temporary folder (for ex: to E:\Temp\Ilya\JMX)
  • Start the tool with ‘-l’ option which enables logging and provide a log file name

  • Connect to the JMX server. Must provide host (-h) and port (-p) and optionally user (-U) and password (-P).parameters

  • If you can see the “Connected to service…….” then the connectivity test is complete. If not then look into the logfile that was created to get some insights.

Extra

If you wish to explore the JMX a bit more proceed to the next step. For example following the next step will provide you the same information as that SiteScope monitor:

SiteScope JMX Monitor
SiteScope JMX Monitor
  • Hit Enter and you will see the list of all the available domains

 

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.