Save state of Pluggable database in Oracle

 

Pluggable Database Saved State in Oracle

Saved State is a feature in Oracle for saved the OPEN state of all PDBS when CDB is restart. It will bring PDBs to same state if it open then it bring the PDB in Open State or if PDB is closed when CDB restart then it bring PDB in closed state. Open the database in READ-WRITE/READ-ONLY mode it save state.

Check the Save State for PDBS

select a.name,b.state from v$pdbs a , dba_pdb_saved_states b where a.con_id = b.con_id;

SELECT con_name, instance_name, state FROM cdb_pdb_saved_states;

When database gets unplug and plug this saved state will be lost.

Save the existing State of PDB

alter pluggable database PDB1 save state;
Pluggable database altered.

Discard or unsaved the existing state of PDB

alter pluggable database HYDB discard state;
Pluggable database altered.

Show the pdbs

Show pdbs

Preserving the Open Mode of All PDBs

ALTER PLUGGABLE DATABASE ALL SAVE STATE;

Preserving the Open Mode of Multiple PDBs

ALTER PLUGGABLE DATABASE PDB1 , PDB2 SAVE STATE;

Preserving the Open Mode of All PDBs Except

ALTER PLUGGABLE DATABASE ALL EXCEPT PDB3, PDB4 SAVE STATE;

SQL> alter pluggable database PDB open read write instances=all;


Pluggable database altered.


SQL> show pdbs;


    CON_ID CON_NAME                       OPEN MODE  RESTRICTED

---------- ------------------------------ ---------- ----------

         2 PDB$SEED                       READ ONLY  NO

         3 PDB                            READ WRITE NO

SQL> alter pluggable database pdb save state;


Pluggable database altered.

Comments

Popular posts from this blog

How to fix Oracle SQL Developer connection issue "Got minus one from a read call"

How to drop index and before dropping it how to get the DDL.

How to troubleshoot Long Running Concurrent Request in EBS 12.2

How to autopopulate user_guid in fnd_user table ( EBS Blank Page)

Opatch is getting faild for GI patch with error code 2 while doing prereq

Few Important steps of Oracle Database Clone

How to Check AD and TXK code levels in your EBS environment

The Server is not able to service this request: [Socket:000445]Connection rejected, filter blocked Socket, weblogic.security.net.FilterException

CPU Patch Analysis

PRVG-11250 : The check "RPM Package Manager database" was not performed because