Format of PPC Gateway server messages and trace

The PPC Gateway server produces messages and trace that are in the same format. See Figure 1 for an example of the PPC Gateway server message, showing the information that it contains.
Figure 1. Example PPC Gateway server message
Example PPC Gateway server message

Table 1 shows the different message types the PPC Gateway server uses. Refer to PPC Gateway server message descriptions for descriptions of individual messages.

Table 1. Message types
Designator Description
A These messages are named audit messages. They record significant events that occur while the PPC Gateway server is running. The text that appears in the message is free format. Here is an example (this message is produced when the PPC Gateway server has completed initialization):
31    22644 96/01/01-19:43:43.744425 74182e16  A  Ready...
W These messages are named attention messages. They record unexpected events that occur while the PPC Gateway server is running. Here is an example of an attention message:
31    22644 96/01/01-19:43:43.744425 a0040437  W  System crash 
         imminent, machine low on swap space. (0x74183027) : ppc_gwy

The first line of text describes the error condition. The second line, that describes where in the PPC Gateway server code the message was produced, is in two parts. The first part contains the value, in parentheses, of the NLS message number (0x74183027 in the example). The second part, which is separated by a colon (:), is the name of the component within the PPC Gateway server that produced the attention (ppc_gwy in our example). The component name is useful if you have to investigate a problem, because it is possible to switch on the PPC Gateway server trace so that it is produced only by a particular component. The attention message might indicate which component is failing and, therefore, which component to trace.

F
These messages are named fatal messages and are issued just before the PPC Gateway server exits. They indicate that an event has occurred which the PPC Gateway server can not process. Here is an example of an unrecoverable error message that was produced by the PPC Gateway server. Notice that it follows a similar format to the format of the attention message above:
 31    22644 96/01/01-19:43:43.744425 50400415 F  unable to 
          create signal handler thread
When these messages occur, the PPC Gateway server writes as much debugging information as it has to a file named EncinaBacktrace.pid, where pid is the operating system process identifier for the failed PPC Gateway server process. This file is written to the directory in which you started the PPC Gateway server. You can format it by using the interpretTrace utility as follows:
interpretTrace < EncinaBacktrace.pid > outputfile

The remaining types of PPC output are trace entries. This trace is designed for use by the PPC developers. Therefore, a precise definition of the contents of the PPC Gateway server trace is not published. Because it is often possible to follow the trace output, a general overview is given below:

Table 2. Trace types
Designator Description
> This is a function entry trace point. It is produced on entry to a function if trace is switched on. Here is an example that contains the function name, followed by the source file and component to which the function belongs:
31  22644 96/01/01-19:43:43.744425 30349826  > ppc_snaOS_Open 
       ppc_snaOS.c ppc_sna
< This is a function exit trace point. It is produced on exit from a function if trace is switched on. Two types of exit trace are possible. Which trace is used depends on whether the function returns data. An example of each is shown below:
31  22644 96/01/01-19:43:43.744425 00000006 <  ppc_snaOS_Init 
       ppc_snaOS.c ppc_sna
31  22644 96/01/01-19:43:43.744425 28040c00 <R ppc_snaOS_Open 
       ppc_snaOS.c ppc_sna -> 7601a003
The first example shows the exit from ppc_snaOS_Init, which is a function that returns no data (a void function). The second example shows the exit from ppc_snaOS_Open which returns a return code. Most (but not all, so beware when reading the trace) of these PPC functions return a ppc_status_t return code, which are defined in:
install_directory/include/ppc/ppc_status.h
A value of 00000000 means that the function was successful; a hexadecimal value that begins with 7601a indicates an unsuccessful response. The translateError command can be used to find out what the unsuccessful response was. This is how you would find out what the 7601a003 response meant:
$ translateError 0x7601a003
ENC-ppc-003: Allocate failure, retry
The output of translateError is in the same format as that which CICS® uses to display return codes from the PPC Gateway server in the CICS messages. Note that translateError is NLS enabled. If you see the following output:
$ translateError 0x7601a003
ENC-ppc-003

Check that your LANG environment variable is set up correctly.

P This is a trace entry that shows the parameters that are passed to a function. The contents of this type of trace entry varies widely, depending on the function, and might span several lines. Here are some examples:
31  22644 96/01/01-19:43:43.744425 28040c23  P  address: 
		0x202359a8
31  22644 96/01/01-19:43:43.744425 28040c01  P  *dataLengthP: 
		16, *requesttosendP: 0
      *whatDataReceivedP: PPC_RECEIVED_DATA_COMPLETE,
      *whatControlReceivedP: PPC_RECEIVED_CONTROL_SEND
E This final type of trace is an event trace. It can be used to show the data that the PPC Gateway server is processing, or error conditions. Here are some examples:
31  22644 96/01/01-19:43:43.744425 04800017  E  ppc Config: 
		Adding SNA tpn[3] : CEMT
31  22644 96/01/01-19:43:43.744425 10043819  E  result mask: 
		00000000