ARTIFACTORY: How to connect JMX to Access JVM

Products
Frog_Artifactory
Content Type
Integrations
AuthorFullName__c
Nir Shervi
articleNumber
000006468
FirstPublishedDate
2025-06-05T11:37:23Z
lastModifiedDate
2025-06-05

ARTIFACTORY: How to connect JMX to Access JVM

Introduction

Starting with Artifactory version 7.90, the Access microservice operates with its own dedicated Java Virtual Machine (JVM). This architectural change enhances the isolation and management of the Access service. For a deeper understanding of this separation, please refer to the official JFrog documentation: https://jfrog.com/help/r/jfrog-installation-setup-documentation/individual-jvm-for-access-service.
This article outlines the steps required to connect JConsole, a Java monitoring and management console, to the Access JVM, allowing you to inspect its metrics and performance.
If you wish to monitor you Artifactory microservice JVM using JMX, please see here: https://jfrog.com/help/r/how-to-enable-jmx-monitoring-in-artifactory-7-x/how-to-enable-jmx-monitoring-in-artifactory-7.x
Both JVMs can be monitored in parallel.

Prerequisites:
  • Artifactory version 7.90 or later. Prior to this Access shares its JVM with Artifactory and so monitoring the Artifactory JVM is enough.
  • JConsole installed on your machine (typically included with the Java Development Kit - JDK).
  • Network connectivity between the machine running JConsole and the Artifactory server.

 

Steps to Connect to the Access JVM:
Step 1: Define the JMX Remote Port for the Access JVM 
Configure the port that the Access JVM will listen on for JMX connections. This is done within the Artifactory system configuration file.

- Open the $JFROG_ARTIFACTORY/artifactory/var/etc/system.yaml file.
- Locate the access: section.
- Add or modify the extraJavaOpts property under access: to include the following JMX remote configuration:
access:
   extraJavaOpts: "-Dcom.sun.management.jmxremote 
-Dcom.sun.management.jmxremote.port=9020 
-Dcom.sun.management.jmxremote.local.only=false 
-Dcom.sun.management.jmxremote.authenticate=false 
-Dcom.sun.management.jmxremote.ssl=false" 
Important Considerations:
  • Port Conflict: Ensure that the port specified for the Access JVM (9020 in the example) is different from the jmxremote.port configured for the main Artifactory JVM or any other services running on the same host.
  • Security: The provided configuration disables authentication and SSL for simplicity. In production environments, it is recommended to enable authentication
    (-Dcom.sun.management.jmxremote.authenticate=true) and SSL
    (-Dcom.sun.management.jmxremote.ssl=true) to secure your JMX connection. You will then need to configure appropriate credentials and keystores/truststores.
Step 2: Restart Artifactory
After modifying the system.yaml file, you must restart the Artifactory service for the changes to take effect and for the Access JVM to start listening on the configured JMX port.

Step 3: Open JConsole 
Launch the JConsole application on your local machine. The exact method to open JConsole depends on your operating system. On macOS, you can typically find it in the JDK's bin directory or by searching for it in Spotlight.

Step 4: Connect to the Access JVM 
In the JConsole connection dialog:

- Enter the hostname or IP address of your Artifactory server, followed by a colon (:) and the JMX remote port you configured for the Access JVM (e.g., localhost:9020 if running JConsole on the same machine as Artifactory, or <Artifactory_IP>:9020).
- Click the "Connect" button.

User-added image 

Step 5: Monitor Access JVM Metrics 
Upon successful connection, JConsole will display various tabs allowing you to monitor the Access JVM's performance, including:

- Overview: Provides a high-level summary of JVM statistics.
- Memory: Displays memory usage, heap size, and garbage collection activity.
- Threads: Shows information about active and historical threads.
- Classes: Details about loaded and unloaded classes.
- MBeans: Allows you to browse and interact with JMX Managed Beans, providing detailed insights into the Access service's internal state and operations.

User-added image