SMF Type 5 Record
This table shows the record layout for type 5 SMF records
It's easy to report on SMF 5 data! (Jump to sample reports)
Spectrum SMF Writer handles the difficult SMF record parsing for you automatically. You just specify which fields you want to see.
Spectrum SMF Writer also converts the arcane date and time fields and reformats them into an attractive report.
Record length. This field and the next field (total of four bytes) form the RDW (record descriptor word). See “Standard SMF Record Header” on page 13-1 for a detailed description.
Segment descriptor (see record length field).
System indicator: Bit Meaning When Set 0-2 Reserved 3-6 Version indicators* 7 Reserved.*See “Standard SMF Record Header” on page 13-1 for a detailed description.
Record type 5 (X'05').
Time since midnight, in hundredths of a second, that the record was moved into the SMF buffer.
Date when the record is passed to the SMF writer, in the form 0cyydddF. See “Standard SMF Record Header” on page 13-1 for a detailed description. This is the date that the job terminated.
System identification (from the SID parameter).
Job name. The job name, time, and date that the reader recognized the JOB card (for this job) constitute the job log identification, or transaction name (for APPC output).
Time since midnight, in hundredths of a second, that the reader recognized the JOB card (for this job).
Date when the reader recognized the JOB card (for this job), in the form 0cyydddF. See “Standard SMF Record Header” on page 13-1 for a detailed description.
User-defined identification field (taken from common exit parameter area, not from USER=parameter on job statement).
Number of steps in the job.
Time since midnight, in hundredths of a second, that the initiator selected the job.
Date when the initiator selected the job, in the form 0cyydddF. See “Standard SMF Record Header” on page 13-1 for a detailed description.
Number of card-image records in DD DATA and DD* data sets read by the reader for the job.
Job completion code: X'0ccc' indicates system ABEND in the last job step where ccc is the system ABEND code (see z/OS MVS System Codes). X'8ccc' indicates user ABEND in the last job step where ccc is the user ABEND code. X'nnnn' indicates normal completion where nnnn is the contents of the two low-order bytes in register 15 at termination. X'0000' indicates either: (see note) 1. The last job step was flushed (not processed) because of an error during allocation or in a preceding job step, or 2. normal job completion with a return code of 0.Note: When a step in a multi-step job terminates abnormally, the subsequent steps, whether executed or flushed, do not propagate the step abend code for processing this record. The code appears in the job termination record (type 4). In this case, the field - SMF5JCC, can contain X'nnnn'. If an abend occurred in the job, the job termination indicator (bit 6 in the SMFJBTI field) is set to 1. Use this field in conjunction with the job termination indicator field, SMFJBTI.
Job selection priority. This field normally equals the user-assigned priority of zero to 13, but if the job fails while being scheduled, this field equals 14 (taken from the PRTY parameter on the JOB card). If no value is specified for the PRTY parameter on the JOB card, this field contains: v For JES3, the default priority specified on the JES3 STANDARDS initialization card v For JES2, a zero.Note that JES2 does not use the priority value reported in this field.
Time since midnight, in hundredths of a second, that the reader recognized the end of the job.
Date when the reader recognized the end of the job, in the form 0cyydddF. See “Standard SMF Record Header” on page 13-1 for a detailed description.
Bit Meaning When Set 0 Reserved 1 Canceled by exit IEFUJV 2 Canceled by exit IEFUJI 3 Canceled by exit IEFUSI 4 Canceled by exit IEFACTRT (step exit only) 5 Reserved 6 If 0, normal completion (if 1, then ABEND). 7 Reserved.
Job transaction residency time, in 1024-microsecond units. That is the total amount of time the transaction was in central storage.
Reader device class. (This field is not filled in for jobs submitted by way of an internal reader.)
Reader unit type. (This field is not filled in for jobs submitted via an internal reader.)
Job input class (taken from JOB card; default equals ‘A’).
Storage protect key, in the form xxxx0000 where xxxx is the key.
Job CPU time under SRBs, in hundredths of a second. This field includes the CPU time for various supervisory routines that are dispatched via SRBs: locking routines, page resolution, swap control, cross-memory communications (WAIT, POST, I/0 POST), and TQE scheduling.
Job service, in service units.
Job transaction active time, in 1024-microsecond units.
Length of rest of the fixed portion of the record.
Number of accounting fields.
Accounting fields. Each entry for an accounting field contains the length of the field (one byte, binary) followed by the field (EBCDIC). A zero indicates an omitted field.
Job CPU service, in service units.
Job I/O service in service units.
Job main storage service, in service units.
Job SRB service, in service units.
The table above is based on the description provided by IBM in its "MVS Systems Management Facilities (SMF)" manual.
The SMF report below was created with Spectrum SMF Writer, the low-cost 4GL report writer for SMF files.
In this report we want to show what percentage of the past month each of our CICS regions was up and running (or what percentage it was down.) To do this, we read that full month's SMF records. (We must also ensure that we read enough records from the current month to get the job termination record for the final CICS session that began in the previous month.) From this input, we select just the SMF type 5 (Job Termination) records for jobs beginning with "CICSP".
SMF writes one type 5 record each time a background job terminates. This record includes the job's begin and end date/time, which we can use to compute the session's elapsed time. For the final session of the month, we use the end of the month as the "end time" for our elapsed time computation. And, for the first session of the month we use the beginning of the month as the "begin time" for the computation. We sort the report on CICS region to sort all of the sessions for each region together. We add a BREAK statement on region to get region totals for the month. These totals that automatically print tell us the total up-hours for each region for the last month.
For each session, we also compute its elapsed time as a percentage of the total hours in the month. While not very meaningful for an individual session, in the total line we can see what percentage of the month the CICS region was available -- a very useful number to monitor on a month to month basis.
(By uncommenting the SUMMARY option statement below, you can omit the detailed session lines and see just one total line for each CICS region for the month. A perfect executive level report!)
Note that this report makes extensive use of Spectrum SMF Writer's many powerful date and time computational functions. We use them to: determine the begin and end dates of the previous calendar month; to compute elapsed time from one date/time to another date/time, and convert that to into hours; and to calculate the exact number of hours in the previous month. This report can run each month without requiring any manual changes to the control statements.
All of this useful executive information with just a few lines of code!
Why not install a Spectrum SMF Writer trial right now and start making your own SMF reports!