Tuesday, 15 July 2014

Oracle EBS Rel.12 Rapid Cloning from Dual Node to Dual Node


This article focus on making an Oracle EBS Release 12 clone from dual node source to dual node target.

Prerequisite

DB NODE WORKING

1)       locate adautocfg.sh
2)       cd /opt/oracle/db/tech_st/11.1.0/appsutil/scripts/PROD_prodapps/
3)       ./adautocfg.sh
4)       Enter apps user password.
5)       locate adpreclone.pl
6)       cd /opt/oracle/db/tech_st/11.1.0/appsutil/scripts/PROD_prodapps/
7)       perl adpreclone.pl dbTier
8)       enter apps user password .
APPS NODE WORKING
9)       cd /opt/oracle/inst/apps/PROD_prodapps/admin/scripts/
10)    ./adautocfg.sh
11)    Enter apps user password.
12)    locate adpreclone.pl
13)    cd /opt/oracle/db/tech_st/11.1.0/appsutil/scripts/PROD_prodapps/
14)    perl adpreclone.pl appsTier
15)    enter apps user password .

Copy Backups From Production To Test Location:
1.        GOTO Production Node through VNC Viewer
2.        Open Terminal
3.        Go to Backup folder Execute cd /Backup/
4.        Ls to see the backup files we want to copy to test
5.        Scp –r <Backup File Name (tar.gz)> oracle@<IP Address of TEST MACHINE>:/<Folder Name (Backup)> /
6.        Use the same command to copy all the db files.
7.        Use the same process for Application Server.
8.        Now open test server through VNC Viewer
9.        First make sure space availability
10.     Go to root cd /
11.     Execute df –h
12.     Make sure enugh space available otherwise make space by removing old unnecessary files and folders
13.     Rm –rf <folder/filename>
14.     Go to the location where files were copied like /Backup/ folder
15.     Execute command tar –xzf <File Name> to extract the files ( tar -xzf PROD_BACKUP_09_JAN_12.tar.gz  )

REMOVE Existing Clone
1.        First down the services on Appliction Server NODE Then on DB node
2.        Restart both nodes
3.        First go to the folder where Application Server is installed
4.        Remove folder like rm –rf u01
5.        GO to DB node
6.        Identify the oracle folder
7.        Remove the folder rm –rf oracle

.adcfgclone.pl


FEW CHECKS BEFORE adcfgclone.pl command:


Check the PERL5LIB enviornment variable with the command: which PERL5LIB or echo $PERL5LIB It should point towards perl folders otherwise set with the below mentioned command:



export PERL5LIB= /<YOUR SPECIFIC PATH >/oracle/product/11.2.0/perl/lib/5.10.0:/<YOUR SPECIFIC PATH >/oracle/product/11.2.0/perl/lib/site_perl/5.10.0:/<YOUR SPECIFIC PATH>/oracle/product/11.2.0/appsutil/perl


set the path to perl/bin if adcfgclone command donot work.

export PATH=/....../u02/oracle/PROD/db/tech_st/11.2.3/perl/bin/:$PATH


DBTIER
[oracle@r12apps /]$ su
Password:
[root@r12apps /]# chown -R oracle:oinstall /opt/oracle
[root@r12apps /]# chmod -R 777 /opt/oracle
[root@r12apps /]# exit
exit
[oracle@r12apps /]$ ./opt/oracle/PROD/db/tech_st/11.2.3/PROD_prodapps.env
[oracle@r12apps /]$ cd /opt/oracle/PROD/db/tech_st/11.2.3/appsutil/clone/bin/
[oracle@r12apps bin]$ perl adcfgclone.pl dbTier

                     Copyright (c) 2002 Oracle Corporation
                        Redwood Shores, California, USA

                        Oracle Applications Rapid Clone

                                 Version 12.0.0

                      adcfgclone Version 120.31.12010000.12

Enter the APPS password : _

