วันเสาร์ที่ 12 มกราคม พ.ศ. 2556

How do I startup PDB & CDB ?


How do I start up a Pluggable database ?

When connect to current PDB:
SQL> alter pluggable database open;

When connect to root:
SQL> alter pluggable database pdb6 open;

How do I shutdown / close a Pluggable database ?

When connect to current PDB:
SQL> alter pluggable database close;

When connect to root:
SQL> alter pluggable database pdb6 close;


How do I shut down / Startup the Container Database ?

Use startup / Shutdown command similar to startup / shutdown of Non CDB.
When the container database is shutdown  , no PDB is accessible.
In a CDB, the root and all of the PDBs share a single instance, or, when using Oracle RAC, multiple concurrent database instances. You start up and shut down an entire CDB, not individual PDBs. However, when the CDB is open, you can change the open mode of an individual PDB by using the ALTER PLUGGABLE DATABASE statement.

Enjoy 12c, Official is comming soon !!, very exciting !

วันอังคารที่ 8 มกราคม พ.ศ. 2556

Oracle Database 12C What is plugable database ?


Pluggable Databases (PDBs) is new in Oracle Database 12c Release 1 (12.1). You can have many pluggable databases inside a single Oracle Database occurrence. Pluggable Databases are fully backwards compatible with an ordinary pre-12.1 database.


Here this is example basic CDB / PDB Operations

How do I know if my database is Container Database or  Non Container database ?
SQL> select NAME, DECODE(CDB, 'YES', 'CONTAINER DATABASE', 'NON CONTAINER DATABASE') "Container DB ?" , OPEN_MODE, CON_ID from V$DATABASE;
NAME               Container DB ?                 OPEN_MODE                   CON_ID
---------           ------------------------       --------------------           ----------
CDB2              CONTAINER DATABASE       MOUNTED                       0


What Pluggable databases do we have in this container database ?
SQL>  select CON_ID, NAME, OPEN_MODE from V$PDBS;
    CON_ID NAME                          OPEN_MODE
---------- ------------------------       ------------
         2 PDB$SEED                        READ ONLY
         3 PDB1                                 MOUNTED
         4 PDB2                                 MOUNTED
         5 PDB3                                 MOUNTED
         6 PDB4                                 MOUNTED
         7 PDB5                                 MOUNTED
         8 PDB6                                 MOUNTED
         9 PDB7                                 MOUNTED
 ...

How do I connect to a Pluggable Database , say, PDB5 ?
SQL> alter session set container = pdb5;

How do I switch to main container Database ?
SQL> ALTER SESSION SET CONTAINER = CDB$ROOT;

How do I determine which PDB or CDB I am currently connected to ?
SQL> show con_name
CON_NAME
------------------------------
PDB5

Enjoy Oracle Database 12C !!! 
Chatchai

วันศุกร์ที่ 4 มกราคม พ.ศ. 2556

Oracle Database 12c Release 1 (12.1) Upgrade New Features


DBUA interface  is changed completely .It is now panel based ( same as OUI ) .DBUA upgrade is  divided into the phase
  • Pre Upgrade Steps
  • Database Upgrade Steps
  • Post Upgrade Steps

1. Enhanced Upgrade Automation with New Pre-Upgrade Information Tool

2. Parallel Processing for Database Upgrade
  • Upgrade parallelism is the new featur introduced in Oracle database 12c R1  , where upgrade scripts and processes can run in parallel
3. New Upgrade Utility catctl.pl
  • The Upgrade Utility (catctl.pl), introduced in Oracle Database 12c.
  • It loads the data dictionary and components in parallel, thus reducing the overall upgrade time.

Oracle XML Database is Mandatory with Installation
  • Oracle XML Database (Oracle XML DB) is now a mandatory component of Oracle Database. . If during the upgrade, Oracle XML DB is not found to be installed, then Oracle XML DB is automatically loaded into the SYSAUX tablespace.The upgraded Oracle Database includes Oracle XML DB.
Enjoy ! New Version Oracle Database 12C !!,  Oracle'll official announce soon in first Q 2013.
Regard,
Chatchai