Database Reference
In-Depth Information
[oracle@server2 CDBFSDCB]$ ls -l PDB5
total 875604
-rw-r-----. 1 oracle asmadmin 5251072 Sep 17 12:12 PDB5_users01.dbf
-rw-r-----. 1 oracle asmadmin 618668032 Sep 17 12:12 sysaux01.dbf
-rw-r-----. 1 oracle asmadmin 272637952 Sep 17 12:12 system01.dbf
-rw-r-----. 1 oracle asmadmin 20979712 Sep 17 01:12 temp01.dbf
[oracle@server2 CDBFSDCB]$
Remember from Chapter 7 that you need the XML file describing the PDB as well. Without the XML metadata
you cannot plug the PDB into the CDB. The XML file resides in /home/oracle/PDB5.xml in the example. With this
information it is possible to plug the PDB into the primary CDB:
SQL> create pluggable database PDB5
2 using '/home/oracle/PDB5.xml'
3 nocopy;
Pluggable database created.
The operation completes successfully on both primary and standby databases.
2013-09-17 12:20:07.834000 +01:00
Recovery created file /u01/oradata/CDBFSDCB/PDB5/system01.dbf
Datafile 23 added to flashback set
[...]
Successfully added datafile 25 to media recovery
Datafile #25: '/u01/oradata/CDBFSDCB/PDB5/PDB5_users01.dbf'
In scenarios where you have more than one standby database you need to make the PDB available to all standby
databases.
Unplugging PDBs from the primary
In the next example pluggable database PDB3 is unplugged from the primary. Prior to this example PDB3 exists in the
primary and standby database:
SQL> select name,guid from v$pdbs;
NAME GUID
------------------------------ --------------------------------
PDB$SEED E6483A08FB7940D8E0431464A8C0318D
PDB1 E6484B59FBEC4908E0431464A8C06F2E
PDB2 E689AE04FAB41253E0431564A8C0354E
PDB3 E689AE04FAB51253E0431564A8C0354E
To show you that it exists in the standby as well v$pdbs is queried against the GUID of PDB3:
SQL> select name,guid from v$pdbs
2 where guid = 'E689AE04FAB51253E0431564A8C0354E';
 
Search WWH ::




Custom Search