Trace channels

The trace facility can accommodate up to eight simultaneous channels of trace-hook activity, which are numbered 0-7.

Channel 0 is always used for system events, but application events can also use it. The other seven channels, called generic channels, can be used for tracing application-program activity.

When trace is started, channel 0 is used by default. A trace -n channel_number command starts trace to a generic channel. Use of the generic channels has some limitations:

  • The interface to the generic channels costs more CPU time than the interface to channel 0 because of the need to distinguish between channels and because generic channels record variable-length records.
  • Events recorded on channel 0 and on the generic channels can be correlated only by time stamp, not by sequence, so there may be situations in which it is not possible to determine which event occurred first.