LOCK.TRACER

Top  Previous  Next

 

The LOCK.TRACER command enables or disables lock tracing and provides a tool to display the logged data.

 

 

Format

 

LOCK.TRACER ONStart logging

 

LOCK.TRACER OFFStop logging

 

LOCK.TRACER {USER n} {LPTR {n}}Display or print logged data

 

 

The LOCK.TRACER command requires administrative rights and is normally only present in the VOC of the QMSYS account. The V-type VOC entry can be copied to other accounts if required.

 

Enabling lock tracing logs locking related actions for all users. The volume of data recorded and the impact on performance are likely to be significant so it is best to enable logging only for short periods. The USER option to the command filters data on display to show only actions relating to the specified QM user number.

 

The logged data is written to a file named locktrace in the TEMP subdirectory of the QMSYS account. On ECS mode systems, this file will be recorded with UTF-8 encoding. Re-enabling the lock tracer will overwrite any existing locktrace file.

 

The report displayed by the third form of the LOCK.TRACER command requires a terminal width of 132 characters. When using a QMConsole session on Windows, the window will automatically adjust size. For all other terminal types, the width must be configured in the terminal emulator.

 

Users may wish to write their own log analysis tool to perform more advanced filtering. Each line of the log is a value mark delimited dynamic array where the values are:

1.Timestamp as an epoch value

2.QM user number

3.File pathname

4.Record id

5.Action code

6.Program name

7.Program execution offset as a hexadecimal value

8.Program line number, -1 if not available

 

The action code is a numeric value. The list below shows the actions for each value, and short text used in the default report.

 

1

Get RU

Get record update lock

2

Get RL

Get shareable read lock

3

RU->RL

Downgrade record update lock

4

RL->RU

Upgrade shareable record lock

5

Get FX

Get file exclusive lock

6

Rel RX

Release record lock

7

Rel FX

Release file lock

 

 

See also:

Application Profiling