Live monitoring using the JMX interface

This article describes how to expose JMX MBeans within JIRA for monitoring with a JMX client.

This guide provides a basic introduction to the JMX interface and is provided as is. Our support team can help you troubleshoot a specific JIRA problem, but aren't able to help you set up your monitoring system or interpret the results.

What is JMX?

JMX (Java Management Extensions) is a technology for monitoring and managing Java applications. JMX uses objects called MBeans (Managed Beans) to expose data and resources from your application. For large instances of JIRA Server or JIRA Data Center, enabling JMX allows you to more easily monitor the consumption of application resources. This enables you to make better decisions about how to maintain and optimize machine resources.

Metrics collected by JIRA

The following table lists metrics (MBeans) that are collected by JIRA. All of them are grouped in the com.atlassian.jira property.

Metric Description Reset after restarting JIRA
dashboard.view.count

The number of times all dashboards were viewed by users.

Yes
entity.attachments.total The number of attachments. -
entity.components.total The number of components. -
entity.customfields.total The number of custom fields. -
entity.filters.total The number of filters. -
entity.groups.total The number of user groups. -
entity.issues.total The number of issues. -
entity.users.total The number of users. -
entity.versions.total The number of versions created. -
issue.assigned.count

The number of times issues were assigned or reassigned to users (counts each action).

Yes
issue.created.count

The number of issues that you created after starting your JIRA instance.

Yes
issue.link.count

The number of issue links created after starting your JIRA instance.

Yes
issue.search.count

The number of times you searched for issues.

Yes
issue.updated.count

The number of times you updated issues (each update after adding or changing some information).

Yes
issue.worklogged.count

The number of times you logged work on issues.

Yes
jira.license The types of licenses you have, the number of active users, and the maximum number of users available for each license type. -
web.requests

The number of requests (invocation.count), and the total response time (total.elapsed.time).

Yes

Monitoring JIRA

Before you can monitor JIRA, you need to enable JMX monitoring and then use a JMX client to view the metrics.

Good to know

Viewing the metrics will always have some performance impact on JIRA. We recommend that you don't refresh them more than once a second.

Enabling JMX monitoring in JIRA

All of the metrics are collected by default, but you need to enable JMX monitoring to expose them. You can do it JIRA, but you need to be a JIRA administrator to get there.

  1. In JIRA, go to  > System > JMX monitoring.
  2. Toggle Enable JMX monitoring.

Monitoring with JConsole

After you enabled JMX monitoring, you can use any JMX client to view the metrics. To make it quick and easy, we've described how to view them by using JConsole. You can monitor your JIRA instance either locally, or remotely:

  • Monitoring JIRA locally is good if you're troubleshooting a particular issue, or only need to monitor JIRA for a short time. Local monitoring can have a performance impact on your server, so it's not recommended for long-term monitoring of your production system.

    Show me how to do this...

     To monitor locally:

    1. Start JConsole (you'll find it in the bin directory of the JDK installation directory).
    2. Select Local Process.
    3. Select the JIRA process. It will be called something like org.apache.catalina.startup.Bootstrap start
    4. After connecting, expand the com.atlassian.jira property that groups all the metrics.

    See Using JConsole for more information on local monitoring.

  • Monitoring JIRA remotely is recommended for production systems, as it does not consume resources on your JIRA server.

    Show me how to do this...

     To monitor remotely:

    1. Add the following properties to your setenv.sh / setenv.bat file. The port can be any port that is not in use.

      set CATALINA_OPTS=-Dcom.sun.management.jmxremote %CATALINA_OPTS% set CATALINA_OPTS=-Dcom.sun.management.jmxremote.port=8099 %CATALINA_OPTS%
    2. Decide how you will secure your remote connection. See Remote Monitoring and Management for more information. 
      Although it is possible to disable authentication, we do not recommend doing this on a production system.
    3. Start JConsole (you'll find it in the bin directory of the JDK installation directory).
    4. Select Remote Process.
    5. Enter your hostname and port (this is the port you specified earlier, not the JIRA port).
    6. Click Connect.
    7. After connecting, expand the com.atlassian.jira property that groups all the metrics.

    See Using JConsole for more information on remote monitoring.

Last modified on Nov 17, 2017

Was this helpful?

Yes
No
Provide feedback about this article

Not finding the help you need?

Ask the community

Powered by Confluence and Scroll Viewport.