2. Agenda
Oracle Rapid Home Provisioning 12.22 22.09.2017
1. RHP What is it ?
2. RHP Architecture
3. RHP Security Model
4. RHP Prerequisites and Setup
5. RHP Provisioning
6. Conclusion
3. Who am I
ZDLRA - in Action3 22.09.2017
Daniele Massimi, Trivadis AG (CH, Bern)
Principal Consultant daniele.massimi@trivadis.com
Since 2012 at Trivadis IMS (Infrastructure Service Management)
Oracle DBA since 2000 (Exadata > 6 Jahre)
Infrastructure-Architecture, Operations & Administration, Upgrades and Migration,
High Availability, Backup & Recovery, Virtualization
Engineered Systems (Exadata, ODA, ZDLRA, PCA)
Trainer (Oracle Architectur and Internal, 12c New Features, Exadata)
Oracle Certifications
Oracle Certified Master (11g)
Oracle Certified Professional (8i – 12c)
Oracle Certified Expert (RAC)
Oracle Implementation Specialist (Exadata and OVM)
5. Rapid Home Provisioning – What is it ?
Oracle Rapid Home Provisioning 12.25 22.09.2017
Standardized Tool for provisioning, patching and Upgrade Oracle Grid Infrastructure,
Oracle RDBMS and custom Software
Improve performance, efficiency and simplifies the software deployment process
Automate the software provisioning from a centralized provisioning Server
Helps to save time for provisioning, patching and upgrade software deployment
Mass Patch deployment possibility, so eliminates to patch individual Databases
Ensure Standardization within an enterprise
Minimize the impact and risk of maintenance
6. Rapid Home Provisioning – Wath's new in 12.2.
Oracle Rapid Home Provisioning 12.26 22.09.2017
Efficient out-of-place distribution
Manage existing 11.2 and 12.x deployments without any special configuration
Provision new clusters with a single command
Database and GI – Provisioning, Patching, Upgrade, Scale in one command
Deploy and manage any software home
Custom workflow framework (User defined Actions)
Clientless Provisioning
Provisioning Notification
Auditing capabilities
7. Rapid Home Provisioning – Main Components
Oracle Rapid Home Provisioning 12.27 22.09.2017
RHP Server
RHP Client
RHP Roles
RHP Images
RHP Workingcopies
ASM
ACFS
GNS
Management DB (GIMR)
10. Rapid Home Provisioning – Architecture Details
Oracle Rapid Home Provisioning 12.210 22.09.2017
RHP Server
Managemnt
Repository
(-MGMTDB)
Image RDBMS
(Gold Image)
Working
Copy 1
DB Home 1
Working
Copy 2
RHP
Client
RHP
Client
GNS Server
GI Home 1
DB Home 1 DB Home 1
RHP
Client
RHP
Client
GI Home 1 GI Home 1
Local Copy
RHP
Metadata
ACFS
Mount
Source:
RDBMS, GI,
3rd Party SW
Image GI
(Gold Image)
12. Rapid Home Provisioning – Basic Built-In Roles
Oracle Rapid Home Provisioning 12.212 22.09.2017
Role Name Description
GH_ROLE_ADMIN administrative role for everything related to roles
GH_SITE_ADMIN administrative role for everything related to Rapid Home Provisioning Clients
GH_SERIES_ADMIN administrative role for everything related to image series
GH_SERIES_CONTRIB Users assigned this role can add images to a series
GH_WC_ADMIN administrative role for everything related to working copies
GH_WC_OPER role that enables users to create a working copy for themselves or others
GH_WC_USER role that enables users to create a working copy
GH_IMG_ADMIN administrative role for everything related to images
GH_IMG_USER role that enables users to create an image
GH_IMG_TESTABLE role that enables users to add a working copy of an image that is in the TESTABLE state
GH_IMG_RESTRICT role that enables users to add a working copy from an image that is in the RESTRICTED state
GH_IMG_PUBLISH
Users assigned this role can promote an image to another state or retract an image from the
PUBLISHED state to either the TESTABLE or RESTRICTED state
GH_IMG_VISIBILITY Users assigned this role can modify access to promoted or published images
15. Rapid Home Provisioning – Prerequisites
Oracle Rapid Home Provisioning 12.215 22.09.2017
Rapid Home Provisioning is part of Grid Infrastructure (GI) 12c
– GI is mandatory for provision with RHP Oracle Restart not supported !
Deployments Works even in a "non" GI Cloud Environment !
– only for RDBMS and third Party SW !
Not supported on HP-UX and Windows Plattform
Does not manage OS Images
Provisioning based on ACFS Snapshot and NFS
GNS Server
NFS Daemon must be run on each Server provided by RHP
License
– Lifecycle Management Pack (12’000 $ / CPU Core)
17. RHP Setup – ASM and GNS Config
Oracle Rapid Home Provisioning 12.217 22.09.2017
ASM Diskgroup ACFS compatible parameter
Configure GNS Server adding following to DNS Record File
Add GNS to Cluster
alter diskgroup data set attribute 'compatible.advm'='12.1';
$ORIGIN rac.trivadis.com.
@ IN NS gns.rac.trivadis.com.
gns IN A 192.168.56.201
[root@sonic01 named]# /u01/app/12.2.0/grid/bin/srvctl add gns -domain
rac.trivadis.com -vip 192.168.56.201
[root@sonic01 named]# /u01/app/12.2.0/grid/bin/srvctl start gns
18. RHP Setup – Mountpoint Directory and add RHP Server
Oracle Rapid Home Provisioning 12.218 22.09.2017
On RHP Server
create a folder on all Cluster Member
Add Storage and start the RHP Server
[root@sonic01 app]# mkdir /rhpdir
[root@sonic01 app]# chown oracle:oinstall /rhpdir
/u01/app/12.2.0/grid/bin/srvctl add rhpserver -storage /rhpdir
-diskgroup DATA
/u01/app/12.2.0/grid/bin/srvctl start rhpserver
19. RHP Setup – Add Images
Oracle Rapid Home Provisioning 12.219 22.09.2017
Add Images to RHP Server (Example GI 12.2.0.x)
[oracle@sonic01 ~]$ rhpctl import image -image gi_12201_V0100 -path /u01/app/12.2.0/grid/ -imagetype
ORACLEGISOFTWARE -state TESTABLE
sonic02: Creating a new ACFS file system for image "gi_12201_V0100" ...
sonic02: Copying files...
sonic02: Copying home contents...
sonic02: Changing the home ownership to user oracle...
sonic01: Transferring data to 1 nodes
sonic01: 10% complete
sonic01: 20% complete
sonic01: 30% complete
sonic01: 40% complete
sonic01: 50% complete
sonic01: 60% complete
sonic01: 70% complete
sonic01: 80% complete
sonic01: 90% complete
sonic01: 100% complete
sonic02: Changing the home ownership to user oracle...
[oracle@sonic01 ~]$
20. RHP Setup – Add Images
Oracle Rapid Home Provisioning 12.220 22.09.2017
Add Images to RHP Server (Example RDBMS 12.2.0.x)
[oracle@sonic01 database]$ rhpctl import image -image rdbms_12201_V0100 -path
/u01/app/oracle/product/12.2.0/dbhome_1 -imagetype ORACLEDBSOFTWARE -state TESTABLE
sonic02: Creating a new ACFS file system for image "rdbms_12201_V0100" ...
sonic02: Copying files...
sonic02: Copying home contents...
sonic02: Changing the home ownership to user oracle...
sonic01: Transferring data to 1 nodes
sonic01: 10% complete
sonic01: 20% complete
sonic01: 30% complete
sonic01: 40% complete
sonic01: 50% complete
sonic01: 60% complete
sonic01: 70% complete
sonic01: 80% complete
sonic01: 90% complete
sonic01: 100% complete
sonic02: Changing the home ownership to user oracle...
[oracle@sonic01 database]$
21. RHP Setup – Add Images
Oracle Rapid Home Provisioning 12.221 22.09.2017
On Filesystem we will have such a situation:
Images are registered on RHP Server
[oracle@sonic01 ~]$ df -h
Filesystem Size Used Avail Use% Mounted on
/dev/sda3 37G 30G 5.9G 84% /
tmpfs 3.9G 1.3G 2.7G 32% /dev/shm
/dev/sda1 477M 116M 333M 26% /boot
/dev/asm/ghchkpt-387 5.0G 1.1G 4.0G 21% /rhp_dir/chkbase
/dev/asm/ghvol436136-387
18G 10G 8.1G 56% /rhp_dir/images/irdbms_12201_V0100635467
/dev/asm/ghvol427603-387
26G 12G 15G 45% /rhp_dir/images/igi_12201_V0100379214
[oracle@sonic01 ~]$ rhpctl query image
Image name: rdbms_12201_V0100
Image name: gi_12201_V0100
25. RHP Setup – Add Images
Oracle Rapid Home Provisioning 12.225 22.09.2017
available possibilities
– NFS (only for RDBMS Home)
• the path for RDBMS Home will be provided as NFS mount point
– Local
• The path will be provided in a local file system
– RHP Managed (NFS managed by RHP) default if it is possible !
• The path will stored in a ACFS shared file system
• Not usable for Grid Infrastructure Provisioning
[oracle@sonic01 database]$ rhpctl add workingcopy –rdbms_12201_WC02 -image rdbms_12201_V0100
–storagetype NFS
[oracle@sonic01 database]$ rhpctl add workingcopy –rdbms_12201_WC02 -image rdbms_12201_V0100
–storagetype RHP_MANAGED
[oracle@sonic01 database]$ rhpctl add workingcopy –rdbms_12201_WC02 -image rdbms_12201_V0100
–storagetype LOCAL
26. RHP Setup – Grid Infrastructure Provisioning
Oracle Rapid Home Provisioning 12.226 22.09.2017
Possible to install, configure, patch and upgrade
– for provisioning with configure you need to create a GI response file
Check where the working copy was provisioned
rhpctl add workingcopy -workingcopy gi_12201_wc01 -image gi_12201_V0100 -responsefile
/home/oracle/floyd.rsp -path /u01/app/12.2.0/grid -root
[oracle@sonic01 ~]$ rhpctl query workingcopy -workingcopy gi_12201_wc01
Working copy name: gi_12201_wc01
Image name: gi_12201_V0100
Groups configured in the working copy: OSDBA=asmdba,OSOPER=asmoper,OSASM=asmadmin
Owner: oracle@floyd
Site: floyd my cluster name
Access control: USER:oracle@floyd
Access control: USER:oracle@sonic
Access control: ROLE:GH_WC_ADMIN
Software home path: /u01/app/12.2.0/grid
Storage type: LOCAL provisioning storage type
Image Type: ORACLEGISOFTWARE
Software only: false
Gold image path:
Work path:
Cluster Name: floyd
Cluster Type: FLEX
Cluster Mode: FLEX
Cluster Class: STANDALONE
Cluster Nodes: sonic03,sonic04 my cluster member where it was provisioned Grid Infrastructure
All patches available in this home:
Additional patches compared to the image:
Additional bug fixes that are not in the image:
Complete: FALSE
27. RHP Setup – RDBMS Provisioning and create Database
Oracle Rapid Home Provisioning 12.227 22.09.2017
Possible to install, configure, patch and upgrade (same as on GI)
– for provisioning with configure you need to create a GI response file
Create a single instance database
– SYS and SYSTEM password will be setted randomly and to change afterward
rhpctl add workingcopy -workingcopy rdbms_12201_WC02 -image rdbms_12201_V0100 -path
/u01/app/oracle/product/12.2.0/dbhome_1 -oraclebase /u01/app/oracle -user oracle -client floyd
[oracle@sonic01 ~]$ rhpctl add database -workingcopy rdbms_12201_WC02 -dbname TVD01 -node sonic03 -
dbtype SINGLE -datafileDestination DATA
sonic03.trivadis.com: Starting database creation on node sonic03 ...
========================================
sonic03.trivadis.com:
SYS_PASSWORD_PROMPT
**********
SYSTEM_PASSWORD_PROMPT
*********
Registering database with Oracle Restart
5% complete
Copying database files
6% complete
36% complete
Creating and starting Oracle instance
57% complete
Completing Database Creation
68% complete
Executing Post Configuration Actions
100% complete
Look at the log file "/u01/app/oracle/cfgtoollogs/dbca/TVD01/TVD01.log" for further details.
28. RHP Setup –Provisioning of 3rd party Software
Oracle Rapid Home Provisioning 12.228 22.09.2017
Possible to install, configure, patch and upgrade it depends on your Action
Scripts !
– Depending on which kind of Software you want deploy and which action is needed for
installing and configuring you must create Action Scripts
Example deploying TVD-Basenv
– Action Script install-TVD-basenv.ksh starts the Basenv installer with responsefile and
execute the installation in silent mode
– Action should be executed as post action after Working Copy was deployed
Create a Imagetype based on type Software for TVD-Basenv
Create an Image for TVD-Basenv (Base SW was only copied not installed)
rhpctl add useraction -useraction Install-TVD-Basenv -actionscript /home/oracle/basenv/install-TVD-
basenv.sh -post -optype ADD_WORKINGCOPY -onerror ABORT
rhpctl add imagetype -imagetype TVD-Basenv-type -basetype SOFTWARE -useractions "Install-TVD-Basenv"
rhpctl import image -image TVD-Basenv-17.05 -path /home/oracle/basenv -imagetype TVD-Basenv-type
29. RHP Setup –Provisioning of 3rd party Software
Oracle Rapid Home Provisioning 12.229 22.09.2017
Deployment of TVD-Basenv with Working Copy
– The software will be copied to /home/oracle/basenv directory
– Due to the imagetype was adopted with an user action that should run as post deployment,
after the deployment the software will be installed
DEMO
rhpctl add workingcopy -workingcopy TVD-Basenv-17.05_WC01 -image TVD-Basenv-17.05 -path
/home/oracle/basenv -node sonic03 -user oracle -root
31. GIMR and RHP
Oracle Rapid Home Provisioning 12.231 22.09.2017
RHP Metadata are stored on GIMR (-MGMTDB)
-MGMTDB is a Container Database (CDB)
– Number of PDBs is depending on how many Options are installed
– All named GIMR_DSCREP_xx (DSCREP=Domain Service Cluster Repository)
RHP Schema is GHSUSER12201
SQL> show pdbs
CON_ID CON_NAME OPEN MODE RESTRICTED
---------- ------------------------------ ---------- ----------
2 PDB$SEED READ ONLY NO
3 GIMR_DSCREP_10 READ WRITE NO
SQL> select username from dba_users order by created
USERNAME
--------------------------------------------------------------------------------
...
GHSUSER12201
32. GIMR and RHP
Oracle Rapid Home Provisioning 12.232 22.09.2017
Interesting Tables with RHP Metadata
– Metadata for Imagecopies
– Metadata for Workingcopies
SQL> select name, SHARED,ONACFS,CLSITE from GHSUSER12201.SWHOMES;
NAME SHARED ONACFS CLSITE
-------------------- ---------- ---------- --------------------
gi_12201_wc01 0 0 floyd
rdbms_12201_WC01 1 0 sonic
rdbms_12201_WC02 0 0 floyd
rdbms_12201_WC03 0 0 STANDALONE_sonic05
tvd_be_1705_wc01 0 0 sonic
SQL> select name, M_ONACFS,STATE,HOME,IMGSIZE,COMPLETE,DBSOFTWARE_VERSION,IMGTYPE from GHSUSER12201.IMGS;
NAME M_ONACFS STATE HOME IMGSIZE COMPLETE DBSOFTWARE_VERSION IMGTYPE
-------------------- ---------- ---------- -------------------------------------------------- ---------- ---------- ------------------------- --------------------
rdbms_12201_V0100 1 TESTABLE /rhp_dir/images/irdbms_12201_V0100635467/swhome 7547764 1 12.2.0.1.0|false ORACLEDBSOFTWARE
gi_12201_V0100 1 TESTABLE /rhp_dir/images/igi_12201_V0100379214/swhome 12572268 1 12.2.0.1.0|false ORACLEGISOFTWARE
TVD-Basenv-17.05 1 PUBLISHED /rhp_dir/images/iTVD-Basenv-17.05442250/swhome 46564 1 12.2.0.1.0|false TVD-Basenv-type
34. Rapid Home Provisioning – Conclusion
Oracle Rapid Home Provisioning 12.234 22.09.2017
☺ Simple to set up
☺ nice built-in in Grid Infrastructure
☺ sufficient functionality for managing provisioning
☺ All tested scenarios worked as expected
☺ Thin Documentation
☺ GI_Home Provisioning
☺ Single Server Provisioning
☺ Cleanup of Metadata on MGMTDB works much better than with 12.1.x
No clear statement about needed space requirements
DB_Home via NFS is no more available when RHP Servers are down