This article presents installation of Oracle database 12C(12.1) on Fedora 21.
Read following article to install Fedora 21 Linux: Install Fedora 21(for comfort set 4G memory for your virtual machine).
This article presents how to install Fedora 21 – Live Workstation version.
I assume you have already downloaded Fedora 21 64 bit Live Workstation(about 1,37 G) and you know how to use VirtualBox 64 bit(100M). Create virtual machine with default settings for Linux Fedora 64 bit. 2GB ram and 64G(includes extra space for Oracle installations) for disk is enough plus increase video memory to 128M. Rest of options you can keep default.
This article presents how to configure physical standby database for Oracle Database 12C release 1 (12.1). It’s not focusing on transportation method, duplication method, protection modes nor extra functionality available for physical standbys. All above will be part of future articles :).
This presentation is based on the following article Install Oracle 12C Release 1 (12.1) on Oracle Linux 6 (OEL6).
Final standby configuration is very simple:
During installation of Oracle you can encounter typical error commonly know by DBAs
ORA-00845: MEMORY_TARGET not supported on this system
Oracle is using for automatic memory management Linux shared segments. Usually they are too small but you can modify it on-the-fly.
Just modify entry in “/etc/fstab” to have persistent settings between reboot of your machine. Here shared segments are set to 2500M.
tmpfs /dev/shm tmpfs size=2500M 0 0
mount -o remount tmpfs
mount | grep tmpfs tmpfs on /dev/shm type tmpfs (rw,size=2500M)
to see what is using shared segments run following command
[oracle@oel6 ~]$ ipcs -m ------ Shared Memory Segments -------- key shmid owner perms bytes nattch status 0x00000000 158433298 oracle 640 4096 0 0x00000000 158466067 oracle 640 4096 0 0x00000000 158498836 oracle 640 4096 0 0x9d984658 158531605 oracle 640 12288 49
Have a fun
Default sqlplus prompt is very simple once you connect to a database.
sqlplus / as sysdba SQL>
This article shows how you can enhance it using sqlplus command SET SQLPROMPT and predefined user variables.
sqlplus / as sysdba SQL> set sqlprompt "DBAORA.COM> " DBAORA.COM>
There are two important improvements in making big datafile backups and restores in Oracle 12C release 1
Multisection option was introduced in 11G and possible only for:
Requirements and restrictions
In Oracle Database 12C new keywords SESSION, GLOBAL are available that can be specified during a sequence creation
CREATE SEQUENCE session_seq START WITH 1 INCREMENT BY 1 SESSION; CREATE SEQUENCE global_seq START WITH 1 INCREMENT BY 1 GLOBAL;
GLOBAL – creates standard sequence well known in previous release. This is the default.
SESSION – creates new type session sequence, which is a special type of sequence that is specifically designed to be used with global temporary tables that have session visibility. Session sequence returns a unique range of sequence numbers only within a session, but not across sessions. Another difference is that session sequences are not persistent. If a session goes away, so does the state of the session sequences that were accessed during the session.
Session sequences must be created by a read-write database but can be accessed on any read-write or read-only databases (either a regular database temporarily open read-only or a standby database).
CACHE, NOCACHE,NOORDER are ignored when specified with SESSION calues
In Oracle 12C release 1 most of SQL and PL/SQL commands are supported in rman:
In previous releases
RMAN> sql 'create table test_tbl(id number)';
In Oracle Database 12C
RMAN> create table test_tbl(id number); RMAN> select * from test_tbl; RMAN> desc test_tbl
Have a fun
In 12C release 1 Oracle has introduced new administrative privilege SYSBACKUP. It’s less powerful than SYSDBA:
During installation of oracle database binaries the privilege is associated with OS group backupdba.
Example of adding oracle dedicated groups
#groups for database management groupadd -g 54321 oinstall groupadd -g 54322 dba groupadd -g 54323 oper groupadd -g 54324 backupdba groupadd -g 54325 dgdba groupadd -g 54326 kmdba groupadd -g 54327 asmdba groupadd -g 54328 asmoper groupadd -g 54329 asmadmin
useradd -u 54321 -g oinstall -G dba,oper,backupdba,dgdba,kmdba oracle
when installation of binaries is going on automatically new group is recognized
APPROX_COUNT_DISTINCT is new function available since version 188.8.131.52. It returns approximate number of rows that contain distinct values of expr.
It’s alternative to the COUNT (DISTINCT expr) function, which returns the exact number of rows that contain distinct values of expr.
For processing large amounts of data it’s significantly faster than COUNT, with negligible deviation from the exact result.