Oracle Data Appliance (ODA)
Oracle Database Appliance (ODA) is a rack mounted "all-in-one" box supplied by Oracle. It contains 2 nodes, 2 networks, 2 power supplies and 1 or 2 storage (magnetic disk or SSD) units accessible to both nodes.
The 2 nodes talk to each other and to storage across an internal 40Gb/s InfiniBand network.
It can be virtualised or bare-metal. You can setup single instance databases, RAC-One (active-passive) or RAC (active-active) databases.
A whole new set of commands is used to interact with ODA - oakcli.
Contents
- 1 Patching Oracle Database Appliance (ODA)
- 2 Useful commands
- 2.1 Is your ODA installation bare-metal or does it have a virtualised image installed?
- 2.2 Show server status
- 2.3 How many processors are cullrenly allocated to ODA?
- 2.4 Show installed ORACLE_HOMES
- 2.5 Show installed databases
- 2.6 Deploy virtualised platform on ODA
- 2.7 Deploy ODA_BASE on ODA
- 2.8 Create a database
- 2.9 Create a new ORACLE_HOME
- 2.10 Upgrade 1 database to new version
- 2.11 Upgrade all databases from a given ORACLE_HOME to new version
- 2.12 Show the available virtual machines
- 3 Useful queries
- 4 Package up useful diagnostic data when opening an SR at Oracle
- 5 Health check a RAC system on ODA
Patching Oracle Database Appliance (ODA)
Useful commands
Is your ODA installation bare-metal or does it have a virtualised image installed?
If virtual, the following command will show 'VM-...' followed by the hardware model used.
oakcli show env_hw
VM-ODA_BASE ODA X4-2
Show server status
Shows server details such as power consumption, temperature and ILOM IP address
oakcli show server
How many processors are cullrenly allocated to ODA?
Also shows total number of available CPUs
oakcli show cpupool -node 0
Show installed ORACLE_HOMES
oakcli show dbhomes
Show installed databases
oakcli show databases
Name Type Storage HomeName HomeLocation Version ----- ------ -------- -------------- ---------------- ---------- ANT5O RAC OraDb12102_home1 /u01/app/oracle/product/12.1.0.2/dbhome_1 12.1.0.2.160419(22291127,21948344) PRJESS2 RAC ASM OraDb12102_home1 /u01/app/oracle/product/12.1.0.2/dbhome_1 12.1.0.2.160419(22291127,21948344) DEVOTASO SINGLE OraDb12102_home1 /u01/app/oracle/product/12.1.0.2/dbhome_1 12.1.0.2.160419(22291127,21948344) CHA5O RAC OraDb12102_home1 /u01/app/oracle/product/12.1.0.2/dbhome_1 12.1.0.2.160419(22291127,21948344) TSTEV3ST SINGLE ASM OraDb12102_home1 /u01/app/oracle/product/12.1.0.2/dbhome_1 12.1.0.2.160419(22291127,21948344) OEMREP RAC ASM OraDb12102_home1 /u01/app/oracle/product/12.1.0.2/dbhome_1 12.1.0.2.160419(22291127,21948344)
Deploy virtualised platform on ODA
oakcli deploy
Deploy ODA_BASE on ODA
oakcli deploy oda_base
Create a database
oakcli create database -d <database name> e.g. oakcli create database -d prod
Create a new ORACLE_HOME
For upgrades etc., you can create a new ORACLE_HOME like this
create dbhome -version <RDBMS version> e.g. create dbhome -version 12.1.0.2
Upgrade 1 database to new version
oakcli upgrade database -db <dbname> -to <destination home name> e.g. oakcli upgrade database -db prod -to 11r2_dbhome1
Upgrade all databases from a given ORACLE_HOME to new version
oakcli upgrade database -from <source home name> -to <destination home name> e.g. oakcli upgrade database -from 11r1_dbhome1 -to 11r2_dbhome1
Show the available virtual machines
oakcli show vm
Useful queries
As seen on Pythian
prompt ------------------------------------------
prompt Patches applied to both the $OH and the DB
prompt ------------------------------------------
with a as (select dbms_qopatch.get_opatch_lsinventory patch_output from dual)
select x.patch_id
, x.patch_uid
, x.rollbackable
, s.status
, x.description
from a
, xmltable('InventoryInstance/patches/*'
passing a.patch_output
columns
patch_id number path 'patchID',
patch_uid number path 'uniquePatchID',
description varchar2(80) path 'patchDescription',
rollbackable varchar2(8) path 'rollbackable'
) x
, dba_registry_sqlpatch s
where x.patch_id = s.patch_id
and x.patch_uid = s.patch_uid
-- and s.bundle_series = 'PSU'
/
prompt --------------------------------------------------------
prompt Patches installed into the $OH but not applied to the DB
prompt --------------------------------------------------------
with a as (select dbms_qopatch.get_opatch_lsinventory patch_output from dual)
select x.patch_id
, x.patch_uid
, x.description
from a
, xmltable('InventoryInstance/patches/*'
passing a.patch_output
columns
patch_id number path 'patchID',
patch_uid number path 'uniquePatchID',
description varchar2(80) path 'patchDescription'
) x
minus
select s.patch_id
, s.patch_uid
, s.description
from dba_registry_sqlpatch s
/
prompt --------------------------------------------------------
prompt Patches applied to the DB but not installed into the $OH
prompt --------------------------------------------------------
with a as (select dbms_qopatch.get_opatch_lsinventory patch_output from dual)
select s.patch_id
, s.patch_uid
, s.description
from dba_registry_sqlpatch s
minus
select x.patch_id
, x.patch_uid
, x.description
from a
, xmltable('InventoryInstance/patches/*'
passing a.patch_output
columns
patch_id number path 'patchID',
patch_uid number path 'uniquePatchID',
description varchar2(80) path 'patchDescription'
) x
/
Package up useful diagnostic data when opening an SR at Oracle
oakcli manage diagcollect
Health check a RAC system on ODA
oakcli orachk -h