Trace CLI/ODBC configuration keyword
Turns on the CLI/ODBC trace facility.
- db2cli.ini keyword syntax:
- Trace = 0 | 1 | db2trc
- Default setting:
- No trace information is captured.
- Equivalent environment attribute:
- SQL_ATTR_TRACE
- Usage notes:
When this option is set to value (1), CLI/ODBC trace records are appended to the file indicated by the TraceFileName configuration parameter or to files in the subdirectory indicated by the TracePathName configuration parameter. Trace CLI/ODBC configuration keyword will have no effect if neither TraceFileName or TracePathname is set.
[COMMON]
Trace=1
TraceFileName=E:\TRACES\CLI\MONDAY.CLI
TraceFlush=1
When this option is set to value (db2trc), the trace facility of the Db2® instance or the Db2 Administration Server (DAS) will be started. The trace facility is controlled by the db2trc command and records information about operations and formats this information into readable form. Enabling the trace facility (OFF by default) might impact your system's performance. As a result, only use the trace facility when directed by a Db2 technical support representative; otherwise, turn off the trace once enough information has been recorded.
Setting the Trace CLI/ODBC configuration keyword to (db2trc) will automatically
run db2trc on command with -cli option. To stop
tracing, command db2trc off
must be run by the user.
db2trc dump <dump_filename>
db2trc off
db2trc fmt -cli <dump_filename> <ODBC-CLI_trace_filename>
db2trc on -f clitrc.dmp -m *.*.CLITRC.*.*
After tracing to a file, the trace
records do not need to be dumped, but do still require formatting to obtain a final CLI Trace file.For more information about using the db2trc command, see db2trc Trace Command.
(This option is contained in the Common section of the initialization file and therefore applies to all connections to Db2 databases.)