DataPump Legacy Mode in 11g Release 2

If you’re planning a migration to 11g, then one of the many items on your “to do” list, will be to check whether or not any database management scripts that you currently use will need to be re-written.

If you’re using Oracle 9i Release 2 or earlier, then you’ll be using scripts for the export and import utilities.  Whilst many of the parameters used by these tools have equivalent parameters when using datapump, a useful feature in 11g Release 2 is the legacy mode feature.

With this new feature, you can simply use your existing export/import scripts with the datapump impdp/expdp utilities.  Datapump won’t re-write the scripts for you, but it will transform the parameters as the script runs, so that datapump completes successfully.  At a later stage, you can then re-write your export/import scripts, without having to manually check what changes should be made.

To demonstrate this functionality, we can take a quick norows export of an 11g Release 2 database.  We’ll use the parameters “file”,”log”,”buffer” and “rows” which are export parameters, but aren’t listed as being parameter for use with expdp.

export ORACLE_SID=orcl
export ORACLE_HOME=/u01/opt/oracle/product/11gR2/db_1
expdp system/password file=test_full.dmp log=test_full.log buffer=1048576 rows=n

An extract from the logfile contains the following lines:-

Export: Release 11.2.0.1.0 - Production on Fri Oct 23 22:26:42 2009
Copyright (c) 1982, 2009, Oracle and/or its affiliates.  All rights reserved.
Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
Legacy Mode Active due to the following parameters:
Legacy Mode Parameter: “buffer=1048576″ Location: Command Line, ignored.
Legacy Mode Parameter: “file=test_full.dmp” Location: Command Line, Replaced with: “dumpfile=test_full.dmp”
Legacy Mode Parameter: “log=test_full.log” Location: Command Line, Replaced with: “logfile=test_full.log”
Legacy Mode Parameter: “rows=FALSE” Location: Command Line, Replaced with: “content=metadata_only”
Legacy Mode has set reuse_dumpfiles=true parameter.
Starting “SYSTEM”.”SYS_EXPORT_SCHEMA_01″:  system/******** dumpfile=test_full.dmp logfile=test_full.log content=metadata_only reuse_dumpfiles=true
Processing object type SCHEMA_EXPORT/USER

Master table “SYSTEM”.”SYS_EXPORT_SCHEMA_01″ successfully loaded/unloaded
******************************************************************************
Dump file set for SYSTEM.SYS_EXPORT_SCHEMA_01 is:
  /u01/opt/oracle/admin/orcl/dpdump/test_full.dmp
Job “SYSTEM”.”SYS_EXPORT_SCHEMA_01″ successfully completed at 22:27:59

 

You’ll notice that datapump converts the export-specific parameters to their datapump equivalents on the fly and then completes the export as normal. The other point to notice about the export, is that the dumpfile and logfile will have been created in the default datapump directory, rather than in the location that you ran the commands from - as would have been the case with the export utility.   (select directory_path from dba_directories where directory_name=’DATA_PUMP_DIR’; - to confirm where this location is in your environment).

 

The same legacy mode has also been implemented for the impdp datapump utility. Below is an extract from the logfile for a quick table import, which was run with the parameters “file”,”log”,”buffer”,”ignore” and “commit” from the import utility.
impdp system/password file=table_export.dmp log=table_import.log buffer=1048576 ignore=y commit=y

Import: Release 11.2.0.1.0 - Production on Fri Oct 23 22:44:48 2009

Copyright (c) 1982, 2009, Oracle and/or its affiliates.  All rights reserved.

Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
Legacy Mode Active due to the following parameters:
Legacy Mode Parameter: “buffer=1048576″ Location: Command Line, ignored.
Legacy Mode Parameter: “commit=TRUE” Location: Command Line, ignored.
Legacy Mode Parameter: “file=table_export.dmp” Location: Command Line, Replaced with: “dumpfile=table_export.dmp”
Legacy Mode Parameter: “ignore=TRUE” Location: Command Line, Replaced with: “table_exists_action=append”
Legacy Mode Parameter: “log=table_import.log” Location: Command Line, Replaced with: “logfile=table_import.log”
Master table “SYSTEM”.”SYS_IMPORT_FULL_01″ successfully loaded/unloaded
Starting “SYSTEM”.”SYS_IMPORT_FULL_01″:  system/******** dumpfile=table_export.dmp logfile=table_import.log table_exists_action=append
Processing object type SCHEMA_EXPORT/USER

. . imported “TEST”.”T1″                                5.156 KB      17 rows
Job “SYSTEM”.”SYS_IMPORT_FULL_01″ completed …

References:

1) Oracle 9i Database Utilities Release 2 (9.2)
2) Oracle Database Utilities 10g Release 2 (10.2)
3) Oracle Database Utilities 11g Release 2 (11.2)

One Response to “DataPump Legacy Mode in 11g Release 2”

  1. DataPump Legacy Mode in 11g Release 2 | Canning IT LTD Says:

    […] DataPump Legacy Mode in 11g Release 2 […]

Leave a Reply

You must be logged in to post a comment.


Buy Effexor Buy Ambien Zyprexa Buy Bontril Zyban Levitra Buy Lipitor Ultram Buy Celexa Fioricet Buy Lorazepam Ativan Buy Zyprexa Nexium Celexa Buy Percocet Biaxin Viagra Adderall Percocet Buy Glucophage Buy Fioricet Buy Percocet Buy Effexor Buy Norvasc Buy Biaxin Buy Viagra Online Adderall Buy Prozac Buy Tramadol Buy Valium Buy Diflucan Buy Cipro Adderall Tenuate Xanax Online Bupropion Buy Xanax On Line Propecia Buy Hydrocodone Adipex Meridia Buy Lorazepam Xanax Buy Zocor Buy Oxycontin Buy Tenuate Diflucan Soma Lipitor Xanax Buy Zyban Buy Seroquel Buy Online Xanax Buy Flexeril Phentermine Buy Zithromax Buy Fioricet Buy Oxycontin Buy Prozac Buy Darvocet Ultracet Paxil Buy Ambien Oxycontin Buy Zyrtec Ambien Buy Generic Viagra Buy Line Xanax Cheap Phentermine Effexor Buy Zyprexa Phentermine Online Didrex Buy Levitra Buy Adderall Buy Xanax Online Buy Xanax Valium Online Buy Xanax Buy Adipex