Use
You can use this function if you want to activate trace level 2 or 3 for a long period, but want to ensure that the trace file does not become too large. This is useful if you are trying to locate a sporadic error. If you are "waiting" for a particular trace output, you can specify that the trace file should be saved after the pattern you are searching for is found, and that the trace level should then be reset to 1.
In this way, you can easily control the size of the trace files. You can also search the trace file for a particular character string without running the risk of filling up your hard disk if a high trace level is active.
Features
Set Size Limit for Trace Files
To activate trace logging, you have to set the parameter rdisp/TRACE_LOGGING. Here, you also specify the maximum size of the trace file.
If the trace file reaches that size, the content is written to a log file with the name of the trace file and the extension .old. The current trace file is then reset. The parameter rdisp/autothtime is used to define how often the trace file should be checked and, if necessary, reset. The default is 60 seconds.
Trace logging is active for the following trace files:
Specify Trace Components
The parameter
rdisp/TRACE_SEARCH_LIST is used to specify a list of trace components that you want taken into account in the automatic trace search.As a value for this parameter, you can enter a list with the following elements (use a comma or a semicolon to separate elements):
rdisp/TRACE_SEARCH_LIST = WP, ICMAN
means: all work process trace files and the ICM trace file are searched.Search Trace Files for a Pattern
The parameter
rdisp/TRACE_PATTERN_<x> is used to search the trace files for a specific pattern. When the specified file size if exceeded, the file is then searched for this pattern. If the pattern is found, the trace level is reset to 1 for all active components.You can also use wildcards (* for any character string, ? for a single character) in the pattern. Use the backslash (\) to ensure that special characters are treated as ordinary characters. See below for examples.
For the sake of readability, the search patterns in the following examples are enclosed in inverted commas. When specifying your own search terms in RZ11 or in the profiles, however, enter them without inverted commas.
Activities
Proceed as follows.
You can dynamically change this parameter in transaction RZ11.
The parameter values have the following syntax:
rdisp/TRACE_LOGGING = on, <n> [k m] off
The first part specifies that logging is active. The value here can be either
ON or OFF. If logging is active, you can specify the file size in the second part.rdisp/TRACE_LOGGING = off
: no trace loggingrdisp/TRACE_LOGGING = on, 1000
: trace is logged if the trace file contains more than 1000 bytesrdisp/TRACE_LOGGING = on, 20 k
: trace is logged if the trace file conatins more than 20 KBrdisp/TRACE_LOGGING = on, 30 m
: trace is logged if the trace file is greater than 30 MBThe search pattern can contain the special character
Example
Click
here for an example of trace logging in use.