Running:
/opt/oracle/PROD/db/tech_st/11.2.3/appsutil/clone/bin/../jre/bin/java -Xmx600M -cp /opt/oracle/PROD/db/tech_st/11.2.3/appsutil/clone/jlib/java:/opt/oracle/PROD/db/tech_st/11.2.3/appsutil/clone/jlib/xmlparserv2.jar:/opt/oracle/PROD/db/tech_st/11.2.3/appsutil/clone/jlib/ojdbc5.jar oracle.apps.ad.context.CloneContext -e /opt/oracle/PROD/db/tech_st/11.2.3/appsutil/clone/bin/../context/db/CTXORIG.xml -validate -pairsfile /tmp/adpairsfile_11486.lst -stage /opt/oracle/PROD/db/tech_st/11.2.3/appsutil/clone  2> /tmp/adcfgclone_11486.err; echo $? > /tmp/adcfgclone_11486.res

Log file located at /opt/oracle/PROD/db/tech_st/11.2.3/appsutil/clone/bin/CloneContext_0606095009.log

Provide the values required for creation of the new Database Context file.

Target System Hostname (virtual or normal) [r12apps] : _

Target Instance is RAC (y/n) [n] :  _

Target System Database SID : PROD

Target System Base Directory : /opt/oracle/PROD
In case of four folders: u02/oracle/PROD

Target System utl_file_dir Directory List : /opt/oracle/PROD/db/tech_st/11.2.3/appsutil/

Number of DATA_TOP's on the Target System [1] :_

Target System DATA_TOP Directory 1 [/opt/oracle/proddata] :_

Target System RDBMS ORACLE_HOME Directory [/opt/oracle/PROD/db/tech_st/11.2.0] : /opt/oracle/PROD/db/tech_st/11.2.3

Do you want to preserve the Display [prodapps:0.0] (y/n)  : n

Do you want the the target system to have the same port values as the source system (y/n) [y] ? : { REFER NOTE BELOW }

--------------------------------------------------------------------------------------------

NOTE: If you want to use the same port values as the current production instance press y if you want to give a different port other than your production instance then press n and select the port number 
For Example if you want to use 1525 then press 4 it will add 4 in default port 1521
--------------------------------------------------------------------------------------------



Complete port information available at /opt/oracle/PROD/db/tech_st/11.2.3/appsutil/clone/bin/out/PROD_r12apps/portpool.lst

Backing up /opt/oracle/PROD/db/tech_st/11.2.3/appsutil/PROD_r12apps.xml to /opt/oracle/PROD/db/tech_st/11.2.3/appsutil/PROD_r12apps.xml2.bak

Creating the new Database Context file from :
  /opt/oracle/PROD/db/tech_st/11.2.3/appsutil/template/adxdbctx.tmp

The new database context file has been created :
  /opt/oracle/PROD/db/tech_st/11.2.3/appsutil/PROD_r12apps.xml

Log file located at /opt/oracle/PROD/db/tech_st/11.2.3/appsutil/clone/bin/CloneContext_0606095009.log
Check Clone Context logfile /opt/oracle/PROD/db/tech_st/11.2.3/appsutil/clone/bin/CloneContext_0606095009.log for details.

Running Rapid Clone with command:
perl /opt/oracle/PROD/db/tech_st/11.2.3/appsutil/clone/bin/adclone.pl java=/opt/oracle/PROD/db/tech_st/11.2.3/appsutil/clone/bin/../jre mode=apply stage=/opt/oracle/PROD/db/tech_st/11.2.3/appsutil/clone component=dbTier method=CUSTOM dbctxtg=/opt/oracle/PROD/db/tech_st/11.2.3/appsutil/PROD_r12apps.xml showProgress contextValidated=true
Running:
perl /opt/oracle/PROD/db/tech_st/11.2.3/appsutil/clone/bin/adclone.pl java=/opt/oracle/PROD/db/tech_st/11.2.3/appsutil/clone/bin/../jre mode=apply stage=/opt/oracle/PROD/db/tech_st/11.2.3/appsutil/clone component=dbTier method=CUSTOM dbctxtg=/opt/oracle/PROD/db/tech_st/11.2.3/appsutil/PROD_r12apps.xml showProgress contextValidated=true
APPS Password :

