Thursday, July 25, 2013

ORACLE 11gR2 - DOP and CLIBRATE_IO

In 11.2.0.2 Automatic Degree of Parallelism can only be used if  I/O statistics are gathered. When PARALLEL_DEGREE_POLICY is set to AUTO, Oracle Database determines whether a statement should run in parallel based on the cost of the operations in the execution plan and the hardware characteristics.

Check the explain plan:
If I/O calibration has not been run to gather the required statistics, the explain plan includes the following text in its notes section:  "- automatic DOP : skipped because of IO calibrate statistics are missing"

Excute dbms_resource_manager.calibrate_io:
SET SERVEROUTPUT ON
DECLARE
lat INTEGER;
iops INTEGER;
mbps INTEGER;
BEGIN
--DBMS_RESOURCE_MANAGER.CALIBRATE_IO(<NUM_DISKS>, <MAX_LATENCY>,iops, mbps, lat);
DBMS_RESOURCE_MANAGER.CALIBRATE_IO (1, 10, iops, mbps, lat);
DBMS_OUTPUT.PUT_LINE ('max_iops = ' || iops);
DBMS_OUTPUT.PUT_LINE ('latency = ' || lat);
dbms_output.put_line('max_mbps = ' || mbps);
end;
/
Note: NUM DISKS - JDATA disk group is made of 1 LUN (1 physical disk)
          LATENCY - Response time (depened upon SLA) 10 sec

STATUS        CALIBRATION_TIME
-----------------------------------------
READY         23-JAN-11 09.30.17.343   [Note: Default status will be NOT AVAILABLE]

Check the explain plan:
The execution plan now shows that the feature automatic degree of parallelism can be used:
"- automatic DOP: Computed Degree of Parallelism is 2"

   0

Ref. DOC ID - 1269321.1

No comments:

Post a Comment