Entering content frameProcedure documentation Enabling the Database Trace Function Locate the document in its SAP Library structure

Use

The Database Manager gives you the option of enabling the database trace function if errors occur.

Note

You should use this function when asked to do so by your SAP DB support organization. We would not recommend you enable the database trace function unless it is really necessary, because it seriously affects the performance of the database instance.

The database trace documents all the reactions of the database kernel to database statements. This also means that it can be used not only to trace errors that occur when statements are processed but also to provide a more exact classification of inconsistencies caused, for example, by hardware errors. If the database trace is enabled, you should be running the Structure linkdatabase instance with the smallest load possible, and only those actions needed to reproduce the error should be performed on the database instance.

Disable the database trace function as soon as the actions needed for the analysis have been logged.

Procedure

You can execute the log functions below either individually or in a group, which you can define yourself.

Logging Database Statements in General

Choose Instance ® Check ® Kernel Trace.
On the Options tab page, select the required database trace options in the list. If the options support the selection of a trace level, the system default value is displayed in column Level.

If you then choose KernelTrace ® Selected Items ON, you activate the database trace for the selected database trace options with the system default value for the trace level.

If you want to change the trace level for the selected database trace options, choose KernelTrace ® Selected Items ON with Level... You are now able to choose a different trace level. The higher the trace level, the greater amount of detail is provided in the information collected by the database trace.

Choose KernelTrace ® Selected Items OFF to disable the database trace.

Logging Database Statements in a Specific User Session

Choose Instance ® Check ® Kernel Trace.

The database trace is written for all user sessions by default. The default setting can be changed if necessary:

To do so, choose the Advanced tab page and select Trace session. Then choose whether the database trace is to be written for the current session or for a specific user session. In this case, enter the session ID of the required user session.

Note

To locate the session ID of a user session, choose Instance ® Information ® Sessions.

Logging the Occurrence of Specific Errors

Choose Instance ® Check ® Kernel Trace.

On the Advanced tab page, select Stop on error. Enter the code of the error whose occurrence is to stop the creation of the database trace.

Creating and Display the Database Trace Log

Choose Instance ® Check ® Kernel Trace.

On the Protocol tab page, select the required options.

Then choose Kernel Trace ® Flush to write the information still contained in the buffer to the trace and thus update the database trace before the log file is created.

Choose KernelTrace ® Make Protocol. The database trace is then converted to a legible format. To open the log, choose Instance ® Check ® Files. Select the Kernel Trace Log and choose Files ® View.

 

 

 

Leaving content frame