Database Reference
In-Depth Information
ENABLE_PLUGGABLE_DATABASE=YES parameter to the auxiliary instance parameter file. The
auxiliary instance that will be created will be a CDB (and thus must be created as a CDB).
With RMAN you can duplicate the entire CDB, a single PDB, or several PDBs. When
you duplicate a PDB, the root and seed PDBs are automatically copied over as well. Thus,
the duplicated database is a fully functional CDB able to plug in, unplug, and copy PDBs.
The RMAN DUPLICATE command provides some additional options when
duplicating PDBs:
PLUGGABLE DATABASE —Duplicates the specified PDBs.
SKIP PLUGGABLE DATABASE —Duplicates all PDBs except the PDBs that are listed.
TABLESPACE —Duplicates specific tablespaces within the PDB listed in the option.
SKIP TABLESPACE —Indicates that all tablespaces in the CDB should be duplicated
except those listed by PDB.
Here are some examples of commands used to duplicate PDBs. In this first example, we
are duplicating the PDB mypdb1 to the CDB called mycdb :
DUPLICATE DATABASE TO mycdb PLUGGABLE DATABASE mypdb1;
In this example, we will duplicate all PDBs in mycdb except the PDB called skippdb :
DUPLICATE DATABASE TO mycdb SKIP PLUGGABLE DATABASE skippdb;
Finally, we can duplicate more than one PDB by using a command similar to this one:
DUPLICATE DATABASE TO mycdb PLUGGABLE DATABASE mypdb1,mypdb3;
Oracle Data Pump and Oracle Multitenant
Oracle Data Pump fully supports operations in a CDB, but this is quite rare. In most cases,
when using Data Pump, you will need to connect directly to the PDB that you wish to export
from. Data Pump does not support exporting all PDBs when logged into the root of the CDB.
Data Pump will return an error if you attempt that operation.
To properly export a PDB, you must log into the PDB that you want to export and then
export that PDB individually. Here is an example where we are exporting the content of
the mypdb PDB:
expdp 'sys/robert@mypdb as sysdba' directory=ROBERT full=y
Note that with the exception of needing to log into the PDB specifically, the way you
export or import data into a PDB is no different than it is with a non-CDB Oracle database.
For example, here we are exporting the SCOTT schema. Note that the expdp command is really
no different:
expdp 'sys/robert@mypdb as sysdba' directory=ROBERT schemas=scott
dumpfile=test.dmp
Search WWH ::




Custom Search