Check the status of an Oracle database and its Pluggable Databases (PDBs)

Check the Status of the Non-Container Database:

SELECT INSTANCE_NAME, STATUS FROM V$INSTANCE;

Check the Status of the Container Database (CDB)

Run the following query to check the status of the CDB:

SELECT INSTANCE_NAME, STATUS FROM V$INSTANCE

Check the Status of All PDBs

Run this query to see the status of all PDBs:

SELECT NAME, OPEN_MODE, RESTRICTED FROM V$PDBS;

Check the Status of a Specific PDB

If you want to check the status of a specific PDB, use:

SELECT NAME, OPEN_MODE, RESTRICTED FROM V$PDBS WHERE NAME = 'your_pdb_name';

Open or Close a PDB

To open a PDB:

ALTER PLUGGABLE DATABASE your_pdb_name OPEN;

To close a PDB:

ALTER PLUGGABLE DATABASE your_pdb_name CLOSE;
This entry was posted in Oracle on by .
Unknown's avatar

About SandeepSingh

Hi, I am working in IT industry with having more than 15 year of experience, worked as an Oracle DBA with a Company and handling different databases like Oracle, SQL Server , DB2 etc Worked as a Development and Database Administrator.

Leave a Reply