Database Administration (MOSC)

MOSC Banner

Renaming PDB after clone

Dear Experts,

We are cloning from PROD to UAT. This is the first clone from PROD. We are facing issue while renaming PDB from PRODDB to UATDB. Please need your suggestion to fix this issue.

ENV:
=====

2 node RAC 19c 19.12

Source CDB prodcdb--> prodcdb1 and prodcdb2
Source PDB name PRODDB

Target CDB uatcdb-->uatcdb1 and uatcdb2
Target PDB name UATDB

After completion of RMAN duplicate:
==================================

[orauat@erpuatdb1 ~]$ sqlplus "/as sysdba"
Version 19.17.0.0.0

SQL> sho pdbs

  CON_ID CON_NAME            OPEN MODE RESTRICTED
---------- ------------------------------ ---------- ----------
     2 PDB$SEED            READ ONLY NO
     3 PRODDB             READ WRITE NO

SQL> alter session set container=PRODDB;

Session altered.


SQL> select count(*) from cdb_services c, service$ s
where upper(s.name) = upper('UATDB')
and s.deletion_date is null
and s.name = c.name; 2  3  4

 COUNT(*)
----------
     0


We are trying to rename PDB from PRODDB to UATDB:
================================================


[orauat@erpuatdb1 ~]$ cd /u02/UAT19CBASE/19chome/appsutil
[orauat@erpuatdb1 appsutil]$ . txkSetCfgCDB.env dboraclehome=/u02/UAT19CBASE/19chome
Oracle Home being passed: /u02/UAT19CBASE/19chome

[orauat@erpuatdb1 appsutil]$ export ORACLE_SID=uatcdb1
[orauat@erpuatdb1 appsutil]$
[orauat@erpuatdb1 appsutil]$ sqlplus "/as sysdba"

SQL*Plus: Release 19.0.0.0.0 - Production on Wed Feb 22 17:13:43 2023
Version 19.17.0.0.0

Copyright (c)

Howdy, Stranger!

Log In

To view full details, sign in to My Oracle Support Community.

Register

Don't have a My Oracle Support Community account? Click here to get started.

Category Leaderboard

Top contributors this month

New to My Oracle Support Community? Visit our Welcome Center

MOSC Help Center