In this section: |
FOCUS can record all user activity on the FOCUS Database Server in a sequential file. Each HLI command is a single action. Each MODIFY/Maintain transaction or TABLE request may execute a series of actions, such as database opens and closes, reads, key matches, and value changes. When you use the ECHO option, the sequential file (allocated to ddname HLIPRINT) records:
You can generate an extended form of the HLIPRINT file by using the STAT option. In addition to the information displayed by the ECHO option, the extended form lists the following:
The HLIPRINT file has three uses:
The following is a sample of the HLIPRINT file generated with the ECHO option. A description of the columns follows.
CMD FILENAME STATUS NEWSEG TARGET ANCHOR NTEST USERID REF NUMB OPN FOCUSSU 0 WIBDIW 00000001 RD CAR 0 1 WIBDIW 00000002 OPN CAR 0 WIBEFO 00000003 MINT CAR 0 WIBEFO 00000004 MATA CAR 0 ORIGIN WIBEFO 00000005 MATB CAR 0 COMP WIBEFO 00000006 MDEL CAR 0 COMP WIBEFO 00000007 MATB CAR 0 ORIGIN WIBNNR 00000008 MATB CAR 1 COMP WIBNNR 00000009 MINC CAR 0 COMP WIBNNR 00000010 MATB CAR 0 ORIGIN WIBMHK 00000011 MATB CAR 0 COMP WIRMHK 00000012 MDEL CAR 0 COMP WIBMHK 00000013 MATB CAR 0 ORIGIN WIBEFO 00000014 MATB CAR 1 COMP WIBEFO 00000015 MINC CAR 0 COMP WIBEFO 00000016 MATB CAR 0 ORIGIN WIBNNR 00000017 MATA CAR 0 COMP WIBNNR 00000018 MINC CAR 1 COMP WIBNNR 00000019 CLO CAR 0 WIBNNR 00000020 CLO FOCUSSU 0 WIBNNR 00000021
The columns in the chart are:
The type of action:
Open a file.
Read a page from a FOCUS database.
MODIFY/Maintain/SU initialization.
Match a field value or values in the database (MODIFY/MAINTAIN MATCH subcommand).
Update a segment instance (MODIFY/Maintain UPDATE subcommand).
Delete a segment instance and its descendents (MODIFY/Maintain DELETE subcommand).
Move to the next segment instance in the segment chain (MODIFY/Maintain TEXT subcommand).
Move to the first segment instance in the segment chain (MODIFY/Maintain REPOSITION subcommand).
COMMIT subcommand.
ROLLBACK subcommand.
Write transactions from buffer to the database
Close a file.
Any other action in this column is an HLI command issued when using HLI with SU.
The ddname of the centrally controlled database on which the action took place. Note that the FILENAME column in the sample HLIPRINT file lists a file allocated to ddname FOCUSSU. This is a FOCUS work file.
Contains either the value of the FOCURRENT variable or the HLI status code for the action. If the action ended normally, this value is set to 0. If a MATCH command failed to locate a segment instance (ON NOMATCH condition), or if a NEXT command reached the end of a segment chain (ON NONEXT condition) this value is set to 1. Otherwise, it is the FOCURRENT field or the HLI status code for the action. For a list of the HLI status codes, see HLI Status Codes Returned in FCB Word 24.
The name of the first segment of new information (for HLI only).
The segment read or modified by the action.
The anchor segment (for HLI only).
The number of test conditions qualifying a retrieved record. For FOCUS users, the number of the database page that was read by an RD action. A page for a FOCUS database is a 4096-byte physical record. A page for an XFOCUS database is a 16K-byte physical record.
The TSO user ID or job ID that issued the action.
The action number in the HLIPRINT file. REF NUMB is useful with the FOCUS ? FILE command. This query displays a chart showing when each segment in a FOCUS database was last changed (this command is described in the Developing Applications manual). The last column in that chart, LAST TRANS NUMBER, lists a number for each segment in the file. If the file was last modified under SU, these numbers refer to the REF NUMB column in the HLIPRINT file, pointing to the last action performed on the segment (usually a CLO or SAV action).
The following figure shows a sample extended HLIPRINT file. The columns are the same as those in the HLIPRINT file described in HLIPRINT File Contents (Simple Format), with the additions described following the sample. If you display the file on a system editor, note that the first column is reserved for print control characters.
A Master File is supplied for the extended HLIPRINT file (member HLIPRINT in MASTER.DATA on the distribution tape). This enables you to write FOCUS reports against the file. For details on producing these reports, see Producing HLIPRINT Reports.
Date the action was executed, in YYMMDD (year, month, day) format.
Time the action finished execution, in HHMMSS (hours, minutes, seconds) format.
Total elapsed CPU time for executing the action (as indicated in the ASCBEJST field of the ASCB for the FOCUS Database Server). If the action took longer than 99.99 seconds to execute, VTIME displays a value of 99.99. Note that the value of VTIME is .0000 for the first action after the server was started.
Same as the VTIME column.
Number of database input/output (I/O) operations performed to complete the action. This number reflects only I/O operations on FOCUS or XFOCUS databases and does not include I/O operations on other files such as Master Files. If the action required more than 9999 I/O operations, IOS displays a value of 9999.
For FOCUS users, the name of the FOCUS procedure (FOCEXEC) executing the action. For users issuing FOCUS commands live on the terminal, PROCNAME is blank.
For HLI users, the contents of FCB words 7 and 8. SU does not use words 7 and 8, so HLI users can define their own contents for these words and have them displayed in the PROCNAME column.
For MODIFY/Maintain requests only.
If the request defines a temporary field called SUPRINTNAME (pronounced SU print name), it is the value of this field. SUPRINTNAME must be an alphanumeric field no longer than 12 characters. For example, if your MODIFY/Maintain request contains the following command, the CASE NAME column will display the value MARK until the next COMPUTE command places another value in the SUPRINTNAME field:
COMPUTE SUPRINTNAME/A12 = 'MARK';
If the request does not define SUPRINTNAME but uses Case Logic, this contains the name of the case that executed the action. Otherwise, CASE NAME is blank.
To record activity in the HLIPRINT file, follow these instructions when starting the FOCUS Database Server:
Give HLIPRINT the following disposition:
The following is a sample DD card for allocating a new file using the simple format:
//HLIPRINT DD DSN=SULOG.DATA, // DCB=(LRECL=88,BLKSIZE=8800,RECFM=FB), // DISP=(NEW,CATLG),UNIT=SYSDA
This DD card allocates a new file for the extended HLIPRINT format:
//HLIPRINT DD DSN=SULOG.DATA, // DCB=(LRECL=133,BLKSIZE=13300,RECFM=FB), // DISP=(NEW,CATLG),UNIT=SYSDA
This DD card allocates an existing file with the new output appended to the present file contents:
//HLIPRINT DD DSN=SULOG.DATA,DISP=MOD,DCB=...
The HLIPRINT file can be allocated to tape, disk, or a SYSOUT queue.
//HLISNK EXEC PGM=HLISNK, PARM={'password ECHO'|'password STAT'}
where:
Records activity in a simple HLIPRINT file.
Records activity in an extended HLIPRINT file.
The password is optional. If you choose to omit it, remember to type a leading blank before the ECHO or STAT keyword. Otherwise, FOCUS will not interpret it correctly.
The extended HLIPRINT log facility has an associated Master File called HLIPRINT. This enables you to produce summary reports of your HLIPRINT log information using FOCUS TABLE commands. These summary reports can be used to:
Before you can issue TABLE commands against HLIPRINT, you must allocate ddname HLIPRINT to the log file. If you named your HLIPRINT data set MYTRACE.HLIPRINT.DATA, you would issue the following command from within FOCUS:
TSO ALLOCATE F(HLIPRINT) DA('MYTRACE.HLIPRINT.DATA') SHR
You must also allocate ddname MASTER to the Master File PDS supplied with FOCUS.
After allocating HLIPRINT and MASTER, you can issue TABLE requests against the HLIPRINT file.
The following sample request determines how much of the server resources were used by each user ID:
TABLE FILE HLIPRINT SUM CPU AND IOS BY USERID END
This request produces a report showing the total elapsed job step time and the number of I/O operations used by the sink machine on behalf of each user ID.
The next sample request can be used to locate performance problems in an application:
TABLE FILE HLIPRINT SUM CPU AND IOS BY PROC_NAME BY CASE_NAME ON PROC_NAME SUMMARIZE END
The output is:
PROC_NAME CASE_NAME CPU IOS --------- --------- ----- --- CARLOAD .3204 6 *TOTAL CARLOAD .3204 6 CARMOD ADDCASE 1.1040 17 DELCASE .5919 10 LOCATE 19.8299 428 SHOWCASE 1.2534 5 TOP .5745 6 UPDATECASE 1.1790 21 *TOTAL CARLOAD 24.5327 487 TOTAL 24.8531 493
This report shows that case LOCATE in the procedure CARMOD consumes most of the CPU time and I/O resources. This particular part of the application could probably be redesigned to run more efficiently.
For more information about report requests, see your FOCUS documentation.
Information Builders |