Skip to content

How to clone remote PDB with dbaascli on ExaCC?

When your DB infrastructure move to ExaCC, it’s a good option to appropriate the tools offer by it to facilitate your life. And for ExaCC, this tool is dbaascli. It manages many aspects of the ExaCC layers. And in this blog, we focus on the clone remote PDB with dbaascli!

The environment used for this blog is :

Server NameCDB NamePDB NameScan name
SourceExaCC-1CDBORA1PDBORA1ExaCC-1-scan.mydomain.ch
TargetExaCC-2CDBORA2PDBORA2ExaCC-2-scan.mydomain.ch

The target PDB (PDBORA2) must not exist on the target CDB (CDBORA2). Unless it, an error will be raised.

And in addition, the SYS password will be asked for the remote CDB.

You must connect on the target server with the root or oracle OS account. In my case, I will use the oracle account.

The dbaascli syntax is simple and friendly :

dbaascli pdb remoteClone --pdbName <value> --dbName <value> --sourceDBConnectionString <value> [--targetPDBName <value>] [--powerLimit <value>] [--maxCPU <value>] [--maxSize <value>] [--resume [--sessionID <value>]] [--executePrereqs] [--waitForCompletion <value>] [--sourcePDBExportedTDEKeyFile <value>]
        {
            [--blobLocation <value>]
            | [--standbyBlobFromPrimary <value>]
        }
[--excludeUserTablespaces <value>] 
[--excludePDBData <value>] 
[--pdbAdminUserName <value>] 
[--lockPDBAdminAccount <value>] 
[--sourcePDBServiceConvertList <value>] 
[--refreshablePDB --refreshMode <value> [--refreshIntervalInMinutes <value>] --dblinkUsername <value> 
[--honorCaseSensitiveUserName]] 
[--updateDBBlockCacheSize]

Where mandatory parameters are :

Questions about your own setup? A dbi services consultant can look at your case.

Talk to an expert (opens in a new tab)

--pdbName specifies the name of the source PDB that you want to clone

--dbname specifies the name (DB_NAME) of the CDB that hosts the newly cloned PDB

--sourceDBConnectionString specifies the source database connection string in the format scan_name:scan_port/database_service_name

--targetPDBName specifies the name for the target PDB (new cloned PDB)

For this blog, we must use this command :

oracle@ExaCC-2:~/ [CDBORA2] dbaascli pdb remoteclone --pdbname PDBORA1 --dbname CDBORA2 --targetPDBName PDBORA2 --sourceDBConnectionString ExaCC-1-scan.mydomain.ch:1521/CDBORA1.mydomain.ch
DBAAS CLI version 24.3.2.0.0
Executing command pdb remoteclone --pdbname PDBORA1 --dbname CDBORA2 --targetPDBName PDBORA2 --sourceDBConnectionString ExaCC-1-scan.mydomain.ch:1521/CDBORA1.mydomain.ch
Job id: 688a8b27-40b1-4115-9fbb-deabc741a235
Session log: /var/opt/oracle/log/CDBORA2/pdb/remoteClone/dbaastools_2025-01-28_11-27-30-AM_153668.log
Enter REMOTE_DB_SYS_PASSWORD:

Enter REMOTE_DB_SYS_PASSWORD (reconfirmation):

Loading PILOT...
Session ID of the current execution is: 689
Log file location: /var/opt/oracle/log/CDBORA2/pdb/remoteClone/pilot_2025-01-28_11-33-38-AM_178552
-----------------
Running Plugin_initialization job
Enter TDE_PASSWORD:
****************
Enter REMOTE_DB_SYS_PASSWORD
****************
Completed Plugin_initialization job
-----------------
Running Validate_input_params job
Completed Validate_input_params job
-----------------
Running Validate_target_pdb_service_name job
Completed Validate_target_pdb_service_name job
-----------------
Running Perform_dbca_prechecks job
Completed Perform_dbca_prechecks job
-----------------
Running Perform_pdb_cross_release_prechecks job
Completed Perform_pdb_cross_release_prechecks job
Acquiring read lock: _u02_app_oracle_product_19.0.0.0_dbhome_1
Acquiring read lock: CDBORA2
Acquiring write lock: PDBORA2
-----------------
Running PDB_creation job
Completed PDB_creation job
-----------------
Running Load_pdb_details job
Completed Load_pdb_details job
-----------------
Running Configure_pdb_service job
Completed Configure_pdb_service job
-----------------
Running Configure_tnsnames_ora job
Completed Configure_tnsnames_ora job
-----------------
Running Set_pdb_admin_user_profile job
Completed Set_pdb_admin_user_profile job
-----------------
Running Lock_pdb_admin_user job
Completed Lock_pdb_admin_user job
-----------------
Running Register_ocids job
Skipping. Job is detected as not applicable.
-----------------
Running Prepare_blob_for_standby_in_primary job
Skipping. Job is detected as not applicable.
Releasing lock: PDBORA2
Releasing lock: CDBORA2
Releasing lock: _u02_app_oracle_product_19.0.0.0_dbhome_1
-----------------
Running Generate_dbsystem_details job
Acquiring native write lock: global_dbsystem_details_generation
Releasing native lock: global_dbsystem_details_generation
Completed Generate_dbsystem_details job

dbaascli execution completed

And from now a new PDB has been created on the target CDB :

oracle@ExaCC-2:~/ [] CDBORA2
*******************************************************
 INSTANCE_NAME   : CDBORA21
 DB_NAME         : CDBORA2
 DB_UNIQUE_NAME  : CDBORA2
 STATUS          : OPEN READ WRITE 
 LOG_MODE        : ARCHIVELOG
 USERS/SESSIONS  : Normal: 0/0, Oracle-maintained: 2/16
 DATABASE_ROLE   : PRIMARY
 FLASHBACK_ON    : YES
 FORCE_LOGGING   : YES
 VERSION         : 19.25.0.0.0
 NLS_LANG        : AMERICAN_AMERICA.WE8ISO8859P15
 CDB_ENABLED     : YES
 PDBs            : PDBORA2  PDB$SEED  
 *******************************************************

Let’s work together

Ready to operate at
the next level?

Tell us about your challenge. We’ll bring the depth, the expertise, and the Swiss precision.

Xavier Franck Godard

Xavier Franck Godard

Xavier-Franck Godard has more than 25 years of experience in Information Technology. His expertise covers database architecture, disaster recovery (Data Guard), backup and recoverability configuration (RMAN, Flashback), performance analysis and tuning (AWR/ADDM, Statspack), and migration/upgrade projects on-premises and on Oracle Database Appliance. Prior to dbi services, he was a senior DBA at DIGORA for seven years, a database consultant at A2F Services for seven years, and a DBA at Société des Autoroutes Paris-Normandie (SAPN) for eight years. He holds a Master's degree in Pure Mathematics. His industry experience covers retail, public sector, insurance, banking, health, and e-commerce.View Author posts

5 posts since January 2025

Most read in Oracle

The Oracle posts our readers open most: the all-time favourites, and what is trending right now.

2 thoughts on “How to clone remote PDB with dbaascli on ExaCC?”

  1. Xavier Franck Godard

    Hi Jack and thanks for your reply.
    No technical issues with duplicate terabyte database with this method.
    And if the sqlnet layer is ok between the servers, it wil work.

  2. That’s good one ! Will it work for remote container from different server or subnet if port is open and db size is in tb’s ?

Leave a Comment

Your email address will not be published. Required fields are marked *