IBM 5655-DB2 Server User Manual


 
Case Study 143
The explanation can be found in the driver program used to run the query. This
program does a CONNECT RESET automatically after each query.
Figure 59. DB2 PM Accounting, SQL DCL Section
Figure 60. DB2 PM Accounting, Parallel Query Section
12.1.1.3 Time Not Accounted
H
in Figure 57 on page 142 shows 19 minutes 50 seconds of time not accounted
for. This is the time the main TCB had to wait for all the parallel threads to finish.
Without query parallelism, the time not accounted for is defined as the difference
between class 2 and class 3 times (class 2 - class 3). This formula works when
there is only one TCB.
With query parallelism, this formula no longer works. Class 2 time is associated
with the main TCB only, since it represents the DB2 time of a query. However,
class 3 time is associated with each parallel task (SRB) plus the main TCB, and
the sum of all the class 3 times can be much longer than the class 2 time. As a
result, DB2 PM decides to report on the main TCB only. Again, the time not
accounted for is still class 2 - class 3, but associated with the main TCB only.
Since the main TCB can wait for a long time for all the parallel tasks to complete,
as is the case where a query scans a large tablespace, the time not accounted for
can be quite long.
SQL DCL TOTAL
---------- --------
LOCK TABLE 0
GRANT 0
REVOKE 0
SET SQLID 0
SET H.VAR. 0
SET DEGREE 1 L
SET RULES 0
CONNECT 1 0
CONNECT 2 1 M
SET CONNEC 0
RELEASE 0
CALL 0
ASSOC LOC. 0
ALLOC CUR. 0
DCL-ALL 2
QUERY PARALLEL. TOTAL
--------------- --------
MAXIMUM MEMBERS N/P
MAXIMUM DEGREE 5 N
GROUPS EXECUTED 1 O
RAN AS PLANNED 1 P
RAN REDUCED 0
ONE DB2 COOR=N 0
ONE DB2 ISOLAT 0
SEQ - CURSOR 0
SEQ - NO ESA 0
SEQ - NO BUF 0
SEQ - ENCL.SER 0
MEMB SKIPPED(%) 0
DISABLED BY RLF NO