CL Command Reference - TRCCNN

CL Command List > TRCCNN Reference

Description:

The Trace Connection (TRCCNN) command allows the tracing of encrypted data flowing over internet protocol (IP) and Secure Sockets Layer (SSL) connections. Specific types of traces are started and stopped by using this command.

TRCCNN uses the Trace Internal (TRCINT) command to collect the trace records and generate an intermediate spooled file named QPCSMPRT. The QPCSMPRT spooled file data is used to generate a spooled file named QSYSPRT. The user data for the QSYSPRT file is ¡¯TRCCNN¡¯.

You can use also use TRCCNN with a QPCSMPRT spooled file generated by using TRCINT directly. TRCCNN can extract and format the IP and SSL connection-related trace records. This allows you to use TRCINT to collect many types of trace records and then use TRCCNN to format the subset of trace records related to IP or SSL connections.

Restrictions:

. To use this command, you must have service (*SERVICE) special authority, or be authorized to the Service Trace function of Operating System through iSeries Navigator¡¯s Application Administration support. The Change Function Usage (CHGFCNUSG) command, with a function ID of QIBM_SERVICE_TRACE, can also be used to change the list of users that are allowed to perform trace operations.

. The following user profiles have private authorities to use the command:
¨C QSRV

. When the Watched job (WCHJOB) parameter is specified, the issuer of the command must be running under a user profile which is the same as the job user identity of the job being watched, or the issuer of the command must be running under a user profile which has job control (*JOBCTL) special authority. Job control (*JOBCTL) special authority is also required if a generic user name is specified for the WCHJOB parameter.

. If you specify a generic user name in the WCHJOB parameter, you must have all object (*ALLOBJ) special authority, or be authorized to the Watch Any Job function of Operating System through iSeries Navigator¡¯s Application Administration support. The Change Function Usage (CHGFCNUSG) command, with a function ID of QIBM_WATCH_ANY_JOB, can also be used to change the list of users that are allowed to start and end watch operations.

. You must have operational (*OBJOPR) and execute (*EXECUTE) authorities to the user exit program if specified in Trace program (TRCPGM) parameter, and execute (*EXECUTE) authority to the library where the program is located.

. You must have use (*USE) authority to the message queues specified in Watched message queue (WCHMSGQ) parameter, and use (*USE) authority to the library where the message queue is located.


Examples:

Example 1: Starting SSL Traces

TRCCNN SET(*ON) TRCTYPE(*SSL)

This command starts tracing for Secure Sockets Layer (SSL) connections.



Example 2: Starting IP Traces

TRCCNN SET(*ON) TRCTYPE(*IP)

This command starts tracing for connections at the internet protocol (IP) level.



Example 3: Stopping Traces and Clearing Trace Storage

TRCCNN SET(*END)

This command stops all traces and deletes the trace table. No spooled output is generated.



Example 4: Printing Traces

TRCCNN SET(*OFF)

This command stops all traces and generates a spooled file (QPCSMTRC) that contains the trace records collected by the TRCINT (Trace Internal) command, and a spooled file (QSYSPRT) that contains the formatted trace data.



Example 5: Formatting Trace Data from TRCINT Command

TRCINT SET(*ON) TRCTYPE(*SCK)
TRCINT SET(*OFF)
TRCCNN SET(*FORMAT) TRCTYPE(*SSL) JOB(*) SPLNBR(*LAST)

The TRCINT (Trace Internal) commands are used to start collecting trace records related to all usage of sockets, and to stop collecting trace records and create a spooled file named QPCSMPRT. The TRCCNN command will use the trace information in the last spooled file named QPCSMPRT for the current job, and format the trace records related to SSL (Secure Sockets Layer) in a spooled file named QSYSPRT.



Example 6: Specifying a Trace Table

TRCCNN SET(*ON) TRCTYPE(*IP) TRCTBL(USER)

This command starts tracing for connections at the internet protocol (IP) level and stores the trace data in the USER trace table.



Example 7: Specifying a Trace Table Size in Megabytes

TRCCNN SET(*ON) TRCTYPE(*IP) SIZE(20000 *MB)

This command starts tracing for connections at the internet protocol (IP) level and stores the data in a 20000-megabyte trace table.



Example 8: Specifying a CCSID for Trace Data

TRCCNN SET(*OFF) CCSID(*ASCII)

This command stops all traces and generates a spooled file (QSYSPRT). ASCII (819) CCSID will be used when formatting the trace data.



Example 9: Start a Trace and Watch for a Message to End the Trace

TRCCNN SET(*ON) TRCTYPE(*IP) WCHMSG((MCH2804))
WCHMSGQ((*SYSOPR) (*JOBLOG)) WCHJOB((*ALL/MYUSER/MYJOBNAME))
TRCPGM(MYLIB/TRCEXTPGM)

This command starts tracing for connections at the internet protocol (IP) level. The trace will be ended when MCH2804 message is found on the System Operator message queue or within the *ALL/MYUSER/MYJOBNAME job log. Also, MYLIB/TRCEXTPGM is specified as a trace exit program.



Example 10: Start a Trace and Watch for a LIC Log Entry to End the Trace

TRCCNN SET(*ON) TRCTYPE(*IP) WCHLICLOG((¡¯99??¡¯ 9932 MYJOBNAME))
WCHTIMO(*NOMAX)

This command starts tracing for connections at the internet protocol (IP) level. The trace will be ended when a Licensed Internal Code (LIC) log entry that has a major code starting with 99 and a minor code of 9932 is generated on the system. Also, the LIC log information should contain the text ¡åMYJOBNAME¡å. *NOMAX on WCHTIMO parameter indicates that the trace will be active until the event occurs or TRCCNN command is issued manually to end the trace.