OpenTP1 Version 7 Operation

[Contents][Index][Back][Next]

3.16.4 Outputting real-time statistics

This subsection describes how to output real-time statistics acquired in the shared memory for the real-time statistics service.

Organization of this subsection
(1) Outputting real-time statistics to the standard output
(2) Outputting real-time statistics to an RTS log file
(3) Editing and outputting real-time statistics in an RTS log file

(1) Outputting real-time statistics to the standard output

When you execute the rtsls command, the real-time statistics acquired in the shared memory for the real-time statistics service are output to the standard output. You can output management information and statistics of the real-time statistics service to the standard output. By outputting this information to the standard output, you can recognize the operating status of the OpenTP1 system in real time.

(2) Outputting real-time statistics to an RTS log file

You can output the real-time statistics acquired in the shared memory for the real-time statistics service to an RTS log file that is created by the real-time statistics service. To output real-time statistics to an RTS log file, specify Y for the rts_log_file operand in the real-time statistics service definition and start the real-time statistics service.

(a) Creating an RTS log file

The real-time statistics service creates an RTS log file when it starts.

Specify the number of RTS log files to be created in the rts_log_file_count operand in the real-time statistics service definition.

Specify the location and name of the RTS log file in the rts_log_file_name operand in the real-time statistics service definition. Generation numbers are added to the names of the RTS log files that are created. When you specify the operands as follows, the real-time statistics service creates RTS log files named rtslog1, rtslog2, and rtslog3 in a directory directly under /OpenTP1/spool/dcrtsinf.

set rts_log_file_count=3
set rts_log_file_name=/OpenTP1/spool/dcrtsinf/rtslog

When Y is specified for the rts_log_file_backup operand in the real-time statistics service definition, or no value is specified for the operand, a backup of the RTS log files is created when the real-time statistics service starts. If you specify the operands in the manner above, which creates RTS log files named rtslog1, rtslog2, and rtslog3 in a directory directly under /OpenTP1/spool/dcrtsinf, the real-time statistics service creates backup files named rtslog1.bk, rtslog2.bk, and rtslog3.bk, and then re-creates the three RTS log files. The real-time statistics service does not create these backup files if N is specified for the rts_log_file_backup operand.

Do not create a file or directory with the same name as an RTS log file or backup file at the output destination for RTS log files. If a file with such a name exists, it will be overwritten by the RTS log file or backup file. If you create a directory with the same name as that used for log file output by the real-time statistics service, the real-time statistics service will be unable to create RTS log files or backup files.

(b) Outputting real-time statistics to an RTS log file

The real-time statistics service outputs the real-time statistics acquired in the shared memory for the real-time statistics service to RTS log files at the interval specified in the rts_trcput_interval operand in the real-time statistics service definition.

Specify the size of an RTS log file in the rts_log_file_size operand in the real-time statistics service definition. If the size of the real-time statistics to be output to an RTS log file exceeds the value specified in the rts_log_file_size operand, the output destination will switch to the next RTS log file. When no RTS log files remain, output of real-time statistics reverts to the first RTS log file.

The following figure shows how RTS log files are switched.

Figure 3-45 Switching RTS log files

[Figure]

(c) Errors in an RTS log file

If an I/O error occurs in an RTS file while the real-time statistics service is online, the real-time statistics service switches to the next RTS log file and continues output processing.

If I/O errors occur in all the RTS log files, the real-time statistics service outputs a KFCA32708-W message and stops the output of real-time statistics to the RTS log files. However, the real-time statistics service continues acquiring real-time statistics in the shared memory for the RTS service.

(3) Editing and outputting real-time statistics in an RTS log file

By executing the rtsedit command, you can change the format of the statistics output in an RTS log file to CSV format for output to another location.