You are on page 1of 11

9/9/23, 11:18 PM Document 2054804.

PowerView is Off Parmanto (Available) Profile (0) Help


Time left:23:03:02

Knowledge RCA Customer Exceptions CMS Service Requests Advanced

Copyright (c) 2023, Oracle. All rights reserved. Oracle Confidential.

ODA (Oracle Database Appliance): How To Setup a Rapid Home Provisioning (RHP) Server and Client (Doc ID To Bottom
2054804.1)

In this Document Was this document helpful?

Goal Yes
No
Solution
Introduction
Document Details
Using Rapid Home Provisioning
GNS Setup on ODA
Creating a Rapid Home Provisioning Server Type:
HOWTO
ODA RHP Server: Create the Rapid Home Provisioning Server resource Status:
PUBLISHED
Distribution:
ODA RHP Server: Start the Rapid Home Provisioning Server resource EXTERNAL
Visibility:
EXTERNAL
ODA RHP Server: HA-VIP setup Last Major
Feb 10, 2020
Update:
ODA RHP Server: Create client data file Last Update:
Jun 4, 2023

RHP Client setup


Scenarios to Use Rapid Home Provisioning
Related Products
Adding Gold Images to the ODA Rapid Home Provisioning Server
Oracle Database Appliance
Database Home provisioning Oracle Database Appliance
Software
Database home provisioning (LOCAL)
Database home provisioning (NFS)
Information Centers
Database provisioning Information Center: Oracle
Switch to Managed Homes Database Appliance
[1417713.2]
Database Patching
インフォメーション・センタ
Standby Database Patching
ー: データベースおよび
ODA RHP Server Considerations Enterprise Manager 日本語ド
ODA DB Home patching キュメント [1946305.2]

Scenario - Steps to create a new PSU DB Home


Troubleshooting Document References
References ODA (Oracle Database
Appliance): Rapid Home
Provisioning (RHP) setup in "1-
APPLIES TO: Click" [2124322.1]

Oracle Database Appliance - Version All Versions to All Versions [Release All Releases]
Recently Viewed
Oracle Database Appliance Software - Version 12.1.2 and later
Information in this document applies to any platform. RHP (Rapid Home
Provisioning): mnttest tool to
test NFS 'export'
GOAL and 'mount'
functionalities [2167541.1]
To provide the steps to setup a Rapid Home Provisioning (RHP) Server on ODA (Oracle Database Appliance). Bug 29699562 - RHP: PRGO-
1618 During rhpctl Upgrade
Database [29699562.8]
SOLUTION Introduction to "Bug
Description" Articles
[245840.1]
Introduction Bug 31155138 - RHP
Changes For Grid Upgrade
Rapid Home Provisioning (RHP) represents a standard way for provisioning, patching and upgrading at organizational level, in a [31155138.8]
unified manner, across all architectural layers of software infrastructure – Oracle databases and custom software. Bug 34538325 - rhp move
gihome Hang For 2 Hours
Rapid Home Provisioning is a method of deploying software homes from single cluster where you create, store and [34538325.8]
manage templates of Oracle homes as images - called gold images - of Oracle software. The DBA can make a working Show More
copy of any gold image and then provision that working copy to any RHP Client in a data center.
RHP is installed as part of Grid Infrastructure, hence available out-of-the-box on ODA. Oracle Clusterware manages the  
components that form the Rapid Home Provisioning Server. These components include the RHP server itself, Grid Naming
Service (GNS) which is used to advertise the location of the RHP server, a VIP to support HA-NFS (required if there are
any clients that you want to provision to - whether you use NFS storage for the workingcopies or not) and Oracle ASM
Cluster File System (ACFS) which is used to store snapshots of the working copies.
The gold images represent an installed home, whether that is an Oracle Database software home or some custom
software home. The gold image is stored in an Oracle Automatic Software Management Cluster File System (Oracle
ACFS).
Metadata describing an installed home is stored as an image series in the Management Repository. The Management
Repository (or Management Database MGMTDB) is created when installing Oracle Grid Infrastructure.

https://myaccess.oraclevpn.com/+CSCO+0075676763663A2F2F7A6266727A632E68662E62656E7079722E70627A++/epmos/faces/Document… 1/11
9/9/23, 11:18 PM Document 2054804.1

Time left:23:03:02

Note: in order to provide an Oracle Home (workingcopy) to an RHP Client are needed about 60min if LOCAL, 30min if by
NFS (storagetype NFS). Many operations are needed like DBHome cloning, relink, etc.

Using the rhpctl utility, gold images can be imported from an installed home on ODA RHP server (Oracle Home created with
'oakcli create dbhome' command), or promoted from an installed home or working copy on any of the RHP clients.

An existing working copy can be promoted to a gold image.

A working copy is an instantiation of an Oracle database software home


Working copies are writable and independent of one another

Using RHP on ODA, we can provision Oracle DB software for the various versions

11.2.0.3 (Oracle Database 11g)


11.2.0.4 (Oracle Database 11g)
12.1.0.2 (Oracle Database 12c)
12.2.0.1 (Oracle Database 12c)

RHP does support more RDBMS versions, however the list above is related to the versions available for ODA as EndUser
RDBMS clone file.

It's recommended on ODA RHP Server to use GI (Grid Infrastructure) version 12.2.0.1_171017 or later.

Using Rapid Home Provisioning

Rapid Home Provisioning requires ASM, the Management DB and the Grid Naming Service (GNS). As part of the Grid
Infrastructure deploy on ODA

ASM is configured
The Management Repository (Management DB) is available. The Management DB is installed by default starting with
Oracle Grid Infrastructure 12.1.0.2

# $GRID_HOME/bin/srvctl status mgmtdb


Database is enabled
Instance -MGMTDB is running on node oda101

As the Management DB (MGMTDB) is doing a key role with the RHP, you should consider to setup a backup for it, in
particular for the schema: 'GHSUSER' (for example using expdp).
The size of it depends on the number of images, workingcopies, sites, users, etc.
In general, the size requirement is very low since we only store the metadata: for 100 images, 2000 workingcopies and 25
RHP Clients, our internal test showed a size of about 200 Mb only.

You need to configure the GNS such that a GNS VIP is provided. A GNS sub-domain is not required by RHP.

Note:
you could skip the manual steps to setup RHP Server using "setrhp" the "1-Click" utility described on Note:2124322.1 - ODA
(Oracle Database Appliance): Rapid Home Provisioning (RHP) setup in "1-Click"

GNS Setup on ODA

Execute the following command as root, providing a valid IP address (domain is not needed on RHP):

# $GRID_HOME/bin/srvctl add gns -vip <IP_address>

example:
# <GI_HOME>/bin/srvctl add gns -vip 10.xxx.51.63

https://myaccess.oraclevpn.com/+CSCO+0075676763663A2F2F7A6266727A632E68662E62656E7079722E70627A++/epmos/faces/Document… 2/11
9/9/23, 11:18 PM Document 2054804.1
# <GI_HOME>/bin/srvctl status gns
GNS is not running.
GNS is enabled. Time left:23:03:02
# <GI_HOME>/bin/srvctl config gns
GNS is enabled.
GNS VIP addresses: 10.xxx.51.63
Domain served by GNS: N_FWD

Note: currently the GNS setup is required on RHP Server only. We advertise to GNS the exact host and port where RHP
Server is running which is used by RHP Clients to connect to RHP Server.

Once the GNS is configured the Rapid Home Provisioning server can be configured.

Creating a Rapid Home Provisioning Server

The Rapid Home Provisioning Server uses an Oracle ACFS file system for Oracle database software homes that will be published
to clients.

To configure the Rapid Home Provisioning Server you will need to:

Provide an ASM diskgroup (DATA/RECO). It is recommended that this diskgroup is with at least 100Gb in free space. The
diskgroup is used to store gold images and RHP managed NFS-provisioned workingcopies.
Provide a mount path that exists on all nodes of the ODA RHP server. Oracle ACFS snapshots can be used to provision
server-local workingcopies or NFS-mounted workingcopies on clients.
Configure an HA VIP. The NFS client, on the RHP client clusters will communicate with the NFS server on the RHP server
over this IP address for NFS mounted homes. The VIP allows for the configuration of HANFS. Note that the HA VIP has to
be configured in the same subnet as the default network configured on the ODA RHP server.

As HANFS requires NFS in order to run. It is assumed that NFS (and its associated needs) will be started by init scripts at node
boot time. NFS will need to be running on both ODA nodes. We can check this on each node issuing:

# service rpcbind status


rpcbind (pid 13256) is running...

# service nfs status


rpc.mountd (pid 13858) is running...
nfsd (pid 13855 13854 13853 13852 13851 13850 13849 13848 13847 13846 13845 13844 13843 13842 13841
13840 13839 13838 13837 13836 13835 13834 13833 13832 13831 13830 13829 13828 13827 13826 13825 13824
13823 13822 13821 13820 13819 13818 13817 13816 13815 13814 13813 13812 13811 13810 13809 13808 13807
13806 13805 13804 13803 13802 13801 13800 13799 13798 13797 13796 13795 13794 13793 13792 13791 13790
13789 13788 13787 13786 13785 13784 13783 13782 13781 13780 13779 13778 13777 13776 13775 13774 13773
13772 13771 13770 13769 13768 13767 13766 13765 13764 13763 13762 13761 13760 13759 13758 13757 13756
13755 13754 13753 13752 13751 13750 13749 13748 13747 13746 13745 13744 13743 13742 13741 13740 13739
13738 13737 13736 13735 13734 13733 13732 13731 13730 13729 13728) is running...
rpc.rquotad (pid 13713) is running...

# service nfslock status


rpc.statd (pid 23372) is running...

If one of these is not running, you could start it by using (as root):

/etc/init.d/<service> status

The 'chkconfig' command can be used to ensure that these services are started at boot time

chkconfig nfs on
chkconfig rpcbind on
chkconfig nfslock on

Once the pre-requisites mentioned above have been met, the RHP server can be added to Grid Infrastructure and started.

ODA RHP Server: Create the Rapid Home Provisioning Server resource

Assuming DATA diskgroup usage, and '/rhp_storage' as ACFS mount point, issue the following command (as 'root' user):

# $GRID_HOME/bin/srvctl add rhpserver -storage <rhp_acfs-storage_path> -diskgroup <disk_group_name>

example:
<GI_HOME>/bin/srvctl add rhpserver -storage /rhp_storage -diskgroup DATA

Note: The storage path "/rhp_storage" is automatically created by srvctl

You can check the status for rhp server doing:

# $GRID_HOME/bin/srvctl status rhpserver


Rapid Home Provisioning Server is enabled
Rapid Home Provisioning Server is not running

On both ODA RHP Server nodes at this time, you have a new ACFS mount point:

[root@oda101 ~]# mount


(...)

https://myaccess.oraclevpn.com/+CSCO+0075676763663A2F2F7A6266727A632E68662E62656E7079722E70627A++/epmos/faces/Document… 3/11
9/9/23, 11:18 PM Document 2054804.1
/dev/asm/<DISK_1> on /rhp_storage/chkbase type acfs (rw)
Time left:23:03:02

ODA RHP Server: Start the Rapid Home Provisioning Server resource

Issue the following command (as 'root' user):

# $GRID_HOME/bin/srvctl start rhpserver

example:
[root@oda101 ~]# /u01/app/12.1.0.2/grid/bin/srvctl start rhpserver
[root@oda101 ~]# /u01/app/12.1.0.2/grid/bin/srvctl status rhpserver
Rapid Home Provisioning Server is enabled
Rapid Home Provisioning Server is running on node oda102

ODA RHP Server: HA-VIP setup

On the RHP server as the Grid Infrastructure owner determine if an HA-VIP has been created (as 'grid' user):

$ $GRID_HOME/bin/srvctl config havip


HAVIP exists: /rhphavip/10.xxx.51.64, network number 1
Description:
Home Node:
HAVIP is enabled.
HAVIP is individually enabled on nodes:
HAVIP is individually disabled on nodes:

If it's not configured, you need to issue the following command (as root):

# $GRID_HOME/bin/srvctl add havip -id id -address {host_name | ip_address}

example
[root@oda101 ~]# <GI_HOME>/bin/srvctl add havip -id rhphavip -address 10.xxx.51.64

ODA RHP Server: Create client data file

On RHP Server create the RHP client configuration file (as 'grid' user), RHPCTL creates the client data file in the directory path
you specify after the -toclientdata flag. The name of the client data file is "client_cluster_name".xml:

$GRID_HOME/bin/rhpctl add client -client <client_cluster_name> -toclientdata <path>

example:
[grid@oda101 ~]$ <GI_HOME>/bin/rhpctl add client -client odaremote1-c -toclientdata /home/grid
<HOSTNAME>: Creating client data ...
<HOSTNAME>: Client data created for user "odaremote-c".

[grid@oda101 ~]$ ls –al /home/grid/stormcloud-cluster.xml


-rw-r—-r-- 1 grid oinstall 3158 Oct 31 21:59 /home/grid/odaremote-c.xml

Note: to get the (RHP Client) cluster name (as grid user) issue the following command:
$GRID_HOME/bin/cemutlo -n

move the RHP Client config file created above to the RHP Client:

example:
[grid@oda101 ~]$ scp odaremote-c.xml root@odaremote1:/home/grid

At this time you should configure the RHP Client.

RHP Client setup

Perform the following actions on the RHP client cluster (as 'root' user):

1. Create the RHP client using the XML wallet created for this cluster
2. Start the RHP client.

$GRID_HOME/bin/srvctl add rhpclient –clientdata <path/rhpclient_configfile.xml>


$GRID_HOME/bin/srvctl start rhpclient

example:
[root@odaremote1 ~]# /u01/app/12.1.0.2/grid/bin/srvctl add rhpclient -clientdata /home/grid/odaremote-
c.xml
[root@odaremote1 ~]# /u01/app/12.1.0.2/grid/bin/srvctl status rhpclient
Rapid Home Provisioning Client is enabled
Rapid Home Provisioning Client is not running
[root@odaremote1 ~]# /u01/app/12.1.0.2/grid/bin/srvctl start rhpclient

The command “srvctl add rhpclient” has two optional arguments:

https://myaccess.oraclevpn.com/+CSCO+0075676763663A2F2F7A6266727A632E68662E62656E7079722E70627A++/epmos/faces/Document… 4/11
9/9/23, 11:18 PM Document 2054804.1

-diskgroup <dg_name> A disk group from which to create the ACFS file systems for image storage.
-storage <base_path> A location which is available on every cluster node and is not necessarily shared. Time left:23:03:02

This location does not need to exist during adding of Rapid Home Provisioning Client.
All images will be mounted on "<base_path>/images" for all local ACFS storage.

Scenarios to Use Rapid Home Provisioning

Adding Gold Images to the ODA Rapid Home Provisioning Server

Rapid Home Provisioning Server stores and serves gold images of software homes. These gold images must be instantiated on
the ODA Rapid Home Provisioning Server. Gold images are read-only, preventing a client from running programs from them. Gold
images are not used as software homes directly. Rather, the gold image is used to create working copies. These working copies
are usable as software homes on RHP Client.

The DBA can import software to the ODA Rapid Home Provisioning Server using any one of the following methods:

- Import a gold image from an installed home on the ODA Rapid Home Provisioning Server using the following command:

rhpctl import image -image <image name> -path <source oracle home path> -imagetype ORACLEDBSOFTWARE

- Import a gold image from an installed home on a Rapid Home Provisioning Client, using the following command run from the
RHP Client:

rhpctl import image –image <image name> –path <source oracle home path>

- Promote an existing workingcopy to a gold image using the following command:

rhpctl add image –image <image name> -workingcopy <workingcopy name>

As example, let's suppose you have created several Oracle homes (on ODA RHP Server) using the ODA command: 'oakcli create
dbhome'

# oakcli show dbhomes


Oracle Home Name Oracle Home version Home Location
---------------- ------------------- ------------
<DB_HOME_NAME>_home1 11.2.0.3.14(20299017,17592127) <DB_HOME>/dbhome_1
<DB_HOME_NAME>_home2 11.2.0.4.6(20299013) <DB_HOME>/dbhome_2
<DB_HOME_NAME>_home3 12.1.0.2..4(20831110,20831113) <DB_HOME>/dbhome_3

You could make them available as gold image issuing the following command (as 'grid' user):

example:
$ <GI_HOME>/bin/rhpctl import image -image <DB_HOME_NAME>_home1 -path <DB_HOME>/dbhome_1 -imagetype
ORACLEDBSOFTWARE
<HOSTNAME>: Creating a new ACFS file system for image "<DB_HOME_NAME>_home1" ...
<HOSTNAME>: Copying files...
<HOSTNAME>: Copying home contents...
<HOSTNAME>: Changing the home ownership to user oracle...
<HOSTNAME>: Transferring data to 1 nodes
<HOSTNAME>: 10% complete
<HOSTNAME>: 20% complete
<HOSTNAME>: 30% complete
<HOSTNAME>: 40% complete
<HOSTNAME>: 50% complete
<HOSTNAME>: 60% complete
<HOSTNAME>: 70% complete
<HOSTNAME>: 80% complete
<HOSTNAME>: 90% complete
<HOSTNAME>: 100% complete
<HOSTNAME>: Changing the home ownership to user grid...

$ <GI_HOME>/bin/rhpctl import image -image <DB_HOME_NAME>_home2 -path <DB_HOME>/dbhome_2 -imagetype


ORACLEDBSOFTWARE
<HOSTNAME>: Creating a new ACFS file system for image "<DB_HOME_NAME>_home2" ...
<HOSTNAME>: Copying files...
<HOSTNAME>: Copying home contents...
<HOSTNAME>: Changing the home ownership to user oracle...
<HOSTNAME>: Transferring data to 1 nodes
<HOSTNAME>: 10% complete
<HOSTNAME>: 20% complete
<HOSTNAME>: 30% complete
<HOSTNAME>: 40% complete
<HOSTNAME>: 50% complete
<HOSTNAME>: 60% complete
<HOSTNAME>: 70% complete
<HOSTNAME>: 80% complete
<HOSTNAME>: 90% complete
<HOSTNAME>: 100% complete

https://myaccess.oraclevpn.com/+CSCO+0075676763663A2F2F7A6266727A632E68662E62656E7079722E70627A++/epmos/faces/Document… 5/11
9/9/23, 11:18 PM Document 2054804.1
<HOSTNAME>: Changing the home ownership to user grid...

$ <GI_HOME>/bin/rhpctl import image -image <DB_HOME_NAME>_home3 -path <DB_HOME>/dbhome_3 -imagetype Time left:23:03:02
ORACLEDBSOFTWARE
<HOSTNAME>: Creating a new ACFS file system for image "<DB_HOME_NAME>_home3" ...
<HOSTNAME>: Copying files...
<HOSTNAME>: Copying home contents...
<HOSTNAME>: Changing the home ownership to user oracle...
<HOSTNAME>: Transferring data to 1 nodes
<HOSTNAME>: 10% complete
<HOSTNAME>: 20% complete
<HOSTNAME>: 30% complete
<HOSTNAME>: 40% complete
<HOSTNAME>: 50% complete
<HOSTNAME>: 60% complete
<HOSTNAME>: 70% complete
<HOSTNAME>: 80% complete
<HOSTNAME>: 90% complete
<HOSTNAME>: 100% complete
<HOSTNAME>: Changing the home ownership to user grid...

Note as at this time you will have three new ACFS filesystems (for every single rhpctl import command, a new ACFS mount point
will be created):

$ df -h
Filesystem Size Used Avail Use% Mounted on
(...)
/dev/asm/<DISK_1> 1.0G 141M 884M 14% /rhp_storage/images/chkbase
/dev/asm/ghvolxxx1
15G 5.2G 9.9G 35% /rhp_storage/images/i<DB_HOME_NAME>_home1673418
/dev/asm/ghvolxxx2
15G 5.2G 9.9G 35% /rhp_storage/images/i<DB_HOME_NAME>_home1977401
/dev/asm/ghvolxxx3
18G 5.9G 13G 33% /rhp_storage/images/i<DB_HOME_NAME>_home1267449

Database Home provisioning

The command rhpctl add workingcopy is used to provision an ORACLE_HOME for use by an Oracle database. This command can
be run on the RHP Server or on the RHP Client. If run on the RHP Server, the command can provision an Oracle database either
RHP-server-local or remotely on any RHP Client. When using the rhpctl command on the RHP Server, use the -client option to
specify the remote cluster.

- Create the mount point for the working copy on all nodes of the RHP Client

example:
[root@odaremote1 /]# mkdir -p /u01/rhp_base
[root@odaremote1 /]# chown -R oracle:oinstall /u01/rhp_base
[root@odaremote2 /]# mkdir -p /u01/rhp_base
[root@odaremote2 /]# chown -R oracle:oinstall /u01/rhp_base

Database home provisioning (LOCAL)

Usage: rhpctl add workingcopy -workingcopy <workingcopy_name> -image <image_name> [-oraclebase


<oraclebase_path>] [-path <where_path>] [-storagetype {NFS | LOCAL | RHP_MANAGED}] [-user <user_name>]
[-dbname <unique_db_name> [-dbtype {RACONENODE | RAC | SINGLE}] [-datafileDestination
<datafileDestination_path>] [-dbtemplate <file_path> | <image_name>:<relative_file_path>] {-node
<node_list> | -serverpool <pool_name> [-pqpool <pool_name> | -newpqpool <pool_name> -pqcardinality
<cardinality>] | -newpool <pool_name> -cardinality <cardinality> [-pqpool <pool_name> | -newpqpool
<pool_name> -pqcardinality <cardinality>]} [-cdb] [-pdbName <pdb_prefix> [-numberOfPDBs <pdb_count>]]]
[-client <cluster_name>] [-ignoreprereq]

-workingcopy <workingcopy_name> Name of the working copy to be created


-image <image_name> Image name from the configured images
-oraclebase <oraclebase_path> ORACLE_BASE path for provisioning Oracle
database home (Required only for ORACLEDBSOFTWARE image type)
-path <path> The absolute path for provisioning
software home (For database images, this will be the ORACLE_HOME)
-storagetype {NFS | LOCAL | RHP_MANAGED} Type of storage for the home
-user <user_name> Name of the user for whom the software
home is being provisioned
-dbname <unique_db_name> Name of database (DB_UNIQUE_NAME) to be
provisioned
-dbtype {RACONENODE | RAC | SINGLE} Type of database: RAC One Node or RAC or
Single Instance
-datafileDestination <datafileDestination_path> Data file destination location or ASM
disk group name
-dbtemplate <filepath> | <image_name>:<relative_file_path> Absolute file path for the template file
or relative path to the image home directory on Rapid Home Provisioning Server
-node <node_list> Comma-separated list of nodes on which
database will be created
-serverpool <pool_name> Existing server pool name
-newpool <pool_name> Server pool name for pool to be created
-cardinality <integer> Cardinality for new server pool
-pqpool <pool_name> Existing PQ pool name
-newpqpool <pool_name> PQ pool name for pool to be created
-pqcardinality <integer> Cardinality for new PQ pool
-cdb To create database as container database
-pdbName <pdb_prefix> The pdbName prefix if one or more PDBs
need to be created
-numberOfPDBs <pdb_count> Number of PDBs to be created

https://myaccess.oraclevpn.com/+CSCO+0075676763663A2F2F7A6266727A632E68662E62656E7079722E70627A++/epmos/faces/Document… 6/11
9/9/23, 11:18 PM Document 2054804.1
-client <cluster_name> Client cluster name
-ignoreprereq To ignore the CVU pre-requisite checks
Time left:23:03:02

Provide an Oracle Home to RHP Client available as "oracle" user making it available "locally" (as 'grid' user from RHP Server)

example:
[grid@oda101 ~]$ rhpctl add workingcopy -workingcopy WC_OraDb11204_home1 -image OraDb11204_home1 -
oraclebase /u01/rhp_base -client odaremote-c -user oracle

Note: the path defined by "-oraclebase" must be writable by the user defined by "-user" option

Creating a workingcopy, a new ACFS snapshot of the DB Home gold image will be created, example:

[root@oda101 ~]# acfsutil snap info /rhp_storage/images/i<DB_HOME_NAME>_home1977401


snapshot name: wWC_<DB_HOME_NAME>_home1
snapshot location:
/rhp_storage/images/i<DB_HOME_NAME>_home1977401/.ACFS/snaps/wWC_<DB_HOME_NAME>_home1
RO snapshot or RW snapshot: RW
parent name: /rhp_storage/images/i<DB_HOME_NAME>_home1977401
snapshot creation time: Tue Sep 8 00:58:57 2015

number of snapshots: 1
snapshot space usage: 1614921728 ( 1.50 GB )

Database home provisioning (NFS)

Provide an Oracle Home to RHP Client available as "oracle" user making it available by "NFS" (HA-NFS) (as 'grid' user from RHP
Server):

example:
[grid@oda101 ~]$ rhpctl add workingcopy -workingcopy WC_OraDb11204_home1 -image OraDb11204_home1 -
oraclebase /u01/rhp_base -client odaremote-c -storagetype NFS -user oracle

Database provisioning

Using RHP 'rhpcli add workingcopy', you can provide also a (RAC, RacOne, Single Instance) database (non-CDB, CDB).

Note: In case your RHP Client is an ODA (Oracle Database Appliance), it is not recommended to provision the database
using "rhpcli add workingcopy -dbname"
- there is no flexibilty on having the redologs file on REDO diskgroup (SSD) and the recovery files on RECO dg.
- the db template used is a generic template and not specialized for ODA
- special enhancements are done on ODA to store the database on ACFS filesystem

Switch to Managed Homes

A DBA can switch databases from an Oracle home that was not provisioned using Rapid Home Provisioning (unmanaged Oracle
home) to an Oracle home provisioned and managed by ODA Rapid Home Provisioning Server.

Assume the following:

Oracle Home installed at /<DB_HOME>/dbhome4 (currently an unmanaged home) on an RHP client cluster named
odaremote. This home has one or more databases created from it.
A gold image named <DB_NAME4> is managed by the RHP server.
(Optionally) the gold image <DB_NAME4> has a working copy named <DB_HOME>/dbhome_4 created on the client
cluster odaremote from it.

Example:

RHP Client

[root@odaremote ~]# oakcli show databases


Name Type Storage HomeName HomeLocation Version
----- ------ -------- -------------- ---------------- ----------
<D_NAME4> SINGLE ACFS <DB_HOME_NAME>_home4 <DB_HOME>/dbhome_4 12.1.0.2.4(20831110,20831113)

----------------------------------------------------------------------------
ODA RHP Server

[grid@oda101 ~]$ rhpctl query image


Image name: OraDb11203_home1
Image name: OraDb11204_home1
Image name: OraDb12102_home1

[grid@oda101 ~]$ rhpctl query workingcopy


Working copy name: WC_OraDb11203_home1
Working copy name: WC_OraDb11204_home1
Working copy name: WC_OraDb12102_home1

[grid@oda101 ~]$ rhpctl move database -sourcehome <DB_HOME>/dbhome_4 -client odaremote-c -patchedwc
WC<DB_NAME>_home4 -dbname odasdb

----------------------------------------------------------------------------
RHP Client

https://myaccess.oraclevpn.com/+CSCO+0075676763663A2F2F7A6266727A632E68662E62656E7079722E70627A++/epmos/faces/Document… 7/11
9/9/23, 11:18 PM Document 2054804.1
[root@odaremote ~]# oakcli show databases
Name Type Storage HomeName HomeLocation
Version Time left:23:03:02
----- ------ -------- -------------- ---------------- ------
----
<DB_NAME4> SINGLE ACFS WC_<DB_HOME_NAME>_home1 /rhp_oracle_home/product/12.1.0.2/WC_<DB_HOME>_home4
12.1.0.2.4(20831110,20831113)

Note: Moving a RAC database from un-managed Oracle Home to an RHP managed Oracle Home by default will be done in rolling
mode

Database Patching

Similar to the above scenario, patching involves moving a database from one workingcopy to a new patched workingcopy.

Workingcopies are independent and multiple workingcopies can be created from the same gold image.
A typical scenario would involve creating an initial workingcopy from a base release. As new patches, PSUs are a good example,
get released create a new workingcopy from your current gold image and apply the PSU.
The latest workingcopy would be promoted as a new gold image from which new databases are created. Existing databases can
then be moved to this latest gold image (which contains the current PSU).
This maintains a lineage of homes, allows for reverting to an older home if necessary, and keeps databases up to date, with
regard to PSU application.

Assume you are moving all databases from a workingcopy named wcDB12PSU1 to a workingcopy named wcDB12PSU2, you
would issue the command:

rhpctl move database -sourcewc wcDB12PSU1 -patchedwc wcDB12PSU2 –image DBIMGPSU2

This command creates a new ORACLE_HOME based on the patched image, if it does not exist, and then switches all Oracle
databases from their current ORACLE_HOME location to the new ORACLE_HOME.

By default, patching is performed in a rolling mode. Use the -nonrolling option to perform patching in non-rolling mode. The
database is then completely stopped on the old ORACLE_HOME, and is then restarted using the newly patched ORACLE_HOME.

For databases versions 12.1.0.1 or higher, the command rhpctl move database also executes any SQL commands required for
database patching. For database versions earlier than Oracle Database 12c Release 1, a message is displayed asking the user to
run the SQL commands for database patching manually. If only a specific database is to have its ORACLE_HOME moved, include
the -dbname switch:

rhpctl move database -sourcewc wcDB12PSU1 -patchedwc wcDB12PSU2 -dbname myDB

Standby Database Patching

Similar to the above scenario, standby database patching involves moving a database oracle home from one workingcopy to a
new patched workingcopy without applying any dictionary patch.

On ODA RHP Client a standby database is running under 12.1.0.2.0:

# oakcli show databases


Name Type Storage HomeName
HomeLocation Version
----- ------ -------- -------------- ---------------
- ----------
STDBY SINGLE ACFS <DB_HOME_NAME>_home3 <DB_HOME>/dbhome_3 12.1.0.2.0

From the ODA RHP Server provide a new OH 12.1.0.2.3 (as 'grid' user):

rhpctl add workingcopy -workingcopy WC_OraDb121023_home1 -image OraDb121023_home1 -oraclebase


/rhp_oracle_home -client odaremote-c -storagetype NFS -user oracle

Now, on ODA RHP Client a new OH 12.1.0.2.3 is show:

# oakcli show dbhomes


Oracle Home Name Oracle Home version Home Location
---------------- ------------------- ------------
<DB_HOME_NAME>_home3 12.1.0.2.0 <DB_HOME>/dbhome_3
WC_<DB_HOME_NAME>_home4 12.1.0.2.3(20299023) <DB_HOME>/WC_<DB_HOME_NAME>_home4

At this point we can move the remote standby from binaries 12.1.0.2.0 to 12.1.0.2.3 (patch the standby OH), as 'grid' user:

rhpctl move database -sourcehome <DB_HOME>/dbhome_3 -client odaremote-c -patchedwc


WC_<DB_HOME_NAME>_home3 -dbname STDBY

The STDBY database is now attached to the new OH provided above:

# oakcli show databases


Name Type Storage HomeName HomeLocation
Version
----- ------ -------- -------------- ---------------- -
---------
STDBY SINGLE ACFS WC_<DB_HOME_NAME>_home4 <DB_HOME>/WC_<DB_HOME_NAME>_home4
12.1.0.2.3(20299023)

Note: Rapid Home Provisioning is Standby Database aware. The standby database will be in mount state, no db dictionary
patches are applied (as part of PSU) waiting them by redo shipping from the primary DB.

https://myaccess.oraclevpn.com/+CSCO+0075676763663A2F2F7A6266727A632E68662E62656E7079722E70627A++/epmos/faces/Document… 8/11
9/9/23, 11:18 PM Document 2054804.1

ODA RHP Server Considerations


Time left:23:03:02
On ODA you can create new Database Home in very simple/fast way, within one command, using

Usage:
oakcli create dbhome [-version <version>]

where:
version - Version information for creating the database home. If not provided create the database home
from latest available bits.

In case you need different DBHome version you can get them from the End-User RDBMS Clone files

- End User RDBMS Clone file for 12.1.0.2 database home (PSU X, x=1-4)- Patch 19520042
Release Oracle Appliance Kit 12.1.2.4.0 --> (PSU 4)
Release Oracle Appliance Kit 12.1.2.3.0 --> (PSU 3)
Release Oracle Appliance Kit 12.1.2.2.0 --> (PSU 2)
Release Oracle Appliance Kit 12.1.2.1.0 --> (PSU 1)
Release Oracle Appliance Kit 12.1.2.0.0 --> (DB Home 12.1.0.2.0)

- End User RDBMS Clone file for 11.2.0.4 database home (PSU X, x=1-7)- Patch 17770873
Release Oracle Appliance Kit 12.1.2.4.0 --> (PSU 7)
Release Oracle Appliance Kit 12.1.2.3.0 --> (PSU 6)
Release Oracle Appliance Kit 12.1.2.2.0 --> (PSU 5)
Release Oracle Appliance Kit 12.1.2.1.0 --> (PSU 4)
Release Oracle Appliance Kit 12.1.2.0.0 --> (PSU 3)
Release Oracle Appliance Kit 2.10.0.0.0 --> (PSU 2)
Release Oracle Appliance Kit 2.9.0.0.0 --> (PSU 1)
Release Oracle Appliance Kit 2.8.0.0.0 --> (DB Home 11.2.0.4.0)

- End User RDBMS Clone file for 11.2.0.3 database home (PSU X, x=4-15)- Patch 14777276
Release Oracle Appliance Kit 12.1.2.4.0 --> (PSU 15)
Release Oracle Appliance Kit 12.1.2.3.0 --> (PSU 14)
Release Oracle Appliance Kit 12.1.2.2.0 --> (PSU 13)
Release Oracle Appliance Kit 12.1.2.1.0 --> (PSU 12)
Release Oracle Appliance Kit 12.1.2.0.0 --> (PSU 11)
Release Oracle Appliance Kit 2.10.0.0.0 --> (PSU 10)
Release Oracle Appliance Kit 2.9.0.0.0 --> (PSU 9)
Release Oracle Appliance Kit 2.8.0.0.0 --> (PSU 8)
Release Oracle Appliance Kit 2.7.0.0.0 --> (PSU 7)
Release Oracle Appliance Kit 2.6.0.0.0 --> (PSU 6)
Release Oracle Appliance Kit 2.5.0.0.0 --> (PSU 5)
Release Oracle Appliance Kit 2.4.0.0.0 --> (PSU 4)

- End User RDBMS Clone file for 11.2.0.2 database home (PSU X, x=7-12)- Patch 14349293
Release Oracle Appliance Kit 2.8.0.0.0 --> (PSU 12)
Release Oracle Appliance Kit 2.7.0.0.0 --> (PSU 11)
Release Oracle Appliance Kit 2.6.0.0.0 --> (PSU 10)
Release Oracle Appliance Kit 2.5.0.0.0 --> (PSU 9)
Release Oracle Appliance Kit 2.4.0.0.0 --> (PSU 8)
Release Oracle Appliance Kit 2.3.0.0.0 --> (PSU 7)

Note: you can use the End-User RDBMS Clone files created for an "early" Oracle Appliance Kit release on a "late" Oracle
Appliance version, in example End User RDBMS Clone file for 11.2.0.2.7 (Release Oracle Appliance Kit 2.3.0.0.0 ) on ODA
running with oak version 12.1.2.4.0

Once you have the new Database Homes you can create the RHP "Gold Images" and the working copys

ODA DB Home patching

If you need to patch a given oracle home with a new PSU, you could use the oak command:

oakcli update -patch <version> --database

and after you should make the updated "local oracle home" available as gold image importing it with the rhpcli command:

example:
rhpctl import image -image <DB_HOME_NAME>.15_home1 -path <DB_HOME>/dbhome_1 -imagetype ORACLEDBSOFTWARE

then you can make it as new workingcopy (in the above example 11.2.0.4.15) DB Home

Scenario - Steps to create a new PSU DB Home

Example:
- There is a source DB Home 112046 and the related Gold Image:

# oakcli show dbhomes


Oracle Home Name Oracle Home version Home Location
---------------- ------------------- ------------
<DB_HOME_NAME>_home2 11.2.0.4.6(20299013) <DB_HOME>/dbhome_2

[grid@oda101 ~]$ rhpctl query image


Image name: <DB_HOME_NAME>_home1
Image name: <DB_HOME_NAME>_home2
Image name: <DB_HOME_NAME>_home3

https://myaccess.oraclevpn.com/+CSCO+0075676763663A2F2F7A6266727A632E68662E62656E7079722E70627A++/epmos/faces/Document… 9/11
9/9/23, 11:18 PM Document 2054804.1
- A new PSU is coming (PSU7 --> 11.2.0.4.7 through the ODA Bundle Patch 12.1.2.5.0)
- Create a local working copy, local to ODA RHP Server (fast step as we are leveraging on ACFS snapshot) Time left:23:03:02

$ rhpctl add workingcopy -workingcopy WC_local_<DB_HOME_NAME>_home2 -image <DB_HOME_NAME>_home2 -


oraclebase /rhp_oracle_home -user oracle

# oakcli show dbhomes


Oracle Home Name Oracle Home version Home Location
---------------- ------------------- ------------
<DB_HOME_NAME>_home2 11.2.0.4.6(20299013) <DB_HOME>/dbhome_2
WC_lcal_<DB_HOME_NAME>_home2 11.2.0.4.6(20299013)
/rhp_storage/images/i<DB_HOME_NAME>_home1977401/.ACFS/snaps/wWC_Local_<DB_HOME_NAME>_home2/swhome

- Using oakcli patch the new local working copy (WC_Local_<DB_HOME_NAME>_home2)

# oakcli update -patch 12.1.2.5.0 --database

(...)
Found the following 11.2.0.4 homes possible for patching:

HOME_NAME HOME_LOCATION
--------- -------------
WC_Local_<DB_HOME_NAME>_home2
/rhp_storage/images/images/i<DB_HOME_NAME>_home1977401/.ACFS/snaps/wWC_Local_<DB_HOME_NAME>_home2/swhome
<DB_HOME_NAME>_home2 <DB_HOME_NAME>/dbhome_2

[Please note that few of the above database homes may be already up-to-date. They will be automatically
ignored]

Would you like to patch all the above homes: Y | N ? :n


Please enter the comma separated list of database home_names that you do NOT want to
patch:OraDb11204_home1
(...)
INFO: 2015-09-11 07:49:07: Applying the patch on oracle home:
/rhp_storage/images/images/iOraDb11204_home1977401/.ACFS/snaps/wWC_Local_OraDb11204_home1/swhome
(...)
SUCCESS: 2015-09-11 07:54:12: Successfully applied the patch on home
/rhp_storage/images/images/iOraDb11204_home1977401/.ACFS/snaps/wWC_Local_OraDb11204_home1/swhome
(...)
 

# oakcli show dbhomes


Oracle Home Name Oracle Home version Home Location
---------------- ------------------- ------------
<DB_HOME_NAME>_home2 11.2.0.4.6(20299013) <DB_HOME>/dbhome_2
WC_lcal_<DB_HOME_NAME>_home2 11.2.0.4.7
/rhp_storage/images/i<DB_HOME_NAME>_home1977401/.ACFS/snaps/wWC_Local_<DB_HOME_NAME>_home2/swhome

- Create a new Gold Image from the local working copy

rhpctl import image -image <DB_HOME_NAME>_home2 -


path /rhp_storage/images/iOra<DB_HOME_NAME>_home1977401/.ACFS/snaps/wWC_Local_<DB_HOME_NAME>_home2/swhome
-imagetype ORACLEDBSOFTWARE
 

You can now provide a new 11.2.0.4.7 workingcopy (to the RHP Client) using the new gold image
<DB_HOME_NAME>_home2 created above

example:
[grid@oda101 ~]$ rhpctl add workingcopy -workingcopy WC_<DB_HOME_NAME>_home2 -image
<DB_HOME_NAME>_home2 -oraclebase /rhp_base -client odaremote-c -storagetype NFS -user oracle

Troubleshooting

- The RHP Server logs are located at the following location:

<oracle_base>/crsdata/<node_name>/rhp

- The RHP Client logs are located at the following location:

<gihome>/oc4j/j2ee/home/log/gh*.log

- In order to investigate what an srvctl command is doing:

export SRVM_TRACE=TRUE ; SRVCTL_TRACEFILE=/tmp/srv.trc

Depending on the nature of the error, enable additional tracing by defining SRVM_NATIVE_TRACE=TRUE and
SRVM_JNI_TRACE=TRUE. This will produce additional jni trace information and is helpful to isolate issue in the jni layer.

REFERENCES

http://www.oracle.com/technetwork/database/database-cloud/private/rapid-home-provisioning-2405191.pdf
https://docs.oracle.com/database/121/CWADD/rapidhome.htm#CWADD92402
NOTE:2124322.1 - ODA (Oracle Database Appliance): Rapid Home Provisioning (RHP) setup in "1-Click"
Didn't find what you are looking for? Ask in Community...

Related
Products

https://myaccess.oraclevpn.com/+CSCO+0075676763663A2F2F7A6266727A632E68662E62656E7079722E70627A++/epmos/faces/Docume… 10/11
9/9/23, 11:18 PM Document 2054804.1

Sun Microsystems > Specialized Systems > Database Systems > Oracle Database Appliance > Miscellaneous > Other
Oracle Database Products > Appliance > Database Appliance > Oracle Database Appliance Software > Appliance Manager > Appliance CLI Time left:23:03:02

Knowledge Categories

PLA-Support > Database > DB Foundation > ODA > DB: ODA_EST ( Primary )
KB Review > KB Review.Reviewed-Fixed

Document Attributes
Author: RCITTON.IT; Status: PUBLISHED(EXTERNAL)
Owner: RCITTON.IT Publisher: KBRANDAU.US
Alias: Content Type: TEXT/X-HTML
Distribution: EXTERNAL Visibility: EXTERNAL
Created By: RCITTON.IT Created: Sep 11, 2015
Modified By: JGRAMLIN.US Modified: Jun 4, 2023
Reviewed By: KBRANDAU.US Reviewed: Sep 9, 2023
Source: AWIZ Exception: No
Priority: 3

Comments
Edit Comment Type Status Priority From To
My Oracle Support Feedback Customer Feedback REJECTED 3 CUSTFEED.WW OWNER

Back to Top

Copyright (c) 2023, Oracle. All rights reserved. Legal Notices and Terms of Use Privacy Statement

https://myaccess.oraclevpn.com/+CSCO+0075676763663A2F2F7A6266727A632E68662E62656E7079722E70627A++/epmos/faces/Docume… 11/11

You might also like