SMF writer header section

In SMF, writer headers for statistics records are mapped by macro DSNDQWST, for accounting records by DSNDQWAS, and for performance, audit, and monitor records by DSNDQWSP.

Begin program-specific programming interface information. When these macros are assembled, they include the other macros necessary to map the remainder of the trace records sent to SMF.

The SMF writer header section begins at the first byte of the record. After establishing addressability, you can examine the header fields. The fields are described in Table 1.
Table 1. Contents of SMF writer header section
Hex Offset DSNDQWST DSNDQWAS DSNDQWSP Description
0 SM100LEN SM101LEN SM102LEN Total length of SMF record
2 SM100SGD SM101SGD SM102SGD Segment descriptor
4 SM100FLG SM101FLG SM102FLG System indicator
5 SM100RTY SM101RTY SM102RTY SMF record type:
  • Statistics=100(dec)
  • Accounting=101(dec)
  • Monitor=102(dec)
  • Audit=102(dec)
  • Performance=102(dec)
6 SM100TME SM101TME SM102TME SMF record timestamp, time portion
A SM100DTE SM101DTE SM102DTE SMF record timestamp, date portion
E SM100SID SM101SID SM102SID System ID
12 SM100SSI SM101SSI SM102SSI Subsystem ID
16 SM100STF SM101STF SM102STF Reserved
17 SM100RI SM101RI SM102RI Reserved
18 SM100SEQ SM101SQ SM102SEQ Compression information, which consists of the next two fields.
18 SM100CMP SM101CMP SM101CMP High-order bit value:
1
The record is compressed.
0
The record is uncompressed.
18 SM100BUF SM101BUF SM102BUF The rest of the field. If the high-order bit is 1, this value is the length of the data record when the record is uncompressed. If the high-order bit is 0, this value is 0.
1C SM100END SM101END SM102END End of SMF header
Figure 1 is a sample of the first record of the Db2 performance trace output sent to SMF.
Figure 1. Db2 trace output sent to SMF (printed with DFSERA10 print program of IMS)
           A         B   C       D        E          F                    G   H 
 000000   01240000 0E660030  9EEC0093 018FF3F0   F9F0E2E2 D6D70000  00000000 0000008C
          I    J    K        L   M    N 
 000020   00980001 0000002C  005D0001 00550053   4DE2E3C1 D9E340E3  D9C1C3C5 404DE2E3
 000040   C1E3405D C3D3C1E2  E2404D5C 405DD9D4   C9C4404D 5C405DD7  D3C1D540 4D5C405D
 000060   C1E4E3C8 C9C4404D  5C405DC9 C6C3C9C4   404D5C40 5DC2E4C6  E2C9E9C5 404D5C40
                                      O          P   Q  R 
 000080   5D000000 01000101  01000000 004C0110   000402xx 00B3AB78  E2E2D6D7 A6E9BACB
                                                 S 
 0000A0   F6485E02 00000003  00000021 00000001   E2C1D5E3 C16DE3C5  D9C5E2C1 6DD3C1C2
 0000C0   C4C2F2D5 C5E34040  D3E4D5C4 F0404040   A6E9BACB F4570001  004C0200 E2E8E2D6
 0000E0   D7D94040 F0F2F34B  C7C3E2C3 D5F6F0F2   E2E2D6D7 40404040  40404040 40404040
 000100   E2E8E2D6 D7D94040  00000000 00000000   00000000 00000000  00000000 00000000
 000120   00000000T
Key to Figure 1 Description
 A 0124 Record length (field SM102LEN); beginning of SMF writer header section
 B 66 Record type (field SM102RTY)
 C 0030 9EEC Time (field SM102TME)
 D 0093 018F Date (field SM102DTE)
 E F3F0 F9F0 System ID (field SM102SID)
 F E2E2 D6D7 Subsystem ID (field SM102SSI)
 G  End of SMF writer header section
 H 0000008C Offset to product section; beginning of self-defining section
 I 0098 Length of product section
 J 0001 Number of times the product section is repeated
 K 0000002C Offset to first (in this case, only) data section
 L 005D Length of data section
 M 0001 Number of times the data section is repeated
 N 00550053 Beginning of data section
 O  Beginning of product section
 P 0004 IFCID (field QWHSIID)
 Q 02 Number of self-defining sections in the record (field QWHSNSDA)
 R xx Release indicator number (field QWHSRN); this varies according to the actual level of Db2 you are using.
 S E2C1D5E3... Local location name (16 bytes)
 T  End of first record
End program-specific programming interface information.