Beginning database tier Apply - Fri Jun  6 09:52:07 2014

/opt/oracle/PROD/db/tech_st/11.2.3/appsutil/clone/bin/../jre/bin/java -Xmx600M -DCONTEXT_VALIDATED=true  -Doracle.installer.oui_loc=/opt/oracle/PROD/db/tech_st/11.2.3/oui -classpath /opt/oracle/PROD/db/tech_st/11.2.3/appsutil/clone/jlib/xmlparserv2.jar:/opt/oracle/PROD/db/tech_st/11.2.3/appsutil/clone/jlib/ojdbc5.jar:/opt/oracle/PROD/db/tech_st/11.2.3/appsutil/clone/jlib/java:/opt/oracle/PROD/db/tech_st/11.2.3/appsutil/clone/jlib/oui/OraInstaller.jar:/opt/oracle/PROD/db/tech_st/11.2.3/appsutil/clone/jlib/oui/ewt3.jar:/opt/oracle/PROD/db/tech_st/11.2.3/appsutil/clone/jlib/oui/share.jar:/opt/oracle/PROD/db/tech_st/11.2.3/appsutil/clone/jlib/oui/srvm.jar:/opt/oracle/PROD/db/tech_st/11.2.3/appsutil/clone/jlib/ojmisc.jar   oracle.apps.ad.clone.ApplyDBTier -e /opt/oracle/PROD/db/tech_st/11.2.3/appsutil/PROD_r12apps.xml -stage /opt/oracle/PROD/db/tech_st/11.2.3/appsutil/clone   -showProgress
APPS Password : Log file located at /opt/oracle/PROD/db/tech_st/11.2.3/appsutil/log/PROD_r12apps/ApplyDBTier_06060952.log
  /     15% completed      

Completed Apply...
Fri Jun  6 09:55:09 2014

Starting database listener for PROD:
Running:
/opt/oracle/PROD/db/tech_st/11.2.3/appsutil/scripts/PROD_r12apps/addlnctl.sh start PROD
Logfile: /opt/oracle/PROD/db/tech_st/11.2.3/appsutil/log/PROD_r12apps/addlnctl.txt

You are running addlnctl.sh version 120.1.12010000.4


Starting listener process PROD ...


Listener PROD has already been started.


addlnctl.sh: exiting with status 0

addlnctl.sh: check the logfile /opt/oracle/PROD/db/tech_st/11.2.3/appsutil/log/PROD_r12apps/addlnctl.txt for more information ... 

[oracle@r12apps bin]$

APPSTIER
[oracle@r12apps ~]$ . /opt/oracle/PROD/apps/apps_st/appl//APPSPROD_prodapps.env
[oracle@r12apps ~]$ cd /opt/oracle/PROD/apps/apps_st/comn/clone/bin/
[oracle@r12apps bin]$ perl adcfgclone.pl appsTier

                     Copyright (c) 2002 Oracle Corporation
                        Redwood Shores, California, USA

                        Oracle Applications Rapid Clone

                                 Version 12.0.0

                      adcfgclone Version 120.31.12010000.12

Enter the APPS password : __

Running:
/opt/oracle/PROD/apps/apps_st/comn/clone/bin/../jre/bin/java -Xmx600M -cp /opt/oracle/PROD/apps/apps_st/comn/clone/jlib/java:/opt/oracle/PROD/apps/apps_st/comn/clone/jlib/xmlparserv2.jar:/opt/oracle/PROD/apps/apps_st/comn/clone/jlib/ojdbc14.jar oracle.apps.ad.context.CloneContext -e /opt/oracle/PROD/apps/apps_st/comn/clone/bin/../context/apps/CTXORIG.xml -validate -pairsfile /tmp/adpairsfile_17077.lst -stage /opt/oracle/PROD/apps/apps_st/comn/clone  2> /tmp/adcfgclone_17077.err; echo $? > /tmp/adcfgclone_17077.res

