Page tree
Skip to end of metadata
Go to start of metadata


Overview

Dynatrace Synthetic provides deep application monitoring and performance lifecycle management. The Dynatrace Synthetic LAM connects with Dynatrace Synthetic and fetches alerts from it. The  alerts are then forwarded to Moogsoft AIOps.

Process Overview


  1. LAM reads the configuration from the  dynatrace_synthetic_lam.conf file.
  2. LAM connects to the Alert Management Web Services API with given WSDL location, username, and password.
  3. LAM calls the Web Service Method GetAlertHistory with parameters as username, password, start time and end time.
  4. LAM calls the Web Service Method GetLMAlertHistory with parameters as username, password, start time and end time.
  5. When the LAM starts for the first time, it takes the end time as the current time and the start time as 24 hrs before the current time, and in the subsequent calls, it takes start time as the end time of the previous call and the end time is set with the current time.
  6. The response is received with incident data in XML format.
  7. The events are parsed and converted into normalized Moogsoft AIOps events.
  8. The normalized events are then published to MooMS bus.

Dynatrace Synthetic LAM Configuration

The alarms received from Dynatrace Synthetic are processed according to the configurations in the dynatrace_synthetic_lam.conf file. The processed alerts are published to Moogsoft AIOps.

The configuration file contains a JSON object. At the first layer of the object, the LAM has a parameter called config, and the object that follows config has all the necessary information to control the LAM.

The following sections are available for configuration in the Dynatrace Synthetic LAM

Monitor

The Dynatrace Synthetic LAM takes the incidents from Dynatrace Synthetic. The user can configure the parameters here to establish a connection with Dynatrace Synthetic.

