Configure ActiveGate for memory dump storage
The following configuration of ActiveGate for memory dump storage is applicable to both Environment ActiveGate and Cluster ActiveGate.
When your application experiences memory leaks or high object churn, it’s important that you get memory dumps so you can analyze these issues. In production environments, this is often a challenge when you can’t log into the environment and you have no other means of triggering memory dumps. Dynatrace enables you to both trigger and securely download memory dumps to the analysis tool of your choice. To enable memory dumps, you need to configure your ActiveGate as described below.
If you configure an ActiveGate to collect memory dumps, and then restart the ActiveGate service, all instances of OneAgent will automatically reconnect and recognize that the ActiveGate can now store memory dumps. From now on, whenever a memory dump is successfully triggered, the dump will be uploaded automatically to the correct ActiveGate. Once safely stored on the ActiveGate, the OneAgent deletes the local file from its storage. Note that OneAgent automatically deletes a memory dump on the original host after one hour.
Before you begin
Familiarize yourself with the basic rules for working with ActiveGate configuration.
Activate dump functionality
Create the [collector]
section in the custom.properties
file, if it doesn't already exist.
Specify the DumpSupported
property in this section and set the value to true
.
[collector]DumpSupported = true
Specify dedicated dump directory (optional)
Unless configured otherwise, ActiveGate saves memory dumps in a default directory.
To use a custom path, specify the path in the properties file and create the directory with appropriate permissions:
Create the [dump]
section in custom.properties
(if it doesn't already exist) and then specify the dumpDir
property in this section. For example:
[dump]dumpDir = dump
The dumpDir
property can contain a relative path, for example, dumpDir = mydir
. In this case, the directory will be a subdirectory of the default location. It can also be an absolute path, for example, dumpDir = C:\data\memory-dumps
.
Create the directory, if it does not already exist, and make sure that it has correct access permissions for the user running the ActiveGate service. This is by default dtuserag
for Linux, and Local Service
for Windows:
-
Linux systems:
Read
,Write
, andExecute
-
Windows systems:
Read
,Write
, andModify
Use of /temp
or /tmp
under Linux
Because of possible automatic purging, we recommend that you not use the Linux directories /temp
, /tmp
, or their subdirectories to install ActiveGate or store any data generated or used by ActiveGate.
Specify parameters for managing dump files (optional)
Also in the [dump]
section, you can specify the following properties:
dumpDir
dump
maxSizeGb
100
maxAgeDays
7
maxConcurrentUploads
5
downloadUrl
Restart ActiveGate
If you modify your ActiveGate configuration, you must restart the ActiveGate main service to put your changes into effect.
Example custom.properties file contents
[collector]DumpSupported = true[dump]# relative to collector root dir or absolute pathdumpDir = dump# maximum size in GB for stored memory dumpmaxSizeGb = 100# maximum age in days for keeping stored memory dumpsmaxAgeDays = 7# maximum number of concurrent file uploads supportedmaxConcurrentUploads = 5