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
[collector] section in the
custom.properties file, if it doesn't already exist.
DumpSupported property in this section and set the value to
[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:
[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
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:
/tmp under Linux
Because of possible automatic purging, we recommend that you not use the Linux directories
/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:
|Valid path of the storage directory used for dump storage|
|Storage quota in GBs. If full, the oldest dumps are overwritten until enough space is available to store a new dump.|
|Maximum age of a memory dump in days until the dump is automatically overwritten|
|Maximum number of concurrent dump uploads from OneAgents|
|unset||A custom download URL (for example, if ActiveGate is behind a load balancer or if ActiveGate only detects an IP address and the user requires an FQDN). The URL must contain the correct schema and port.|
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 path dumpDir = dump maximum size in GB for stored memory dump maxSizeGb = 100 maximum age in days for keeping stored memory dumps maxAgeDays = 7 maximum number of concurrent file uploads supported maxConcurrentUploads = 5