How to Convert Classical Database in Multitenant Architecture Database
Source DB (Classical Architecture) : ORCL1P
Target DB (Multitenant Architecture) : CDB01DB
Container DB (CDB01DB) should already be installed and present
NOTE: Demonstration in this post assumes the conversion on same host
Execute on ORCL1P
Step1>Place the non-CDB in read-only mode
SQL>select name from v$database;
SQL>shutdown immediate;
SQL>startup open read only;
SQL> select name,open_mode from v$database;
Step2> Prepare Conversion
BEGIN
DBMS_PDB.DESCRIBE(
pdb_descr_file => '/ora_temp/rman/ORCL1P/PDB01P.xml');
END;
/
DBMS_PDB.DESCRIBE(
pdb_descr_file => '/ora_temp/rman/ORCL1P/PDB01P.xml');
END;
/
Step3> shutdown the NON-CDB database ( NONCDB)
SQL>shutdown immediate;
Execute on CDB01DB
Step4> Check the compatibility.
Now connect to the container database, where it need to be plugged.
SET SERVEROUTPUT ON
DECLARE
compatible CONSTANT VARCHAR2(3) :=
CASE DBMS_PDB.CHECK_PLUG_COMPATIBILITY(
pdb_descr_file => '/ora_temp/rman/ORCL1P/PDB01P.xml',
pdb_name => 'PDB01P')
WHEN TRUE THEN 'YES'
ELSE 'NO'
END;
BEGIN
DBMS_OUTPUT.PUT_LINE(compatible);
END;
/
Step5> Check for Compatibility and Violations
set line 200
col NAME for a30
col MESSAGE for a30
col ACTION for a30
col CAUSE for a20
SQL> select NAME,CAUSE,ERROR_NUMBER,MESSAGE,STATUS,ACTION from PDB_PLUG_IN_VIOLATIONS;
col NAME for a30
col MESSAGE for a30
col ACTION for a30
col CAUSE for a20
SQL> select NAME,CAUSE,ERROR_NUMBER,MESSAGE,STATUS,ACTION from PDB_PLUG_IN_VIOLATIONS;
Step6> Resolve Violations
- Fix violations that may cause failure.
- Some parameter miss match can be ignored based on requirements
Step7>Plug in the non-CDB as PDB
SQL> create pluggable database PDB01P using '/ora_temp/rman/ORCL1P/PDB01P.xml' NOCOPY tempfile reuse;
NOTE: NOCOPY will simply use the existing datafiles. In case you don't want to touch the existing datafiles but copy the file to new location for new PDB use COPY option together with file_name_convert clause. COPY is default option
SQL> create pluggable database PDB01P using '/ora_temp/rman/ORCL1P/PDB01P.xml'
FILE_NAME_CONVERT = ('/ora_data/ORCL1P/datafile',
'/ora_data/CDB01DB/pdb01p/datafile/')
'/ora_data/CDB01DB/pdb01p/datafile/')
tempfile reuse;
NOTE: DO not open the PDB now
Step8> Check PDB status
SQL> show pdbs
CON_ID CON_NAME OPEN MODE RESTRICTED
---------- ------------------------------ ---------- ----------
2 PDB$SEED READ ONLY NO
---------- ------------------------------ ---------- ----------
2 PDB$SEED READ ONLY NO
4 PDB01P MOUNTED
SQL>ALTER SESSION SET CONTAINER=PDB01P;
Step9: run noncdb_to_pdb.sql script
@$ORACLE_HOME/rdbms/admin/noncdb_to_pdb.sql
Step10> Open the PDB and verify
SQL>ALTER PLUGGABLE DATABASE PRB01P OPEN; instances=all;
Pluggable database created.
SQL> SELECT name, open_mode FROM v$pdbs;
SQL> show pdbs
CON_ID CON_NAME OPEN MODE RESTRICTED
---------- ------------------------------ ---------- ----------
2 PDB$SEED READ ONLY NO
4 PDB01P READ WRITE NO
---------- ------------------------------ ---------- ----------
2 PDB$SEED READ ONLY NO
4 PDB01P READ WRITE NO
set line 200
col NAME for a30
col MESSAGE for a30
col ACTION for a30
col CAUSE for a20
SQL> select NAME,CAUSE,ERROR_NUMBER,MESSAGE,STATUS,ACTION from PDB_PLUG_IN_VIOLATIONS;
col NAME for a30
col MESSAGE for a30
col ACTION for a30
col CAUSE for a20
SQL> select NAME,CAUSE,ERROR_NUMBER,MESSAGE,STATUS,ACTION from PDB_PLUG_IN_VIOLATIONS;
Thanks For Post which have lot of knowledge and informataion thanks.... tinyMediaManager Crack
ReplyDeleteblender crack
Ultimate Suite for Excel Crack
DBF Converter Crack
SoftPerfect Network Scanner Crack
DVDFab Passkey Crack
The Bat Professional Crack
AutoRun Pro Enterprise Crack
jAlbum Crack
PCDJ DEX Crack
How To Convert Non-Cdb Into Cdb And Pdb >>>>> Download Now
ReplyDelete>>>>> Download Full
How To Convert Non-Cdb Into Cdb And Pdb >>>>> Download LINK
>>>>> Download Now
How To Convert Non-Cdb Into Cdb And Pdb >>>>> Download Full
>>>>> Download LINK 8F