Log file located at /opt/oracle/PROD/apps/apps_st/comn/clone/bin/CloneContext_0606095954.log

Provide the values required for creation of the new APPL_TOP Context file.

Target System Hostname (virtual or normal) [r12apps] : _

Target System Database SID : PROD

Target System Database Server Node [r12apps] : _<DB NODE PATH>

Target System Database Domain Name [usdenim] : _

Target System Base Directory : /opt/oracle/PROD

Target System Tools ORACLE_HOME Directory [/opt/oracle/PROD/apps/tech_st/10.1.2] : _

Target System Web ORACLE_HOME Directory [/opt/oracle/PROD/apps/tech_st/10.1.3] : _

Target System APPL_TOP Directory [/opt/oracle/PROD/apps/apps_st/appl] :_

Target System COMMON_TOP Directory [/opt/oracle/PROD/apps/apps_st/comn] : _

Target System Instance Home Directory [/opt/oracle/PROD/inst] : _

Target System Root Service [enabled] : _

Target System Web Entry Point Services [enabled] : _

Target System Web Application Services [enabled] : _

Target System Batch Processing Services [enabled] : _

Target System Other Services [disabled] : _

Do you want to preserve the Display [prodapps:0.0] (y/n)  : n

Target System Display [r12apps:0.0] : _

Do you want the the target system to have the same port values as the source system (y/n) [y] ? : { REFER NOTE BELOW }

--------------------------------------------------------------------------------------------

NOTE: If you want to use the same port values as the current production instance press y if you want to give a different port other than your production instance then press n and select the port number 
For Example if you want to use 8004 then press 4 it will add 4 in default port 8000
--------------------------------------------------------------------------------------------

Complete port information available at /opt/oracle/PROD/apps/apps_st/comn/clone/bin/out/PROD_r12apps/portpool.lst

UTL_FILE_DIR on database tier consists of the following directories.

1. /usr/tmp
2. /opt/oracle/PROD/db/tech_st/11.2.3/appsutil/
3. /opt/oracle/PROD/db/tech_st/11.2.3/appsutil/outbound/PROD_r12apps
4. /usr/tmp
Choose a value which will be set as APPLPTMP value on the target node [1] : _

Creating the new APPL_TOP Context file from :
  /opt/oracle/PROD/apps/apps_st/appl/ad/12.0.0/admin/template/custom/adxmlctx.tmp

The new APPL_TOP context file has been created :
  /opt/oracle/PROD/inst/apps/PROD_r12apps/appl/admin/PROD_r12apps.xml

Log file located at /opt/oracle/PROD/apps/apps_st/comn/clone/bin/CloneContext_0606095954.log
Check Clone Context logfile /opt/oracle/PROD/apps/apps_st/comn/clone/bin/CloneContext_0606095954.log for details.

Running Rapid Clone with command:
perl /opt/oracle/PROD/apps/apps_st/comn/clone/bin/adclone.pl java=/opt/oracle/PROD/apps/apps_st/comn/clone/bin/../jre mode=apply stage=/opt/oracle/PROD/apps/apps_st/comn/clone component=appsTier method=CUSTOM appctxtg=/opt/oracle/PROD/inst/apps/PROD_r12apps/appl/admin/PROD_r12apps.xml showProgress contextValidated=true
Running:
perl /opt/oracle/PROD/apps/apps_st/comn/clone/bin/adclone.pl java=/opt/oracle/PROD/apps/apps_st/comn/clone/bin/../jre mode=apply stage=/opt/oracle/PROD/apps/apps_st/comn/clone component=appsTier method=CUSTOM appctxtg=/opt/oracle/PROD/inst/apps/PROD_r12apps/appl/admin/PROD_r12apps.xml showProgress contextValidated=true
APPS Password :

Beginning application tier Apply - Fri Jun  6 10:02:38 2014