config :
    {
        monitor:
        {

            name                     : "Dynatrace Synthetic Monitor",

            class                    : "CDynatraceSyntheticMonitor",

			wsdl_location            : "https://gpn.webservice.gomez.com/AlertManagementService20/AlertManagementWS.asmx"

            user_name                : "username",

            password                 : "password",

            #encrypted_password      : "ieytOFRUdLpZx53nijEw0rOh07VEr8w9lBxdCc7229o=",

            polling_interval         : 60,

            max_retries              : 10, 

            retry_interval           : 60
			
	},


  • name and class: These fields are reserved and should not be changed the default values are Dynatrace Synthetic Monitor and CDynatraceSyntheticMonitor respectively
  • wsdl_location: Enter the wsdl (Web Services Definition Language) location of the Dynatrace Synthetic server. This will be same as given in the above example

  • user_name and password: Enter the username and password for accessing Dynatrace Synthetic server
  • encrypted_password: If an encrypted password is to be used then encrypt the password using the moog_encryptor described below, enter it in this field, and comment the password field. At a time either password or the encrypted_password field is used. If both the fields are not commented, then the field encrypted_password will be used by the Dynatrace Synthetic LAM 
  • polling_interval: The polling time interval between the requests after which the event data is fetched from Dynatrace Synthetic. The polling interval is entered in seconds

    The default value is set to 60 seconds, if 0 or a value less than 0 is entered in this field then the time interval is by default set to 60 seconds

  • max_retries: The maximum number of retry attempts to reconnect with Dynatrace Synthetic in case of a connection failure

    The default value is set to 10, if 0 is entered in this field then the LAM by default takes the value 10 and will try at least 10 times to reconnects

    If all the number of retries are exhausted, then an alert is sent to Moogsoft AIOps about the connection failure. For re-establishing the connection the LAM has to be restarted

  • retry_interval: The time interval between two successive retry attempts

    The default value is set to 10 seconds, if 0 is entered in this field then the time interval is by default set to 60 second

The entry in the fields polling_interval, max_retries and retry_interval should be an integer, therefore enter the values in these fields without quotation mark 

Agent

Agent allows the user to define two parameters:

agent:
        {
                name    : "Dynatrace Synthetic"
                #log    : "/var/log/moogsoft/dynatrace_synthetic_lam.log"
        },


The above example specifies:  

name: This is the agent name. The events sent to MooMS by the Dynatrace Synthetic LAM are identified by the agent name in the log. In this example the agent name is Dynatrace Synthetic

log: In this instance, the Dynatrace Synthetic LAM will write its ingress contents in the file dynatrace_synthetic_lam.log located at /var/log/moogsoft/

HA Configuration

Refer the document HA Configuration of LAM

Mapping 

For events received from Dynatrace Synthetic, a user can directly map the alert/event fields of Dynatrace Synthetic with moogsoft fields. In the case of an event received in text format, the event is first tokenised in the variable section, and the tokenised event is then mapped here in the mapping section. The parameters of the received alert/event are displayed in Moogsoft AIOps according to the mapping done here.

 mapping :
        {
            builtInMapper:  "CJsonDecoder",
            catchAll: "overflow",
            rules:
            [
                { name: "signature", rule:      "$monitorId" },
                { name: "source_id", rule:      "$siteIP" },
                { name: "external_id", rule:    "$alertId" },
                { name: "manager", rule:        "Dynatrace Synthetic" },
                { name: "source", rule:         "$siteIP" },
                { name: "class", rule:          "$alertType" },
                { name: "agent", rule:          "$LamInstanceName" },
                { name: "agent_location", rule: "$siteName" },
                { name: "type", rule:           "$alertType" },
                { name: "severity", rule:       "$alertState", conversion: "sevConverter" },
                { name: "description", rule:    "$description" },
                { name: "agent_time", rule:     "$timeStamp"}
            ]
        },
        filter:
        {
            presend: "DynatraceSyntheticLam.js"
        }


The above example specifies the mapping of the Dynatrace Synthetic alert fields with the Moogsoft AIOps fields. The stringToInt is used to convert the time received in the string format into an integer format.

The signature field is used by the LAM to identify correlated alerts

Constants and Conversions

Constants and Conversions allow the user to convert formats of the received data defined users.

constants:
        {
		severity:
            {
                "CLEAR"         : 0,
                "GOOD"	        : 2,
                "WARNING"       : 3,
                "BAD"         	: 4,
                "SEVERE" 		: 5
            }
        },
        conversions:
        {
            sevConverter:
            {
                lookup: "severity",
                input:  "STRING",
                output: "INTEGER"
            },
	    	            
			stringToInt:
            {
                input:      "STRING",
                output:     "INTEGER"
            }
        },


The above example specifies:

  • Severity and sevConverter: The severity field has a conversion defined as sevConverter in the Conversions section, this looks up the value of severity defined in the severity section of constants and returns back the mapped integer corresponding to the severity
  • stringToInt: It is used in a conversion, which forces the system to turn a string token into an integer value

catchALL 

The attribute that is never referenced in a rule is collected and placed as a JSON object in a variable called overflow defined here and passed as part of the event.

 mapping :
        {
            builtInMapper:  "CJsonDecoder",
            catchAll: "overflow",
            rules:
            [
                { name: "signature", rule:      "$monitorId" },
                { name: "source_id", rule:      "$siteIP" },
                { name: "external_id", rule:    "$alertId" },
                { name: "manager", rule:        "Dynatrace Synthetic" },
                { name: "source", rule:         "$siteIP" },
                { name: "class", rule:          "$alertType" },
                { name: "agent", rule:          "$LamInstanceName" },
                { name: "agent_location", rule: "$siteName" },
                { name: "type", rule:           "$alertType" },
                { name: "severity", rule:       "$alertState", conversion: "sevConverter" },
                { name: "description", rule:    "$description" },
                { name: "agent_time", rule:     "$timeStamp"}
            ]
        },


The Dynatrace synthetic field messageId is sent to the LAM. Since it is not mapped to a field in the dynatrace_synthetic_lam.conf file, it is placed in the overflow JSON object. The fields that are placed in the overflow variable can be viewed in the Dynatrace Synthetic LAM log file.

An example of an overflow JSON object created in the Dynatrace Synthetic LAM log file:

"overflow":"{\"messageId\":\"158897286\"}"

Quotes

In some instances, the attribute strings are quoted. Our JSON parser ignores it, but the standard requires quoting for all strings, so Moogsoft recommends that user quote all strings 

Comments

A user can comment out lines by prefixing them with a hash. 

Starting the Dynatrace Synthetic LAM

To start the Dynatrace Synthetic LAM enter the following command:

service dynatracesyntheticlamd start

To stop the Dynatrace Synthetic LAM enter the following command:

service dynatracesyntheticlamd stop


To view the status of Dynatrace Synthetic LAM, enter the following command:

service dynatracesyntheticlamd status

Command line attributes

The dynatrace_synthetic_lam is a command line executable that can be run as a service daemon, and takes four attributes, which can be viewed by typing:

 dynatrace_synthetic_lam --help

Option

Description

--config

Points to a pathname to find the configuration file for the LAM. This is where the entire configuration for the LAM is specified

--help

Displays all the command line options

--version

Displays the component’s version number

--log level

Specifies the level of debugging. By default, User gets everything. In common with all executables in MOOG, having it set at that level can result in a lot of output (many messages per event message processed).

In all production implementations, it is recommended that log level is set to WARN, which only informs user of matters of importance



Version Information


LAM Version

Tool Version

Tested?

Expected to Work

1.0

Synthetic Monitoring Platform 2017

Yes

Yes

1.1

Synthetic Monitoring Platform 2017

Yes

Yes

1.2

Synthetic Monitoring Platform 2017

Yes

Yes

System Information

This LAM was tested on a system with the following configurations:

CPU2 core
RAM4 GB
Operating SystemCentOS Linux release 6.7

The system must at least have the above mentioned system requirements to run the LAM.


  • No labels