How do I install Dynatrace OneAgent on Solaris?

Dynatrace supports Oracle Solaris (x86 and SPARC) for Java and Apache HTTP server. If your infrastructure is based on these technologies you can use Dynatrace OneAgent to effectively monitor your hosts, services, and user experience.

If a proxy is required to connect to Dynatrace Server, we recommend that you install Security Gateway and have Dynatrace OneAgent use Security Gateway for this purpose.

Install Dynatrace OneAgent on Solaris

Select Deploy Dynatrace from the navigation menu.

Click Start Installation.

Click the Solaris button.

Choose the CPU architecture of your environment.

Click Copy to copy the wget command.

Log into your Solaris host and execute the wget command. Create a folder on your local system for OneAgent (for example, /opt/dynatrace/oneagent) and unzip the ZIP archive into the folder.

Note:
The wget command isn't installed on Solaris by default. Either install it or use an alternative means of downloading OneAgent.

Attention:
While downloading, you may encounter the following error:

Releasing 0x0000000239ae1890 (new refcount 1). Initiating SSL handshake.
SSL handshake failed.
Closed fd 5
Unable to establish SSL connection.

This can be caused by selecting the wrong SSL or TLS protocol on handshake. As different operating systems act differently (both server and client side), you must specify some protocols manually under certain conditions.

For this specific case, to select the correct protocol, you must specify --secure-protocol=tlsv1_2 as an additional parameter of the wget command. The command should appear as follows:

wget --secure-protocol=tlsv1_2 -O Dynatrace-OneAgent-Solaris-xxx-1.xxx.xxx.zip "https://xxx/xxx/api/v1/deployment/installer/agent/solaris/paas/latest?Api-Token=xxx&arch=x86"

It can also be set permanently by creating the file ~/.wgetrc with the following content:

secureprotocol = tlsv1_2

Switch to the installation folder and run . dynatrace-env.sh to set TENANT, TENANTTOKEN, and the CONNECTION_POINT to prepare your environment for OneAgent injection. To inject OneAgent directly into a Java process, call . dynatrace-java-env.sh 64. For 32-bit Java processes, omit the 64 parameter. This will implicitly call dynatrace-env.sh and extend your $JAVA_OPTS and $JAVA_OPTIONS environment variables. If your Java process makes use of these environment variables, there's nothing more to do except start the Java process.

Note:
In contrast to other platforms, root access isn't required for installation of OneAgent on Solaris. OneAgent can be installed in any folder. However, as all monitored applications need to be able to read the library, ensure that the permissions allow this. Also, be sure to reference the folder correctly in the subsequent steps of your deployment.

Instrument your application

Depending on your application's technology, follow the relevant steps described below to instrument your application on Solaris.

Modify the command line of your Java application:

java -agentpath:/opt/dynatrace/oneagent/agent/bin/solaris-<arch>-<bitness>/liboneagentloader.so=tenant=<tenantUUID>,tenantToken=<tenant-token>,server=<communicationEndpoints> <MainClass>

or modify the JAVA_OPTS environment variable, if applicable:

JAVA_OPTS=-agentpath:/opt/dynatrace/oneagent/agent/bin/solaris-<arch>-<bitness>/liboneagentloader.so=tenant=<tenantUUID>,tenantToken=<tenant-token>,server=<communicationEndpoints>:$JAVA_OPTS

  • tenantUUID is the environment ID of your Dynatrace environment that should be pulled from dynatrace-env.sh (located in the OneAgent installation root directory). The tenantUUID parameter is represented in the script as DT_TENANT.

  • tenantToken is the token that OneAgent uses to connect to Dynatrace Server. It should be pulled from dynatrace-env.sh (located in the OneAgent installation root directory). The tenantToken parameter is represented in the script as DT_TENANTTOKEN.
    Attention: This token should not be confused with Dynatrace API or PaaS tokens. Those tokens can't be used here.

  • communicationEndpoints corresponds to one or multiple HTTP addresses that represent Dynatrace Servers or Security Gateways. The communicationEndpoints parameter is represented in the script as DT_CONNECTION_POINT. For example, the dynatrace-env.sh (located in the OneAgent installation root directory) may contain the following:

    export DT_CONNECTION_POINT="https://x1.live.dynatrace.com/communication;https://x2.live.dynatrace.com/communication;https://x3.live.dynatrace.com/communication"
    

    In this case, the parameter would be

    server=https://x1.live.dynatrace.com/communication;https://x2.live.dynatrace.com/communication;https://x3.live.dynatrace.com/communication
    

Restart your Java process. The newly started Java process should show up in Dynatrace.

Update Dynatrace OneAgent on Solaris (x86 and SPARC)

To update an installed OneAgent instance on Solaris

  1. Select Deploy Dynatrace from the navigation menu.

  2. Click the Start installation button.

  3. Select your environment architecture (x86/64 or SPARC).

  4. Click Copy to copy the wget command to your clipboard.

  5. Log into your Solaris host and execute the wget command. Note: The wget command isn't installed on Solaris by default. You must either install it or use another means of downloading OneAgent.

  6. Create a folder on your local system for OneAgent (for example, /opt/dynatrace/oneagent-update).

  7. Unzip the ZIP archive into the folder.

  8. Stop the monitored processes.

  9. Rename the current OneAgent installation directory (for example, /opt/dynatrace/oneagent-131) using the following command: mv /opt/dynatrace/oneagent /opt/dynatrace/oneagent-131. This folder can be deleted following the OneAgent update.

  10. Rename the updated OneAgent folder to point to the original installation directory (for example, /opt/dynatrace/oneagent) using the following command: mv /opt/dynatrace/oneagent-update /opt/dynatrace/oneagent

  11. Restart all processes that are to be monitored.