Oracle Replication
Transportable Tablespaces
Pros The quickest way to transport an entire tablespace to a target system is to simply transfer the tablespace's underlying files. Cons For a tablespace to be transported to a target system, it must be selfcontained. The source database tablespace needs to be made read-only until the copying of tablespace ends. Cross-platform issues - Endian-ness of operating system ASM (will need RMAN to pull out tablespaces into file structures)
Data Pump
Data Pump , introduced in 10g, replaces the older Export-Import tool. Data Pump can be used in below modes Transportable tablespace Just a Datapump approach of TTS discussed in previous slide Table/Schema dump Discussed below External Tables Discussed below Network Link (Dblink) Discussed in next slide Cons Slower than Transportable tablespaces. Tests Using EXPDP & IMPDP (Parallel=4) Uses Table dump mode Rows - 65 million Export - 00:02:30 FTP - Depends on n/w speed 10 GB file Can use shared volume/disk Import - 00:01:44 ODI LKM Oracle to Oracle (Data pump) - Uses External Tables mode 1 million records 00:00:17 5 million records 00:01:45 10 million records 00:04:14 20 million records 00:07:23 40 million records 00:13:53 65 million records 00:26:34
Pulling Tablespaces
New tool in Oracle Database 10g that simplifies the transportable tablespace approach so that it involves only the execution of a single packaged procedure. In this approach, the user "pulls" the tablespaces from the source system, using a supplied package, DBMS_STREAMS_TABLESPACE_ADM. This package uses Data Pump to transport tablespaces and transfers the data files to the target system's format. It also performs any required endian conversion automatically. Cons Limitation in terms of flexibility because its a packaged approach.
File Extracts
Source systems with batch feeds will not be able to provide a near real time feed. Frequent extracts (hourly) can be taken, but this may be an overhead on source systems . Usually source systems only provide a daily extract. Two methods SQL Loader External Tables Cons One of the slowest methods for data transfer.
Cons Additional structure needs to be created on source database side i.e. MV logs.
Comparison of Methods
File Extracts
Real Time (RT)/ Non-Real Time (NRT)
Database Link
Transportable Tablespaces
CDC
NRT
NRT
NRT
NRT
NRT
RT
Significant
Significant
Significant
Significant
Minimal
Minimal the impact is caused only by additional logging and log transfer
No
No
No 16 million in 9 mins
Yes
Yes
Not Tested
9.5 million in 6 mins 35 secs Timestamp Based if timestamps not updated, changes are not identified Simple one step only defined by the SQL Select statement
Not Tested
Not Tested
Timestamp Based
100% - all the changes are identified via the redo log files
Medium
Medium
Simple
Medium
Complex CDC config, change tables on different instance, cannot use complex joins