DBCA silent mode commands in 19c – Part 1

In oracle 19c, several automations were introduced to database configuration assistant (DBCA) in duplicating databases, cloning or relocating pluggable databases (PDBs). These methods help the DBA to complete these tasks at a rapid pace, without using expensive GUI operations.

Remote cloning of Pluggable database

The setup

Prepare Source Database (where the Original PDB Runs) – PROD

Prepare Target Database (where the remote clone will reside) – PROD2

As we know, enabling archived log mode and setting local undo (to TRUE), at least on our source database (prod) , helps us to perform the cloning without impacting the availability of the source database.

Now that we have all the pre-requisites met, below command will initiate the cloning of PRODPDB1 from PROD database to PROD2PDB2 on PROD2 database.

Remote clone

Note : Ensure PRODPDB1 is in read write mode

dbca -silent \

-sourceDB prod2 \ —  target CDB

-pdbName prod2pdb2 \ — target PDB name

-createPluggableDatabase \

-createFromRemotePDB \

-remotePDBName prodpdb1 \ — source PDB

-remoteDBConnString localhost:1521/prodpdb1 \  — using easy connect method

-remoteDBSYSDBAUserName sys \ — source CDB user

-remoteDBSYSDBAUserPassword oracle123 \ — source CDB password

-dbLinkUsername c##produser \ — source CDB link user

-dbLinkUserPassword oracle123 — source CDB link user password

Now verify the New PDB

By gayan