/opt/oracle/PROD/apps/apps_st/comn/clone/bin/../jre/bin/java -Xmx600M -DCONTEXT_VALIDATED=true  -Doracle.installer.oui_loc=/oui -classpath /opt/oracle/PROD/apps/apps_st/comn/clone/jlib/xmlparserv2.jar:/opt/oracle/PROD/apps/apps_st/comn/clone/jlib/ojdbc14.jar:/opt/oracle/PROD/apps/apps_st/comn/clone/jlib/java:/opt/oracle/PROD/apps/apps_st/comn/clone/jlib/oui/OraInstaller.jar:/opt/oracle/PROD/apps/apps_st/comn/clone/jlib/oui/ewt3.jar:/opt/oracle/PROD/apps/apps_st/comn/clone/jlib/oui/share.jar:/opt/oracle/PROD/apps/apps_st/comn/clone/jlib/oui/srvm.jar:/opt/oracle/PROD/apps/apps_st/comn/clone/jlib/ojmisc.jar  oracle.apps.ad.clone.ApplyAppsTier -e /opt/oracle/PROD/inst/apps/PROD_r12apps/appl/admin/PROD_r12apps.xml -stage /opt/oracle/PROD/apps/apps_st/comn/clone    -showProgress
APPS Password : Log file located at /opt/oracle/PROD/inst/apps/PROD_r12apps/admin/log/ApplyAppsTier_06061002.log
  \     71% completed      

Completed Apply...
Fri Jun  6 10:14:40 2014


Do you want to startup the Application Services for PROD? (y/n) [y] : _

Starting application Services for PROD:
Running:
/opt/oracle/PROD/inst/apps/PROD_r12apps/admin/scripts/adstrtal.sh -nopromptmsg

You are running adstrtal.sh version 120.15.12010000.3

The logfile for this session is located at /opt/oracle/PROD/inst/apps/PROD_r12apps/logs/appl/admin/log/adstrtal.log
Executing service control script:
/opt/oracle/PROD/inst/apps/PROD_r12apps/admin/scripts/adopmnctl.sh start
script returned:
****************************************************

You are running adopmnctl.sh version 120.6.12010000.5

Starting Oracle Process Manager (OPMN) ...
opmnctl: opmn started.

adopmnctl.sh: exiting with status 0

adopmnctl.sh: check the logfile /opt/oracle/PROD/inst/apps/PROD_r12apps/logs/appl/admin/log/adopmnctl.txt for more information ... 


.end std out.

.end err out.

****************************************************


Executing service control script:
/opt/oracle/PROD/inst/apps/PROD_r12apps/admin/scripts/adalnctl.sh start
script returned:
****************************************************

adalnctl.sh version 120.3

Checking for FNDFS executable.
Starting listener process APPS_PROD.

adalnctl.sh: exiting with status 0


adalnctl.sh: check the logfile /opt/oracle/PROD/inst/apps/PROD_r12apps/logs/appl/admin/log/adalnctl.txt for more information ... 


.end std out.

.end err out.

****************************************************


Executing service control script:
/opt/oracle/PROD/inst/apps/PROD_r12apps/admin/scripts/adapcctl.sh start
script returned:
****************************************************

You are running adapcctl.sh version 120.7.12010000.2

Starting OPMN managed Oracle HTTP Server (OHS) instance ...
opmnctl: opmn is already running.
opmnctl: starting opmn managed processes...

adapcctl.sh: exiting with status 0

adapcctl.sh: check the logfile /opt/oracle/PROD/inst/apps/PROD_r12apps/logs/appl/admin/log/adapcctl.txt for more information ... 


.end std out.

.end err out.

****************************************************


Executing service control script:
/opt/oracle/PROD/inst/apps/PROD_r12apps/admin/scripts/adoacorectl.sh start
script returned:
****************************************************

You are running adoacorectl.sh version 120.13

Starting OPMN managed OACORE OC4J instance  ...

adoacorectl.sh: exiting with status 0

adoacorectl.sh: check the logfile /opt/oracle/PROD/inst/apps/PROD_r12apps/logs/appl/admin/log/adoacorectl.txt for more information ... 


.end std out.

.end err out.

****************************************************


Executing service control script:
/opt/oracle/PROD/inst/apps/PROD_r12apps/admin/scripts/adformsctl.sh start
script returned:
****************************************************

