Cloning EBS R12.2.9 Environment Step by Step using cold backup
Cloning EBS R12.2.9 Environment Step by Step using cold backup
Source environment details
Hostname - ebs122.premier.com
Database Name - UAT
Target environment details
Hostname - ebs121.premier.com
Database Name - TEST
Pre-Req Tasks on Target system:
Make sure all rpms all installed as we installed during our EBS installation process.
Make sure we had the oracle and applmgr user created on target system.
Preparation of the Source DB Tier.
Make sure to have latest appsutil on database side.
Login to Database node as oracle.
Download patch 17537119 from My Oracle Support, unzip it under /db/oratst/TEST/12.1.0/12.1.0/appsutil/etcc and run /db/oratst/TEST/12.1.0/appsutil/etcc/checkDBpatch.sh to avoid ADOP related issues.
Go to Oracle Home>appsutil/scripts/$CONTEXT_NAME/
Run perl adpreclone.pl dbTier
[oracle@ebs122 UAT_ebs122]$ perl adpreclone.pl dbTier
Copyright (c) 2011, 2014 Oracle Corporation
Redwood Shores, California, USA
Oracle E-Business Suite Rapid Clone
Version 12.2
adpreclone Version 120.31.12020000.25
Enter the APPS User Password:
Verifying if Database Patch checker (ETCC) exists in /db/orauat/UAT/12.1.0/appsutil/etcc
Running:
perl /db/orauat/UAT/12.1.0/appsutil/bin/adclone.pl java=/db/orauat/UAT/12.1.0/appsutil/jre mode=stage stage=/db/orauat/UAT/12.1.0/appsutil/clone component=dbTier method=CUSTOM dbctx=/db/orauat/UAT/12.1.0/appsutil/UAT_ebs122.xml showProgress
Beginning database tier Stage - Fri Mar 20 21:49:14 2020
/db/orauat/UAT/12.1.0/appsutil/jre/bin/java -Xmx600M -DCONTEXT_VALIDATED=false -Doracle.installer.oui_loc=/db/orauat/UAT/12.1.0/oui -classpath /db/orauat/UAT/12.1.0/lib/xmlparserv2.jar:/db/orauat/UAT/12.1.0/jdbc/lib/ojdbc6.jar:/db/orauat/UAT/12.1.0/appsutil/java:/db/orauat/UAT/12.1.0/oui/jlib/OraInstaller.jar:/db/orauat/UAT/12.1.0/oui/jlib/ewt3.jar:/db/orauat/UAT/12.1.0/oui/jlib/share.jar:/db/orauat/UAT/12.1.0/oui/jlib/srvm.jar:/db/orauat/UAT/12.1.0/jlib/ojmisc.jar oracle.apps.ad.clone.StageDBTier -e /db/orauat/UAT/12.1.0/appsutil/UAT_ebs122.xml -stage /db/orauat/UAT/12.1.0/appsutil/clone -tmp /tmp -method CUSTOM -showProgress
APPS Password :
Log file located at /db/orauat/UAT/12.1.0/appsutil/log/UAT_ebs122/StageDBTier_03202149.log
- 79% completed
Completed Stage...
Fri Mar 20 21:49:42 2020
[oracle@ebs122 UAT_ebs122]$
5. Go to Application server and login as applmgr
6. cd $ADMIN_SCRIPTS_HOME
perl adpreclone.pl appsTier
[applmgr@ebs122 ~]$ . EBSapps.env run
E-Business Suite Environment Information
----------------------------------------
RUN File System : /apps/appuat/UAT/fs1/EBSapps/appl
PATCH File System : /apps/appuat/UAT/fs2/EBSapps/appl
Non-Editioned File System : /apps/appuat/UAT/fs_ne
DB Host: ebs122.premier.com Service/SID: UAT
Sourcing the RUN File System ...
[applmgr@ebs122 ~]$
[applmgr@ebs122 ~]$ cd $ADMIN_SCRIPTS_HOME
[applmgr@ebs122 scripts]$
[applmgr@ebs122 scripts]$ perl adpreclone.pl appsTier
Copyright (c) 2011, 2014 Oracle Corporation
Redwood Shores, California, USA
Oracle E-Business Suite Rapid Clone
Version 12.2
adpreclone Version 120.31.12020000.25
Enter the APPS User Password:
Enter the Weblogic AdminServer password :
Checking the status of the Oracle WebLogic Administration Server....
Running perl /apps/appuat/UAT/fs1/EBSapps/appl/ad/12.0.0/patch/115/bin/adProvisionEBS.pl ebs-get-serverstatus -contextfile=/apps/appuat/UAT/fs1/inst/apps/UAT_ebs122/appl/admin/UAT_ebs122.xml -servername=AdminServer -promptmsg=hide
The Oracle WebLogic Administration Server is up.
wlsDomainName: EBS_domain_UAT
WLS Domain Name is VALID.
Running:
perl /apps/appuat/UAT/fs1/EBSapps/appl/ad/12.0.0/bin/adclone.pl java=/apps/appuat/UAT/fs1/EBSapps/comn/util/jdk64 mode=stage stage=/apps/appuat/UAT/fs1/EBSapps/comn/clone component=appsTier method= appctx=/apps/appuat/UAT/fs1/inst/apps/UAT_ebs122/appl/admin/UAT_ebs122.xml showProgress
Setting the wls environment
Beginning application tier Stage - Fri Mar 20 16:04:05 2020
/apps/appuat/UAT/fs1/EBSapps/comn/util/jdk64/bin/java -Xmx600M -DCONTEXT_VALIDATED=false -Doracle.installer.oui_loc=/oui -classpath /apps/appuat/UAT/fs1/FMW_Home/webtier/lib/xmlparserv2.jar:/apps/appuat/UAT/fs1/FMW_Home/webtier/jdbc/lib/ojdbc6.jar:/apps/appuat/UAT/fs1/EBSapps/comn/java/classes:/apps/appuat/UAT/fs1/FMW_Home/webtier/oui/jlib/OraInstaller.jar:/apps/appuat/UAT/fs1/FMW_Home/webtier/oui/jlib/ewt3.jar:/apps/appuat/UAT/fs1/FMW_Home/webtier/oui/jlib/share.jar:/apps/appuat/UAT/fs1/FMW_Home/webtier/../Oracle_EBS-app1/oui/jlib/srvm.jar:/apps/appuat/UAT/fs1/FMW_Home/webtier/jlib/ojmisc.jar:/apps/appuat/UAT/fs1/FMW_Home/wlserver_10.3/server/lib/weblogic.jar:/apps/appuat/UAT/fs1/FMW_Home/oracle_common/jlib/obfuscatepassword.jar oracle.apps.ad.clone.StageAppsTier -e /apps/appuat/UAT/fs1/inst/apps/UAT_ebs122/appl/admin/UAT_ebs122.xml -stage /apps/appuat/UAT/fs1/EBSapps/comn/clone -tmp /tmp -method CUSTOM -showProgress -nopromptmsg
Log file located at /apps/appuat/UAT/fs1/inst/apps/UAT_ebs122/admin/log/clone/StageAppsTier_03201604.log
/ 20% completed
Completed Stage...
Fri Mar 20 16:29:10 2020
[applmgr@ebs122 scripts]$
7. Stop the application services and database services on your source system.
8. Take a backup of database files and Oracle Home from database node.
9. Take a backup EBSapps directory of your RUN file system on fs1/fs2.
10. Go to database node
$cd /db
$nohup tar -cvzf /EBSBKP/122after1229working/db.tar orauat &
11. Go to appplication node
tar -zxvf EBSapps.tar.gz EBSapps
12. Login to target machine
$cd /apps
$nohup tar -cvzf /EBSBKP/122after1229working/apps1229.tar appuat &
copy the backup from source to target
$cd /EBSBKP
$scp -r 122after1229working/ root@192.168.0.9:/soft
Make sure below users exists in source environment
[root@ebs121 ~]# id oracle
uid=500(oracle) gid=54322(dba) groups=54322(dba)
[root@ebs121 ~]#
[root@ebs121 ~]# id applmgr
uid=501(applmgr) gid=54322(dba) groups=54322(dba)
[root@ebs121 ~]#
- extract the tar files
#cd /db
#tar -xvf /soft/122after1229working/db.tar
#cd /apps
#tar -xvf /soft/122after1229working/apps1229.tar
Once Untar is done , please remove tar files to release space.
Rename the folders and change the permisionssions
#cd /db
#mv orauat oratst
#cd oratst
#mv UAT TEST
#chown -R oracle:dba oratst
#cd /apps
#mv appuat apptst
#mv UAT TEST
#chown -R applmgr:dba apptst
- check the orainventory and delete old inventory
[root@ebs121 apptst]# cat /etc/oraInst.loc
inventory_loc=/db/oracle/oraInventory
inst_group=dba
[root@ebs121 apptst]#
- delete the below folders
$cd /apps/apptst/TEST/fs1
$rm -rf FMW_Home inst
$/apps/apptst/TEST/fs2
$rm -rf FMW_Home inst
Go to clone/bin directory and run adcfgclone.pl on database node .
$cd /db/oratst/TEST/12.1.0/appsutil/clone/bin
Configure Database Node
[oracle@ebs121 bin]$ cd /db/oratst/TEST/12.1.0/appsutil/clone/bin
[oracle@ebs121 bin]$ perl adcfgclone.pl dbTier
Copyright (c) 2002, 2015 Oracle Corporation
Redwood Shores, California, USA
Oracle E-Business Suite Rapid Clone
Version 12.2
adcfgclone Version 120.63.12020000.62
Enter the APPS password :
Running: Context clone...
Log file located at /db/oratst/TEST/12.1.0/appsutil/clone/bin/CloneContext_0323131914.log
Provide the values required for creation of the new Database Context file.
Target System Hostname (virtual or normal) [ebs121] :
Target Instance is RAC (y/n) [n] :
Target System Database SID : TEST
Target System Base Directory : /db/oratst/TEST
Role separation is supported y/n [n] ? : n
Target System utl_file_dir Directory List : /usr/tmp
Number of DATA_TOP's on the Target System [1] :
Target System DATA_TOP Directory 1 [/db/oratst/TEST/data] :
Target System RDBMS ORACLE_HOME Directory [/db/oratst/TEST/12.1.0] :
Do you want to preserve the Display [null] (y/n) : n
Target System Display [ebs121:0.0] : ebs121:0
Do you want the target system to have the same port values as the source system (y/n) [y] ? : n
Target System Port Pool [0-99] : 0
Checking the port pool 0
done: Port Pool 0 is free
Report file located at /db/oratst/TEST/12.1.0/appsutil/temp/portpool.lst
The new database context file has been created :
/db/oratst/TEST/12.1.0/appsutil/TEST_ebs121.xml
Check Clone Context logfile /db/oratst/TEST/12.1.0/appsutil/clone/bin/CloneContext_0323131914.log for details.
Running Rapid Clone with command:
Running:
perl /db/oratst/TEST/12.1.0/appsutil/clone/bin/adclone.pl java=/db/oratst/TEST/12.1.0/appsutil/clone/bin/../jre mode=apply stage=/db/oratst/TEST/12.1.0/appsutil/clone component=dbTier method=CUSTOM dbctxtg=/db/oratst/TEST/12.1.0/appsutil/TEST_ebs121.xml showProgress contextValidated=true
Beginning database tier Apply - Mon Mar 23 13:20:00 2020
/db/oratst/TEST/12.1.0/appsutil/clone/bin/../jre/bin/java -Xmx600M -DCONTEXT_VALIDATED=true -Doracle.installer.oui_loc=/db/oratst/TEST/12.1.0/oui -classpath /db/oratst/TEST/12.1.0/appsutil/clone/jlib/xmlparserv2.jar:/db/oratst/TEST/12.1.0/appsutil/clone/jlib/ojdbc6.jar:/db/oratst/TEST/12.1.0/appsutil/clone/jlib/java:/db/oratst/TEST/12.1.0/appsutil/clone/jlib/oui/OraInstaller.jar:/db/oratst/TEST/12.1.0/appsutil/clone/jlib/oui/ewt3.jar:/db/oratst/TEST/12.1.0/appsutil/clone/jlib/oui/share.jar:/db/oratst/TEST/12.1.0/appsutil/clone/jlib/oui/srvm.jar:/db/oratst/TEST/12.1.0/appsutil/clone/jlib/ojmisc.jar oracle.apps.ad.clone.ApplyDBTier -e /db/oratst/TEST/12.1.0/appsutil/TEST_ebs121.xml -stage /db/oratst/TEST/12.1.0/appsutil/clone -showProgress
APPS Password : Log file located at /db/oratst/TEST/12.1.0/appsutil/log/TEST_ebs121/ApplyDBTier_03231320.log
\ 15% completed
Completed Apply...
Mon Mar 23 13:39:54 2020
Starting database listener for TEST:
Running:
/db/oratst/TEST/12.1.0/appsutil/scripts/TEST_ebs121/addlnctl.sh start TEST
Logfile: /db/oratst/TEST/12.1.0/appsutil/log/TEST_ebs121/addlnctl.txt
You are running addlnctl.sh version 120.4
Starting listener process TEST ...
Listener TEST has already been started.
addlnctl.sh: exiting with status 0
addlnctl.sh: check the logfile /db/oratst/TEST/12.1.0/appsutil/log/TEST_ebs121/addlnctl.txt for more information ...
Do you want to change the password for all EBS Schemas? (y/n) [n]) : n
Do you want to change the password for sysadmin user? (y/n) [n]) : n
Do you want to change the apps password? (y/n) [n]) : n
Do you want to change the sys and system passwords? (y/n) [n]) : n
Running ETCC to check status of DB technology patches...
+===============================================================+
| Copyright (c) 2005, 2019 Oracle and/or its affiliates. |
| All rights reserved. |
| Oracle E-Business Suite Release 12.2 |
| Database EBS Technology Codelevel Checker |
+===============================================================+
Using context file from command line argument:
/db/oratst/TEST/12.1.0/appsutil/TEST_ebs121.xml
Starting Database EBS Technology Codelevel Checker, Version 120.72
Mon Mar 23 13:49:37 IST 2020
Log file for this session : /db/oratst/TEST/12.1.0/appsutil/clone/bin/log/checkDBpatch_27192.log
Identifying database release.
Database release set to 12.1.0.2.
Connecting to database.
Database connection successful.
Database TEST is in READ WRITE mode.
Identifying APPS and APPLSYS schema names.
- APPS schema : APPS
- APPLSYS schema : APPLSYS
Checking for DB-ETCC results table.
Table to store DB-ETCC results already exists in the database.
Bugfix file /db/oratst/TEST/12.1.0/appsutil/etcc/db/onprem/txk_R1220_DB_base_bugs.xml : 120.0.12020000.50
This file will be used for identifying missing bugfixes.
Mapping file /db/oratst/TEST/12.1.0/appsutil/etcc/db/onprem/txk_R1220_DB_mappings.xml : 120.0.12020000.25
This file will be used for mapping bugfixes to patches.
[WARNING] DB-ETCC: Bugfix XML file (/db/oratst/TEST/12.1.0/appsutil/etcc/db/onprem/txk_R1220_DB_base_bugs.xml) is more than 30 days old.
Check if a newer version is available in patch 17537119.
Checking Bugfix XML file for 12.1.0.2
Obtained list of bugfixes to be applied and the list to be rolled back.
Now checking Database ORACLE_HOME.
The opatch utility is version 12.1.0.1.10.
DB-ETCC is compatible with this opatch version.
Found patch records in the inventory.
Checking Mapping XML file for 12.1.0.2
All the required one-off bugfixes are present in Database ORACLE_HOME.
Stored Technology Codelevel Checker results in the database TEST successfully.
Finished checking fixes for Oracle Database: Mon Mar 23 13:49:59 IST 2020
Log file for this session: /db/oratst/TEST/12.1.0/appsutil/clone/bin/log/checkDBpatch_27192.log
===============================================================================
[oracle@ebs121 bin]$
check the environment
[oracle@ebs121 ~]$ ps -ef|grep smon
oracle 21252 21185 0 19:18 pts/1 00:00:00 grep smon
oracle 26133 1 0 13:32 ? 00:00:01 ora_smon_TEST
[oracle@ebs121 ~]$
[oracle@ebs121 ~]$ ps -ef|grep tns
oracle 21254 21185 0 19:18 pts/1 00:00:00 grep tns
oracle 25408 1 0 13:22 ? 00:00:00 /db/oratst/TEST/12.1.0/bin/tnslsnr TEST -inherit
[oracle@ebs121 ~]$
[oracle@ebs121 12.1.0]$ pwd
/db/oratst/TEST/12.1.0
[oracle@ebs121 12.1.0]$ . TEST_ebs121.env
[oracle@ebs121 12.1.0]$
[oracle@ebs121 12.1.0]$ sqlplus '/as sysdba'
SQL*Plus: Release 12.1.0.2.0 Production on Mon Mar 23 19:19:30 2020
Copyright (c) 1982, 2014, Oracle. All rights reserved.
Connected to:
Oracle Database 12c Enterprise Edition Release 12.1.0.2.0 - 64bit Production
With the Partitioning, OLAP, Advanced Analytics and Real Application Testing options
SQL> select status from v$instance;
STATUS
------------
OPEN
SQL> select name from v$database;
NAME
---------
TEST
SQL>
Login to application node (applmgr)
Goto clone/bin directory and run adcfgclone.pl on application node
Run adcfgclone.pl appsTier dualfs
[applmgr@ebs121 bin]$ pwd
/apps/apptst/TEST/fs1/EBSapps/comn/clone/bin
[applmgr@ebs121 bin]$
[applmgr@ebs121 bin]$
[applmgr@ebs121 bin]$ per adcfgclone.pl appsTier dualfs
-bash: per: command not found
[applmgr@ebs121 bin]$
[applmgr@ebs121 bin]$
[applmgr@ebs121 bin]$ perl adcfgclone.pl appsTier dualfs
Copyright (c) 2002, 2015 Oracle Corporation
Redwood Shores, California, USA
Oracle E-Business Suite Rapid Clone
Version 12.2
adcfgclone Version 120.63.12020000.62
Enter the APPS password :
Enter the Weblogic AdminServer password :
Do you want to add a node (yes/no) [no] :
Running: Context clone...
Log file located at /apps/apptst/TEST/fs1/EBSapps/comn/clone/bin/CloneContext_0323144132.log
Provide the values required for creation of the new APPL_TOP Context file.
Target System Hostname (virtual or normal) [ebs121] :
Target System Database SID : TEST
Target System Database Server Node [ebs121] :
Target System Database Domain Name [premier.com] :
Target System Base Directory : /apps/apptst/TEST
Target System Base Directory set to /apps/apptst/TEST
Target System Current File System Base set to /apps/apptst/TEST/fs1
Target System Other File System Base set to /apps/apptst/TEST/fs2
Target System Fusion Middleware Home set to /apps/apptst/TEST/fs1/FMW_Home
Target System Other File System Fusion Middleware Home set to /apps/apptst/TEST/fs2/FMW_Home
Target System Web Oracle Home set to /apps/apptst/TEST/fs1/FMW_Home/webtier
Target System Other File System Web Oracle Home set to /apps/apptst/TEST/fs2/FMW_Home/webtier
Target System Appl TOP set to /apps/apptst/TEST/fs1/EBSapps/appl
Target System Other File System Appl TOP set to /apps/apptst/TEST/fs2/EBSapps/appl
Target System COMMON TOP set to /apps/apptst/TEST/fs1/EBSapps/comn
Target System Other File System COMMON TOP set to /apps/apptst/TEST/fs2/EBSapps/comn
Target System Instance Home Directory [/apps/apptst/TEST] :
Target System Current File System Instance Top set to /apps/apptst/TEST/fs1/inst/apps/TEST_ebs121
Do you want to preserve the Display [ebs122:0.0] (y/n) : n
Target System Display [ebs121:0.0] : ebs121:0.0
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 the target system to have the same port values as the source system (y/n) [y] ? : n
Target System Port Pool [0-99] : 0
Checking the port pool 0
done: Port Pool 0 is free
Report file located at /apps/apptst/TEST/fs1/inst/apps/TEST_ebs121/admin/out/portpool.lst
Target System proxy port [80] :
UTL_FILE_DIR on database tier consists of the following directories.
1. /usr/tmp
2. /usr/tmp
3. /db/oratst/TEST/12.1.0/appsutil/outbound/TEST_ebs121
4. /usr/tmp
Choose a value which will be set as APPLPTMP value on the target node [1] :
The new APPL_TOP context file has been created :
/apps/apptst/TEST/fs1/inst/apps/TEST_ebs121/appl/admin/TEST_ebs121.xml
Check Clone Context logfile /apps/apptst/TEST/fs1/EBSapps/comn/clone/bin/CloneContext_0323144132.log for details.
Creating Patch file system context file.....
Log file located at /apps/apptst/TEST/fs1/EBSapps/comn/clone/bin/CloneContextPatch_0323144336.log
Target System Other File System Instance Top set to /apps/apptst/TEST/fs2/inst/apps/TEST_ebs121
Target System Port Pool [0-99] : 10
Checking the port pool 10
done: Port Pool 10 is free
Report file located at /apps/apptst/TEST/fs2/inst/apps/TEST_ebs121/admin/out/portpool.lst
The new APPL_TOP context file has been created :
/apps/apptst/TEST/fs2/inst/apps/TEST_ebs121/appl/admin/TEST_ebs121.xml
Check Clone Context logfile /apps/apptst/TEST/fs1/EBSapps/comn/clone/bin/CloneContextPatch_0323144336.log for details.
FMW Pre-requisite check log file location : /apps/apptst/TEST/fs1/EBSapps/comn/clone/FMW/logs/prereqcheck.log
Running: FMW pre-req check...
Configuring: Run file system....
LogFile located at /apps/apptst/TEST/fs1/inst/apps/TEST_ebs121/admin/log/clone/run/RCloneApplyAppstier_03231444.log
<Mar 23, 2020 3:24:51 PM IST> <Warning> <JNDI> <BEA-050001> <WLContext.close() was called in a different thread than the one in which it was created.>
Configuring: Patch file system....
LogFile located at /apps/apptst/TEST/fs1/inst/apps/TEST_ebs121/admin/log/clone/patch/RCloneApplyAppstier_03231534.log
Do you want to startup the Application Services for TEST? (y/n) [n] : n
Services not started
[applmgr@ebs121 bin]$
[applmgr@ebs121 bin]$
- set the environment and start the application services
[applmgr@ebs121 ~]$ cd /apps/apptst/TEST/
[applmgr@ebs121 TEST]$
[applmgr@ebs121 TEST]$ . EBSapps.env run
E-Business Suite Environment Information
----------------------------------------
RUN File System : /apps/apptst/TEST/fs1/EBSapps/appl
PATCH File System : /apps/apptst/TEST/fs2/EBSapps/appl
Non-Editioned File System : /apps/apptst/TEST/fs_ne
DB Host: ebs121.premier.com Service/SID: TEST
Sourcing the RUN File System ...
[applmgr@ebs121 TEST]$
need to use the credentials same as source environment
[applmgr@ebs121 TEST]$ cd $ADMIN_SCRIPTS_HOME
[applmgr@ebs121 scripts]$
[applmgr@ebs121 scripts]$
[applmgr@ebs121 scripts]$ sh adstrtal.sh apps/apps
You are running adstrtal.sh version 120.24.12020000.11
Enter the WebLogic Server password:
Open the application login link and validate application