[Enterprise Extensions only]

Filtering the information in a formatted trace file

If you turn on component trace, WebSphere Application Server enterprise services stores trace data in one or more trace logs, which must be formatted before you can read their contents.

After you have formatted a trace log, as described in related tasks, you can use the protrace utility to filter the formatted trace information. You can use the protrace utility to filter the formatted trace information, to perform one or more of the following actions:

To use the protrace utility to filter a formatted trace log file, complete the following steps

  1. Open a command-line window on the host where the formatted trace log is stored.
  2. On the command line, type the following command
    protrace inputfile [outputfile] [-t thread] [-i maxindent] [-r] [-m]
    [-s(b,e,d,n,p,t,r,i)] [-inc stringlist] [-exc stringlist] [-v]

    Where:

    inputfile
    is the file output from the showlog or combtrace command.
    outputfile
    (if specified) the output is sent to this file rather than sent to standard output.
    -t thread
    displays entries for the specified thread.
    -i maxindent
    specifies the maximum indent level. Set it to 0 (zero) to disable indenting.
    -r
    includes any raw data in the output.
    -m
    displays the primary message.
    -s(b,e,d,n,p,t,r,i)
    suppresses output specified by one or more of the following characters appended to the -s:
    b
    disables braces. ({})
    e
    disables extended message.
    d
    disables date/time.
    n
    disables entry numbering.
    p
    disables process Id.
    t
    disables thread Id.
    r
    disables the thread indent report generated after each run.
    i
    disables the raw data indicator.

    For example, the option -sedp means that extended message, date/time, and processId information is suppressed.

    -inc stringlist
    specifies a set of inclusion strings. The primary or extended message must contain at least one of these strings to be output. Separate each entry in the list with white space.
    -exc stringlist
    specifies a set of exclusion strings. The primary or extended message must not contain any of these strings to be output. Separate each entry in the list with white space.
    -v

    Notes:

    1. By default, open and close braces ({...}) are added to entry and exit trace points. This allows bracket matching in editors such as vi.
    2. The list separator in the inclusion and exclusion options is a space character. Inclusion or exclusion strings that contain a space character must be delimited with quote (") symbols. For example: -exc "was entered".
    3. The R field in the output is the raw data indicator field. This field is only displayed when the raw data display is disabled and is used to highlight entries that have raw data associated with them. Such entries have a dash (-) in this field. To remove the indicator, and append the raw data to the output, specify the -r flag on the command line.
    4. The protrace utility warns you if any invalid entries are found in the input file. A trace entry is invalid if the function name is missing or the date/time field is missing or incorrectly formatted.

The output in the outfilename file can be displayed in a text editor (or some other utility).