New Oracle 12C performance summary
Basic RAC Maintenance
1) Check RAC status
[Grid @ rac01 ~] $ Crsctl check crs
CRS-4638: Oracle High Availability Services is online
CRS-4537: Cluster Ready Services is online
CRS-4529: Cluster Synchronization Services is online
CRS-4533: Event Manager is online.
[Grid @ rac01 ~] $ Olsnodes-n
Rac01 1
Rac02 2
[Grid @ rac01 ~] $ Srvctl status asm-
ASM is running on rac01, rac02
ASM is enabled.
[Grid @ rac01 ~] $ Srvctl status res-t
[Grid @ rac01 ~] $ Crs_stat-t
2) disable the RAC Environment
[Grid @ rac01 ~] $ Crs_stop-all
[Grid @ rac01 ~] $ Crs_start-all
3) Disable enabling a Single Node
Close
[Root @ rac01 ~] #/U01/app/12.1.0/grid/bin/crsctl stop crs
Or
[Grid @ rac02 ~] $ Srvctl stop listener-n rac01
[Grid @ rac02 ~] $ Srvctl stop nstance-d testshf_n-I TESTSHF1
[Grid @ rac02 ~] $ Srvctl stop asm-n rac01
[Grid @ rac02 ~] $ Srvctl stop nodeapps-n rac01
Enable
[Root @ rac01 ~] #/U01/app/12.1.0/grid/bin/crsctl start crs
Or
[Grid @ rac02 ~] $ Srvctl start listener-n rac01
[Grid @ rac02 ~] $ Srvctl start nstance-d testshf_n-I TESTSHF1
[Grid @ rac02 ~] $ Srvctl start asm-n rac01
[Grid @ rac02 ~] $ Srvctl start nodeapps-n rac01
CDB and PDB
Introduction
Oracle 12C introduces new features of CDB and PDB. In the multi-tenant user Environment (Multitenant Environment) introduced by ORACLE 12C, a database container (CDB) is allowed) host multiple pluggable databases (PDB ). CDB is called the Container Database, and the Chinese translation is a Database Container. PDB is called the Pluggable Database, which can be used to plug and unplug the Database. Before ORACLE 12C, an instance and a database have one-to-one or many-to-one relationship (RAC): that is, an instance can only be associated with one database, and the database can be loaded by multiple instances. The relationship between instances and databases cannot be one-to-many. After entering ORACLE 12C, the relationship between the instance and the database can be one-to-many. The following is the relationship between CDB and PDB in the official documents.
Does this CDB and PDB feel the same as the single-instance multi-database architecture of SQL SERVER. For example, PDB $ SEED can be regarded as a system database such as master and msdb, and PDBS can be regarded as a user-created database. The concept of pluggable is the same as that of separating and attaching user databases in SQL SERVER. It seems that ORACLE has also copied the concept of an SQL SERVER, but it just changed its packaging.
Migration from 32-bit to 64-bit for a single Oracle instance
Install Oracle 11gR2 (x64) in CentOS 6.4)
Steps for installing Oracle 11gR2 in vmwarevm
Install Oracle 11g XE R2 In Debian
CDB Components (Components of a CDB)
A cdb database container contains the following components:
ROOT component
ROOT, also known as CDB $ ROOT, stores metadata and Common users provided by ORACLE. An example of metadata is the source code of the PL/SQL package provided by ORACLE, common User is a User that exists in each container.
SEED component
Seed is also called PDB $ SEED. This is the template for creating a PDBS database. You cannot add or modify an object in Seed. One CDB can have only one Seed. This sentiment is very similar to the model database in SQL SERVER.
PDBS
There can be one or more PDBS in CDB. PDBS is backward compatible and can be used to operate PDBS as in the database. Most common operations are described here.
Each of these components can be called a container. Therefore, ROOT is a container, Seed is a container, and each PDB is a container. Each container has a unique ID and name in CDB.
1) connect to the CDB Database
2) check whether the database is CDB
SQL> select name, decode (cdb, 'yes', 'multitenant Option enabled', 'regular 12c Database: ') "Multitenant Option", open_mode, con_id from v $ database; NAME Multitenant Option OPEN_MODE CON_ID --------- ------------------------------- ------------------ ---------- Epps Multitenant Option enabled read write 0
YES indicates that the database is CDB, if it is NO indicates that it is a NO-CDB (normal database)
3) view the current Container (Container)
3.1
SQL> show con_name CON_NAME------------------------------CDB $ root SQL> select sys_context ('userenv', 'Con _ name') "Container DB" from dual; Container DB----------------------------------------------------CDB $ ROOTSQL>
4) view the PDBS information in the CDB container
Check the number of pluggable databases in CDB
SQL> select con_id, dbid, guid, name, open_mode from v $ pdbs; CON_ID dbid guid name OPEN_MODE ---------- ---------------------------------- ------------------------------ ---------- 2 4071321146 running PDB $ seed read only 3 1930201447 running pdbepps mounted SQL>
5) Start the PDB Database
Method 1:
SQL> alter pluggable database PDBEPPS open; Pluggable database altered. SQL> select con_id, dbid, guid, name, open_mode from v $ pdbs; CON_ID dbid guid name OPEN_MODE ---------- ---------------------------------- ------------------------------ ---------- 2 4071321146 bytes PDB $ seed read only 3 1930201447 bytes PDBEPPS READ WRITE
Method 2:
SQL> alter session set container = PDBEPPS; Session altered. SQL> startupPluggable Database opened. SQL>
For more details, please continue to read the highlights on the next page: