Tip-of-the-week Cloning your oracle home

Topics about Databases, Backups, Tuning, Architecture, Systems Management, etc etc.

Post Reply
bgrenn
Posts: 91
Joined: Mon Mar 16, 2009 11:47 am
Location: Rochester, NY
Contact:

Tip-of-the-week Cloning your oracle home

Post by bgrenn »

Ever want to put down a new second copy of your oracle software that the current version PLUS an additional patch ? Maybe you want to test a patch, or make for quicker patch time.  Think you have to go through the installer and re-install the software, and put on the same patches ? Well you don't have to .. Just follow these steps..

1) As the root user, on each node in the cluster, copy the existing ORACLE_HOME to the new ORACLE_HOME location. (This requires no downtime.) For example:
cp –pr /u01/app/oracle/product/11.1.0.6 /u01/app/oracle/product/11.1.0.7
2. Validate that any file changes between the source ORACLE_HOME and the copied ORACLE_HOME are ok (only log files may differ): > diff -q -r /u01/app/oracle/product/11.1.0.6 /u01/app/oracle/product/11.1.0.7
3. As the OS user that owns the Oracle software, add the new ORACLE_HOME software to the Oracle Inventory using a cloning script. For example: #!/bin/sh echo "Clone started at `date`" | tee -a clone.log perl /u01/app/oracle/product/11.1.0.7/clone/bin/clone.pl ORACLE_HOME=/u01/app/oracle/product/11.1.0.7 ORACLE_HOME_NAME=11gR1P2 '-O"CLUSTER_NODES={chi01,chi02}"' '-O"LOCAL_NODE=chi01"' echo "Clone ended at `date`" | tee -a clone.log
4. As root user, run the root.sh script on each node.
5. Apply the patch set to the newly cloned ORACLE_HOME (/u01/app/oracle/product/11.1.0.7)
Post Reply