You are running adformsctl.sh  version 120.16.12010000.3

Starting OPMN managed FORMS OC4J instance  ...
Calling txkChkFormsDeployment.pl to check whether latest FORMSAPP.EAR is deployed...
Program : /opt/oracle/PROD/apps/apps_st/appl/fnd/12.0.0/patch/115/bin/txkChkFormsDeployment.pl started @ Fri Jun  6 10:16:25 2014

*** Log File = /opt/oracle/PROD/inst/apps/PROD_r12apps/logs/appl/rgf/TXK/txkChkFormsDeployment_Fri_Jun_6_10_16_25_2014/txkChkFormsDeployment_Fri_Jun_6_10_16_25_2014.log

File "/opt/oracle/PROD/apps/tech_st/10.1.3/j2ee/forms/applications/forms/formsweb/WEB-INF/lib/frmsrv.jar" exists. Proceeding to check the size...

=============================================
*** Latest formsapp.ear has been deployed ***
=============================================


Program : /opt/oracle/PROD/apps/apps_st/appl/fnd/12.0.0/patch/115/bin/txkChkFormsDeployment.pl completed @ Fri Jun  6 10:16:26 2014

Perl script txkChkFormsDeployment.pl got executed successfully



adformsctl.sh: exiting with status 0

adformsctl.sh: check the logfile /opt/oracle/PROD/inst/apps/PROD_r12apps/logs/appl/admin/log/adformsctl.txt for more information ... 


.end std out.
*** ALL THE FOLLOWING FILES ARE REQUIRED FOR RESOLVING RUNTIME ERRORS
*** Log File = /opt/oracle/PROD/inst/apps/PROD_r12apps/logs/appl/rgf/TXK/txkChkFormsDeployment_Fri_Jun_6_10_16_25_2014/txkChkFormsDeployment_Fri_Jun_6_10_16_25_2014.log

.end err out.

****************************************************


Executing service control script:
/opt/oracle/PROD/inst/apps/PROD_r12apps/admin/scripts/adoafmctl.sh start
script returned:
****************************************************

You are running adoafmctl.sh version 120.8

Starting OPMN managed OAFM OC4J instance  ...

adoafmctl.sh: exiting with status 0

adoafmctl.sh: check the logfile /opt/oracle/PROD/inst/apps/PROD_r12apps/logs/appl/admin/log/adoafmctl.txt for more information ... 


.end std out.

.end err out.

****************************************************


Executing service control script:
/opt/oracle/PROD/inst/apps/PROD_r12apps/admin/scripts/adcmctl.sh start
script returned:
****************************************************

You are running adcmctl.sh version 120.17.12010000.5

Starting concurrent manager for PROD ...
Starting PROD_0606@PROD Internal Concurrent Manager
Default printer is noprint

adcmctl.sh: exiting with status 0


adcmctl.sh: check the logfile /opt/oracle/PROD/inst/apps/PROD_r12apps/logs/appl/admin/log/adcmctl.txt for more information ... 


.end std out.

.end err out.

****************************************************


Executing service control script:
/opt/oracle/PROD/inst/apps/PROD_r12apps/admin/scripts/jtffmctl.sh start
script returned:
****************************************************

You are running jtffmctl.sh version 120.3

Validating Fulfillment patch level via /opt/oracle/PROD/apps/apps_st/comn/java/classes
Fulfillment patch level validated.
Starting Fulfillment Server for PROD on port 9300 ...

jtffmctl.sh: exiting with status 0


.end std out.

.end err out.

****************************************************


All enabled services for this node are started.

adstrtal.sh: Exiting with status 0

adstrtal.sh: check the logfile /opt/oracle/PROD/inst/apps/PROD_r12apps/logs/appl/admin/log/adstrtal.log for more information ... 

[oracle@r12apps bin]$
           








Tags: Oracle E Business Suite, Rapid Clone, 12.1.3, adpreclone.pl, adautoconfig.pl, adclone.pl 

No comments:

Post a Comment