This is an excerpt from the bestselling book
Oracle Grid & Real Application Clusters. To get immediate
access to the code depot of working RAC scripts, buy it
directly from the publisher and save more than 30%.
For loading, multiple load
sessions executing concurrently on a multiple-CPU system are used.
The input data files are split into separate files on logical record
boundaries and are then loaded each such input data file with a
conventional path load session.This is faster than a single
conventional load on a multiple-CPU system, but it is probably not
as fast as a direct load. Also, triggers are executed, integrity
constraints are applied to the loaded rows, and indexes are
maintained using the standard DML execution logic.Parallel Direct Path Load
SQL*Loader permits multiple, concurrent sessions to perform a
direct path load into the same table or into the same partition of
a partitioned table. Multiple SQL*Loader sessions improve the
performance of a direct path load, given the available resources
on the system.
Parallel data loading is enabled by setting both the direct and
the parallel parameters to TRUE. However, there are some
restrictions to parallel direct load. They are:
* Referential integrity and CHECK constraints must be
disabled.* Triggers must be disabled.
* Rows can only be appended. REPLACE, TRUNCATE and INSERT
cannot be used.
* Indexes are not maintained during a parallel direct path
load. Any table indexes must be created manually or dropped and
recreated manually after the load completes.
The following commands invoke three direct path SQL*Loader load
sessions on the same table. These are in separate server
sessions:
Session 1:
>sqlldr
USERID=nyora/frodo CONTROL=pload1.ctl DIRECT=TRUE PARALLEL=true
Session 2:>sqlldr
USERID=nyora/frodo CONTROL=pload2.ctl DIRECT=TRUE PARALLEL=true
Session 3:>sqlldr
USERID=nyora/frodo CONTROL=pload3.ctl DIRECT=TRUE PARALLEL=true
|
|
|
Get the Complete
Oracle Utility Information
The landmark book
"Advanced Oracle
Utilities The Definitive Reference" contains over 600 pages of
filled with valuable information on Oracle's secret utilities.
This book includes scripts and tools to hypercharge Oracle 11g
performance and you can
buy it
for 30% off directly from the publisher.
|
|
Other RAC Parallel Operations
The following are some of the
other miscellaneous parallel execution opportunities.
DBWR and LGWR
Using multiple DBWRs parallels
the writing of buffers. Therefore, multiple DBWR processes should
deliver more throughput than one DBWR process with the same number
of I/O slaves. Since the mirroring of redo log files on separate
disks, does not slow LGWR considerably, LGWR writes to each disk in
parallel and waits until each part of the parallel write is
complete.
Parallel Recovery
Recovery performed in parallel
can speed up the crash, instance, and media recovery considerably.
During a parallel recovery process, the SMON background process
reads the redo-log files sequentially, and the redo-blocks are then
distributed evenly to all recovery processes to be read into the
buffer cache. The parallel slave processes apply the changes to data
files. If the data files involved in the recovery are many, the
parallel process really helps.
To specify the number of
concurrent recovery processes for instance or crash recover use the
recovery_parallelism initialization parameter to specifies the
number of concurrent recovery processes. This parameter has no
affect on media recovery. To parallelize media recovery, use the
parallel clause in the RECOVER DATABASE statement.
The SQL*Plus
recovery_parallelism command specifies parallel media recovery.
The default is NOPARALLEL.
Example:
SQL>RECOVER
PARALLEL integer;
SQL>RECOVER TABLESPACE myTBS, yourTBS PARALLEL (degree 4);
SQL>RECOVER DATAFILE ?/u01/orodata/NYORA/sales1.dbf? PARALLEL
(DEGREE 3);
SQL>RECOVER DATABASE PARALLEL ; -- default DOP is used.
For media recovery, Oracle uses a division of
labor approach to allocate different processes to different data
blocks while rolling forward, thereby making the procedure more
efficient. For example, if parallel recovery is performed with
parallel four, and only one data file is recovered, four spawned
processes read blocks from the data file and apply records instead
of only one process.

|
|