Configuration

Kernel Trace for OS/2 provides a stanza-based, text, configuration file.  This file, KTRACE.CFG, gives the user a simple means to modify the behavior of the program.  Please refer to the File Listing section of this document to determine where this file must be located in order for Kernel Trace to find it and use the information it contains.

Editing KTRACE.CFG

Configurable options provided by the KTRACE.CFG file are:

Sections

KTRACE.CFG is comprised of two sections:  TRACEPOINTS and DEFAULTS.  Both sections and their contents are described below.  Any other sections found in this file will be ignored.

TRACEPOINTS

This section contains a key/value pair for each tracepoint alias.  The following syntax rules apply to this section of the file:

Base Tracepoint Identifiers
TRACEPOINT ALIAS HEX VALUE TRACEPOINT ALIAS HEX VALUE
OPEN_PRE 0000000001 FINDFIRSTS3X 0000020000
OPEN_POST 0000000002 FINDNEXT 0000040000
READ_PRE 0000000004 FINDFIRSTNEXT3X 0000080000
READ_POST 0000000008 FINDCLOSE 0000100000
WRITE_PRE 0000000010 FINDCLOSE3X 0000200000
WRITE_POST 0000000020 SETFILESIZE 0000400000
CLOSE 0000000040 QUERYFILEINFO 0000800000
CHGFILEPTR 0000000080 SETFILEINFO 0001000000
DELETE_PRE 0000000100 SETFILEMODE 0002000000
DELETE_POS 0000000200 SETPATHINFO 0004000000
MOVE_PRE 0000000400 MAKEDIR 0008000000
MOVE_POST 0000000800 CHANGEDIR 0010000000
LOADEROPEN 0000001000 REMOVEDIR 0020000000
GETMODULE 0000002000 CREATEVDM 0040000000
EXECPGM 0000004000 CREATEVDMPOST 0080000000
EXECPGMPOST 0000008000 SETDATETIME 0100000000
FINDFIRST 0000010000 DEVIOCTL 0200000000

Aliases for Common Tracepoint Groupings
These aliases have been created in the default ktrace.cfg file in order to group similar tracepoints together.
ALL 03FFFFFFFF 
OC OPEN_POST+CLOSE
RW READ_POST+WRITE_POST+CHGFILEPTR
FIND FINDFIRST+FINDFIRST3X+FINDNEXT+FINDFIRSTNEXT3X+FINDCLOSE+FINDCLOSE3X
INFO QUERYFILEINFO+SETFILEINFO+SETFILESIZE+SETFILEMODE+SETPATHINFO
X EXECPGMPOST+LOADEROPEN+GETMODULE+CREATEVDMPOST


DEFAULTS
This section allows the user to customize defaults for the program's command line arguments. Default values are specified as keyword/value pairs, using the syntax KEY = VALUE.  The following syntax rules apply to this section of the file:

Note: Command line parameters take precedence over values defined in ktrace.cfg.
 
KEYWORD
Command Line
Equivalent
DEFINITION
FILENAME  -fFILENAME Default Trace Filename
Note: filename extension must be .ktr  -  other extensions will be ignored.
MAXSIZE  -mMAXSIZE Default maximum trace size in megabytes
PIDLIST  -iPIDx Default list of process IDs to trace, separated by comma (,)
PIDMASK -pPIDMASK Default pattern of process names to trace
FILEFILTER -lFILEFILTER Default pattern of filenames to trace (file-related tracepoints only)
TRACEPOINTS  -tTRACEPOINTS Default active tracepoints
COMMENT -cCOMMENT Default comment for trace files

© 2001 Golden Code Development Corporation.  ALL RIGHTS RESERVED