Manual Creation of an Oracle 19c Container Database
Step 1: create new P FILE with below contents and mention "ENABLE_PLUGGABLE_DATABASE=TRUE" for COntainer database inittesdbcdb.ora [oracle@tesdb dbs]$ cd $ORACLE_HOME/dbs [oracle@tesdb dbs]$ pwd /u01/app/oracle/product/19.0.0/dbhome_1/dbs [oracle@tesdb dbs]$ cat inittesdbcdb.ora db_name=tesdbcdb CONTROL_FILES='/u01/app/oracle/oradata/tesdbcdb/control01.ctl' ENABLE_PLUGGABLE_DATABASE=TRUE DB_BLOCK_SIZE=8192 UNDO_TABLESPACE=undotbs USER_DUMP_DEST='/u01/app/oracle/oradata/tesdbcdb/adump/' DB_CREATE_FILE_DEST='/u01/app/oracle/oradata/tesdbcdb/' DB_CREATE_ONLINE_LOG_DEST_1='/u01/app/oracle/oradata/tesdbcdb/' DB_BLOCK_SIZE=8192 UNDO_MANAGEMENT=AUTOStep 2: Create necessary directories. [oracle@tesdb oradata]$ pwd /u01/app/oracle/oradata/ [oracle@tesdb oradata]$ mkdir tesdbcdb [oracle@tesdb oradata]$ ll drwxr-x---. 2 oracle oinstall 4096 Oct 20 17:35 TESDB drwxr-xr-x. 2 oracle oinstall 6 Oct 27 17:54 tesdbcdb [oracle@tesdb oradata]$ cd tesdbcdb/ [oracle@tesdb tesdbcdb]$ mkdir -p /u01/app/oracle/oradata/tesdbcdb/adumpStep 3: start the new database in the nomount stage oracle@tesdb dbs]$ export ORACLE_SID=tesdbcdb [oracle@tesdb dbs]$ sqlplus / as sysdba SQL*Plus: Release 19.0.0.0.0 - Production on Fri Oct 27 18:04:28 2023 Version 19.3.0.0.0 Copyright (c) 1982, 2019, Oracle. All rights reserved. Connected to an idle instance. SQL> startup nomount ORA-32004: obsolete or deprecated parameter(s) specified for RDBMS instance ORACLE instance started. Total System Global Area 318767000 bytes Fixed Size 9133976 bytes Variable Size 251658240 bytes Database Buffers 50331648 bytes Redo Buffers 7643136 bytesStep 4: Create a script as below to create a manual database using create database command with ENABLE PLUGGABLE DATABASE clause. create database tesdbcdb user sys identified by oracle user system identified by manager maxlogfiles 3 maxlogmembers 3 logfile group 1 size 50m,group 2 size 50 m default temporary tablespace temp tempfile size 50m undo tablespace undotbs datafile size 200m enable pluggable database;Step 5: Run this script on sql prompt SQL> create database tesdbcdb user sys identified by oracle user system identified by manager maxlogfiles 3 maxlogmembers 3 logfile group 1 size 50m, group 2 size 50 m default temporary tablespace temp tempfile size 50m undo tablespace undotbs datafile size 200m enable pluggable database; Database created.Step 6: Check for the container databse details SQL> select name,open_mode,CDB from v$database; NAME OPEN MODE CDB -------- ---------- ------ TESDBCDB READ WRITE YESStep 7: Create a pluggable database SQL> CREATE PLUGGABLE DATABASE mypdb1 ADMIN USER mypdb1_adm IDENTIFIED BY oracle; Pluggable database created.Step 8: Check for the database details SQL> show pdbs
|