The RFC call work process developer trace monitoring, is used here as an example of log file monitoring. There is a trace file containing, for example, RFC environment errors, for each work process. These files are in the work
folder of the instance directory. Create a metric group to monitor the number of times the string ERROR occurs in all trace files.
To monitor the RFC call work process developer traces and integrate them in the monitoring and alerting infrastructure, proceed as follows:
Call the SAP Solution Manger Configuration (transaction SOLMAN_SETUP).
Go to Technical Monitoring
, select the use case System Monitoring
, and go to the step Template Management
.
Go to change mode by choosing Edit
.
To monitor an instance-specific ABAP log file, create a customer template for the
.Select this SAP template, and choose Create Customer Template
. In the Template Settings
tab, enter ABAP 7.0x with Dev. Trace Monitoring as the template name. You can enter notification and incident settings for the template, here. The example uses the global settings, so no entries are required.
Save the template. As you only use this template as a test, and do not want to transport it further, set the Local Object
flag.
Go to Expert mode, and choose Creating a User-Defined Metric.
To create a new metric, choose the drop-down box
.In the user-defined metric creation wizard, enter the required information in the 6 tabs. In the Overviewt
enter the basic metric details.
Input field |
Meaning |
---|---|
|
Enter the metric name RFC Developer Trace Errors. The metric is displayed in technical monitoring under this name. |
|
Specify the metric category |
|
Specify the class |
|
The data type of a metric depends on the data supplier. The data supplier |
|
Enter the metric unit |
|
Set this flag, so that the metric is used. |
|
Enter a description of the metric. For the example, copy the metric name above. |
In the Data Collection
tab, specify the value to be assigned to the metric, by specifying the data supplier and its input parameters.
Input field |
Meaning |
---|---|
|
Specify the value capture frequency; use the default value |
|
Specify how the data is captured. For the log file monitoring data supplier, it is |
|
Specify the data provider which monitors any files for text patterns. This is |
When you have specified the data provider, enter its input parameters. For a metric group, specify which parameters apply to the whole group, and which vary between variants (in this case, the parameter FILEPATTERN
). A metric variant is created in the metric group for each file whose name satisfies the input parameter FILEPATTERN
.
Reset the flag in the Configure
column for the following parameters, and enter the data which is the same for all variants in the group:
Parameter ID |
Meaning |
---|---|
|
Specify whether each read reads the file from the beginning, or only the rows which have been added by the data provider since the last read. In this example, choose |
|
This is the full path to the folder containing the monitored files. Enter \Q$INSTANCE_FULL_PATH$/work\E ein ( |
|
The search pattern for which the file is to be monitored. Enter .*ERROR.*. |
For the parameter FILEPATTERN
, set the flag in the Configure
column, choose Add Variant
, and enter the name pattern of the files to be monitored, in the table Metric Group Variants
. In this case, all files which begin with dev_rfc, followed by a sequence of digits (the work process number), are to be monitored. The file name should end with that, so that .old files are not monitored. As a regular expression, this is dev_rfc[0-9]+$.
Note
General information about this data provider and its input parameters is under Log File Monitoring Data Providers.
Specify, in the Data Usage
tab, which components use this metric. Accept the default settings.
Specify in the Threshold Values
tab, how the delivered measured values of the metric are rated (status green
, yellow
or red
). In this case, the status should be red if the search pattern ERROR
occurs at least once. Choose the threshold type Numeric (Green/Red)
, and in the input field Trigger at Value
, enter 1.
You can restrict the validity of the metric to specified types of managed objects, in the Validity
tab. Accept the default setting.
In the Others
tab, enter the technical name of the metric (it must begin with Z, so that it is in the customer namespace). In this example, specify the technical name Z_RFCERRORS.
Go to the next step in the wizard. Assign the metric to alerts. You cannot yet do so, because the alert does not yet exist.
End the wizard with End
, and save the metric.
To create a new alert, choose the drop-down box
.In the user-defined alert creation wizard, enter the required information in the 7 tabs. In the Overview
enter the basic alert details.
Input field |
Meaning |
---|---|
|
Enter the alert name Too Many Errors in RFC Developer Trace. The alert is displayed in technical monitoring Alert Inbox, under this name. |
|
Specify the im alert category |
|
Rate the alert 5 (medium). |
|
Do not change this flag. |
|
Set this flag, so that the alert is used. |
|
Enter a description of the alert. For the example, copy the alert name above. |
You can overwrite the default values for this alert in the Messages
, Notifications
, Third-Party Component
and Automatic Reactions
tabs. Leave them unchanged for this example.
In the Rules
tab, specify how an event or alert is rated if it depends on several metrics. Accept the default setting Rate as Worst Case
.
In the Others
tab, enter the technical name of the alert (it must begin with Z, so that it is in the customer namespace). In this example, specify the technical name Z_RFCERRORS_ALRT.
Go to the next step in the wizard. Assign the alert to the metric. The metric list shows the metrics of this category which can be assigned. The metric RFC Developer Trace Errors
should be displayed. Assign this metric.
Exit the wizard by choosing Finish
.
You have now created a template, and a metric and a customer alert for it. Save the template.
To use the template for your managed objects, assign it to them, and activate.
Go to the next configuration step, (Specify Scope
), select the managed objects (in this case, technical systems of type ABAP), and go to the next step (Set Up Monitoring
).
You can assign these managed objects to the template. Choose Assign Templates
for the instances, und the template ABAP 7.0x with Dev. Trace Monitoring
, for the product. Choose Copy and Activate
, to activate the assignment.
Call the Technical Monitoring work center.
Call the ABAP system to which you have assigned the template, and start System Monitoring
.
Select a managed object. System Monitoring is shown in a new window.
Go to the new metric by expanding an instance in the Details
and Instance Exceptions
subscreens.