[ Previous | Next | Contents | Glossary | Home | Search ]
AIX Version 4.3 Problem Solving Guide and Reference

Control the Trace Facility

When the trace is configured, the trace facility controls trigger the collection of data on or off and stop the trace facility (stop deconfigures the trace command and unpins buffers). Trace facility controls include:

Trace Facility Commands and Subcommands

trace
                          Starts the tracing of system events. The trace log file and the internal trace buffers that collect trace event data can be managed, including their size, by this command.
trcdead
                          Extracts trace information from a system dump. If the system halts while the trace facilities are active, the contents of the internal trace buffers are captured. This command extracts the trace event data from the dump and writes it to the trace log file.
trcrpt
                          The trcrpt command formats reports of trace event data contained in the trace log file. You can specify the events to be included (or omitted) in the report, as well as determine the presentation of the output with this command. The trcrpt command uses the trace formatting templates stored in the /etc/trcfmt file to determine how to interpret the data recorded for each event.
trcstop
                          Stops the tracing of system events.
trcupdate
                          Updates the trace formatting templates stored in the /etc/trcfmt file. When you add applications or kernel extensions that record trace events, templates for these events must be added to the /etc/trcfmt file. The trcrpt command uses the trace formatting templates to determine how to interpret the data recorded for each event. Software products that record events usually run the trcupdate command as part of the installation process.

Trace Facility Calls and Subroutines

trcgen, trcgent
                          Records trace events consisting of more than five words of data. The trcgen subroutine may be used to record an event as part of the system event trace (trace channel 0) or to record an event on a generic trace channel (channels 1 through 7). You specify the channel number in a subroutine parameter when you record the trace event. The trcgent subroutine appends a time stamp to the event data.
trcgenk,trcgenkt
                          Used by kernel extensions to record trace events consisting of more than five words of data. May be used to record an event as part of the system event trace (trace channel 0) or to record an event on a generic trace channel (channels 1 through 7). You specify the channel number in a subroutine parameter when you record the trace event. The trcgenkt subroutine appends a time stamp to the event data.
trchook, utrchook
                          Records up to five words of data. These subroutines may be used to record an event as part of the system event trace (trace channel 0). The utrchook subroutine uses a special FAST-SVC path to improve performance and should be used by programs at the user (application) level.
trcoff
                          Suspends the collection of trace data on either the system event trace channel (channel 0) or a generic trace channel (1 through 7). The trace channel remains active and trace data collection can be resumed by using the trcon subroutine.
trcon
                          Starts the collection of trace data on a trace channel. The channel may be either the system event trace channel (0) or a generic channel (1 through 7). The trace channel, however, must have been previously activated by using the trace command or the trcstart subroutine. You can suspend trace data collection by using the trcoff subroutine.
trcstart
                          Requests a generic trace channel. This subroutine activates a generic trace channel and returns the channel ID to the calling application to use in recording trace events using the trcgen, trcgent, trcgenk, and trcgenkt subroutines.
trcstop
                          Frees and deactivates a generic trace channel.

Trace Facility Files

/etc/trcfmt
                          Contains the trace formatting templates used by the trcrpt command to determine how to interpret the data recorded for each event.
/usr/include/sys/trcmacros.h Contains commonly used macros for recording trace events.
/var/adm/ras/trcfile Default trace log file. The trace command allows you to specify a different trace log file.

Go back to Trace Facility.


[ Previous | Next | Contents | Glossary | Home | Search ]