Show Menu
Cheatography

Oracle 12c: First scope Cheat Sheet (DRAFT) by

oracle 12 first scope

This is a draft cheat sheet. It is a work in progress and is not finished yet.

Instal­lation

For testing, using default options, configure oracle­_ho­me,­ora­cle­_base and inventory structure

Create Oracle12c DB

using dbca, configure the cdb,pdb, listener and em ( default port 5500)

First Scope of 12c Database

https://localhost:5500/em
-- with Em Express Login issues:switch to CDB$ROOT, run exec dbms_xdb_config.setglobalportenabled(TRUE);
--check https port
--common user need em_express_basic or em_empress_all role

set oracle_sid=cdb
sqlplus sys as sysdba
alter pluggable database pdb1 open;

select name, cdb,con_id from v$database;
select instance_name, status,con_id from v$instance;
select dbms_xdb_config.getHttpsPort() from dual;
select con_id, name, open_mode from v$pdbs;

--swtich to different pdb
ALTER SESSION SET CONTAINER=pdb1;
show con_name
show parameter dispatchers

--switch back to cdb
Alter session set container=CDB$ROOT;

No listener error: ora-015241

listner is up and seems fine.
$oracl­e_h­ome­/ne­two­rk/­adm­in/­sql­net.ora
host=l­oca­lhost
host=1­27.0.0.1
USE_SI­D_A­S_S­ERV­ICE=on
for tnsnam­es.ora with sid hard coded
 

listen­er.ora example

# listener.ora Network Configuration File: D:\oracle\product\12.2.0\dbhome_1\network\admin\listener.ora
# Generated by Oracle configuration tools.

SID_LIST_LISTENER =
  (SID_LIST =
    (SID_DESC =
      (SID_NAME = CLRExtProc)
      (ORACLE_HOME = D:\oracle\product\12.2.0\dbhome_1)
      (PROGRAM = extproc)
      (ENVS = "EXTPROC_DLLS=ONLY:D:\oracle\product\12.2.0\dbhome_1\bin\oraclr12.dll")
    )
  )

LISTENER =
  (DESCRIPTION_LIST =
    (DESCRIPTION =
      (ADDRESS = (PROTOCOL = TCP)(HOST = hostname.unmc.edu)(PORT = 1521))
      (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))
    )
  )
if set host=h­ost­nam­e.u­nmc.edu will solve the no tns listner issue from toad