Management Agent
A Management Agent is installed on a host. A management agent can be installed directly on a host (for example, a host on your premises or on a third-party cloud platform) or indirectly as a plug-in for an oracle cloud agent (in the case of a Compute Instance). A management agent's plug-ins monitor and collect data from its host, which they then report to the Management Agent Cloud Service.
- The presence of a Java Runtime installation
- The start of a Java application
- The start of a Java Runtime
- Data provided by Java Usage Tracker
A management agent may have one or more Tags.
See also, Managed Instance.
The management agent cloud service is an OCI service that manages management agents and their life cycle. For more details, see Management Agent Concepts.
Installing a Management Agent
This section describes the process to install a management agent for both on-premises and OCI instances.
- You have read Perform Prerequisites for Deploying Management Agents and ensured that your host meets the prerequisites, including the requirement for JDK 8 (update 361, JDK 1.8.0_361, or later). The management agent isn't compatible with any other versions of the JDK.
- To install a management agent on a host,
you must meet the prerequisites described in Install
Management Agents. For more information,
see Configuring a Management Agent for
Java Management Service.
Caution:
To update the Java runtime used by the management agents, you should follow the instructions detailed in the Using Java with Management Agent section to ensure the management agents continue working. - JMS recommends using JDK (instead of JRE) for setting up MACS.
- JMS recommends setting up the management agent with a
Java installation that is independent of system
java
. For example, while installing the management agent, setJAVA_HOME
to JDK 8 that is not managed by the operating system's package management system. - You have completed the policy set up steps for the installation script to run successfully.
- You have ensured that the clock on your host is synchronized with the OCI platform. You'll be unable to install a management agent if your host's clock is skewed more than five minutes from the OCI platform. For more information, see Maximum Allowed Client Clock Skew.
This section describes the steps to configure a management agent for both on-premises and OCI platforms:
You can install a management agent in a container. For details see Tracking Java Usage in a Container.
Using Installation Script
JMS provides an installation script that you can use to set up management agents using a single command.
Supported platforms include Oracle Linux, Ubuntu, and Windows (x86 and x64).
- Install the Management Agent software.
- Configure the agent with a specific key for the fleet.
- Install JMS plugins for Java runtime discovery and usage reporting and Lifecycle management operations.
- Configure the usage tracker.
Downloading the Installation Script
Follow these instructions to download the installation script:
Oracle applications:
- Oracle JDK 11 on OCI host
- OCI Command Line Interface (CLI) on Linux OCI along with Python 3
Third-party tools:
- curl: a command-line tool and library used for transferring data with URLs.
- jq: a command-line JSON processor used to map and transform structured data.
- unzip: utility used to extract files from a zipped single file or similar file archive. This is used only on Ubuntu platform.
- snap: a software packaging and deployment system used embed applications on Linux devices. This is used only on Ubuntu platform.
On-Premises Linux
This section describes the steps to run the downloaded script on an on-premise host running on Linux platform.
Steps
On-Premises Windows
This section describes the steps to run the downloaded script on an on-premise host running on Windows platform.
On 32 bit instances, run the script with parameter
--force-32bit-installer
as described in the
following steps.
Steps
/opt/oracle/mgmt_agent/plugins/jm/stateDir/log
directory.
OCI Linux
This section describes the steps to run the downloaded script on an OCI instance running on Linux platform.
You need to add the policy
ALLOW dynamic-group JMS_DYNAMIC_GROUP TO MANAGE instances IN COMPARTMENT Fleet_Compartment
before
you install a management agent on Linux for OCI. You can remove the policy after
you've installed the management agent.Steps
/var/log/oracle-cloud-agent/plugins/oci-jms/
directory.
Manual Installation
You can manually install a management agent on a non-OCI host.
This section describes the steps to manually install a management agent on:
On-Premises Linux
This section describes the steps to manually run the downloaded script on an on-premise host running on Linux platform.
Steps
The installation instructions are the same for Oracle Linux and Ubuntu unless a difference between the two is noted.
/opt/oracle/mgmt_agent/plugins/jm/stateDir/log/
directory.
On-Premises Windows
This section describes the steps to manually run the downloaded script on an on-premise host running on Windows platform
Steps
The installation instructions are the same for Linux and Ubuntu unless a difference between the two is noted.
/opt/oracle/mgmt_agent/plugins/jm/stateDir/log/
directory.
OCI Linux
Follow these steps if your host is a Compute Instance on Oracle Cloud Infrastructure (OCI).
Before you begin, review the prerequisites and the overview of the steps.
This functionality isn't available for Windows instances running on Oracle Cloud Infrastructure. See the System Requirements for platforms currently supported by JMS.
- Enable Management Agents on Compute Instances and ensured that you meet the prerequisites (see Perform Prerequisites for Deploying Management Agents on Compute Instances).
- You have set up the policies described in Setting Up Oracle Cloud Infrastructure for Java Management Service.
Overview
- Enable the Management Agent plugin.
- Deploy the JMS service plug-in Java Usage Tracker.
- Enable Lifecycle Management Operations.
- Associate the management agent with your fleet.
- Configure Java Usage Tracker.
- Verify the installation of the management agent on your host.
- (Optional). Customize which file system paths on your host will be scanned to discover installations of Java Runtimes, and how frequently the agent will report data to JMS.
Steps
/var/log/oracle-cloud-agent/plugins/oci-jms/
directory.
Upgrading a Management Agent
Oracle recommends using the latest version of the Management Agent software. Upgrading gives access to the latest functionality. For information about getting the latest version, see Upgrading Management Agents.
Oracle recommends the Automatic Upgrade method. By default Auto Upgrade is set to Disable by the Management Agent Cloud Service. Follow the steps in Enable Auto Update to enable automatic upgrade of Management Agents.
Modifying Management Agents' Settings
This feature requires version
210918.1427
or later of the management agent software installed on all of your hosts. You can download the latest version of the software by using the contextual menu of a fleet in the Fleet Dashboard or from a fleet's Fleet Properties Tab. See also Installing a Management Agent.- Which file system paths the fleet's management agents scan on their hosts to discover Java Runtime installations
- How frequently the fleet's management agents report usage and Java Runtime installations to JMS
Prerequisites: You have selected a fleet from the fleet dashboard.
Include/Exclude Path Patterns
Pattern | Description |
---|---|
** |
This pattern specifies all volumes. (This is equivalent to / on Linux.)
|
/* |
This pattern matches one directory with any name. (For example, on Linux the pattern /usr/*/java matches /usr/lib32/java and /usr/lib64/java .)
|
/** |
This pattern matches one or more directories with any name. (For example, on Linux the pattern /usr/**/java matches /usr/lib32/java and /usr/lib/jvm/java .)
|
|
System or environment variable. If the variable is null or not set, the value of the optional subsequent variable expansion is used. For example, if you specify (This syntax simulates that provided by Shell Parameter Expansion.) |
Characters including
?
, [
, ]
, {
, and }
may exist in the path, and are not expanded when matching paths. For example, the include path pattern /[a-c]/jav?/*c
assumes there is a file system path with exactly this name.
Modifying a Management Agent's Tags
- You made a mistake when installing the agent and want to correct its tag(s)
- You created a fleet and want it to contain the agent's corresponding managed instance
If you modify the agents tags so that the agent moves to a new fleet, the historic data of the managed instance associated with the agent will not move to the new fleet.
For example, if the tag of an agent associated with a managed instance was changed from fleet A's OCID to fleet B's OCID on January 1, 2021, then fleet A will contain the managed instance's data until January 1, 2021 and fleet B will contain the management instance's data from January 1, 2021.
For more information, see Resource Tags.
Management Gateway
The Management Gateway provides a single point of communication between the Management Agents (or any other customer-side products) and the Oracle Cloud Infrastructure.
If you want your agents to communicate through a single point with the Oracle Cloud Infrastructure, follow the instructions in Management Gateway.
Uninstalling a Management Agent
If you no longer want to use JMS, or if you have encountered the error message "Please uninstall the agent and remove the service file before installing the new agent!", remove the agent by following the procedure described in Remove Management Agents.