Oracle Apps R12
cloning Using RMAN backup
In this article i will illustrate all steps
involved in cloning an Oracle E-Business suite environment using online backup.
There are other ways also to do a clone of database with online backup. But in this article I am illustrating rman database cloning with nocatalog option.
- Database will be backed up using rman
- Application File system will be backed up when all services are up and running.
source system - Existing system for which you want to create a new copy
target system - New system on which clone is prepared
Source and target OS - oracle solaris 10 - sparc 64-bit
Application Version - R12.1.1
Database Version - 11.1.0.7
High Level Steps:
There are other ways also to do a clone of database with online backup. But in this article I am illustrating rman database cloning with nocatalog option.
- Database will be backed up using rman
- Application File system will be backed up when all services are up and running.
source system - Existing system for which you want to create a new copy
target system - New system on which clone is prepared
Source and target OS - oracle solaris 10 - sparc 64-bit
Application Version - R12.1.1
Database Version - 11.1.0.7
High Level Steps:
1.
Install all required rapid clone patches from
Note "406982.1" on
source system if doesn't exists.
2.
Run clone preparation script (adpreclone.pl)
on database and application Tier
3.
Perform full database backup using rman
4.
Perform application file system backup using
tar/backup tool
5.
Copy RDBMS ORACLE_HOME, rman backup pieces
and Application FS on target node
6.
Create database context file using clone
configuration script (adcfgclone.pl)
7.
Restore and recover database using rman
8.
Run autoconfig on target database node
9.
Run clone configuration script on application
Tier on target node.
10.
perform post clone steps
Source System Application dash board:
check pre-req patches on source system:
- Perform all OS pre-requisites on target system (OS packages, users, groups, kernel parameters, Display, File system privileges and space requirements)
For LINUX refer section "Perform all operating system per-requisites":
http://appsdbaworkshop.blogspot.com/2011/11/installation-of-oracle-applications.html
For Solaris refer:
http://appsdbaworkshop.blogspot.com/2010/11/oracle-applications-r1211-installation.html
- Perform all OS pre-requisites on target system (OS packages, users, groups, kernel parameters, Display, File system privileges and space requirements)
For LINUX refer section "Perform all operating system per-requisites":
http://appsdbaworkshop.blogspot.com/2011/11/installation-of-oracle-applications.html
For Solaris refer:
http://appsdbaworkshop.blogspot.com/2010/11/oracle-applications-r1211-installation.html
SQL>
select BUG_ID, BUG_NUMBER from ad_bugs where bug_number='&num';
Enter
value for num: 9239089
old
1: select BUG_ID, BUG_NUMBER from ad_bugs where bug_number='&num'
new
1: select BUG_ID, BUG_NUMBER from ad_bugs where bug_number='9239089'
BUG_ID BUG_NUMBER
----------
------------------------------
374712 9239089
SQL>
/
Enter
value for num: 9171651
old
1: select BUG_ID, BUG_NUMBER from ad_bugs where bug_number='&num'
new
1: select BUG_ID, BUG_NUMBER from ad_bugs where bug_number='9171651'
BUG_ID BUG_NUMBER
----------
------------------------------
375423 9171651
SQL>
/
Enter
value for num: 9833058
old
1: select BUG_ID, BUG_NUMBER from ad_bugs where bug_number='&num'
new
1: select BUG_ID, BUG_NUMBER from ad_bugs where bug_number='9833058'
BUG_ID BUG_NUMBER
----------
------------------------------
375424 9833058
SQL>
/
Enter
value for num: 12404574
old
1: select BUG_ID, BUG_NUMBER from ad_bugs where bug_number='&num'
new
1: select BUG_ID, BUG_NUMBER from ad_bugs where bug_number='12404574'
BUG_ID BUG_NUMBER
----------
------------------------------
375421 12404574
SQL>
/
Enter
value for num: 12598630
old
1: select BUG_ID, BUG_NUMBER from ad_bugs where bug_number='&num'
new
1: select BUG_ID, BUG_NUMBER from ad_bugs where bug_number='12598630'
BUG_ID BUG_NUMBER
----------
------------------------------
375422 12598630
Run Clone Preparation Script (adpreclone.pl) on DB Tier
bash-3.00$
adpreclone.pl dbTier
Copyright (c) 2002 Oracle Corporation
Redwood Shores, California, USA
Oracle Applications Rapid Clone
Version 12.0.0
adpreclone Version 120.20.12010000.5
Enter
the APPS User Password:
Running:
perl
/data/R12_ERP/db/tech_st/11.1.0/appsutil/bin/adclone.pl
java=/data/R12_ERP/db/tech_st/11.1.0/appsutil/jre
mode=stage
stage=/data/R12_ERP/db/tech_st/11.1.0/appsutil/clone
component=dbTier
method=CUSTOM
dbctx=/data/R12_ERP/db/tech_st/11.1.0/appsutil/ERPTEST_devdb.xml
showProgress
APPS
Password :
Beginning
database tier Stage - Sun Feb 3 11:45:39 2013
/data/R12_ERP/db/tech_st/11.1.0/appsutil/jre/bin/java
-Xmx600M -DCONTEXT_VALIDATED=false
-Doracle.installer.oui_loc=/data/R12_ERP/db/tech_st/11.1.0/oui
-classpath
/data/R12_ERP/db/tech_st/11.1.0/lib/xmlparserv2.jar:/data/R12_ERP/db/tech_st/11.1.0/jdbc/lib/ojdbc6.jar:/data/R12_ERP/db/tech_st/11.1.0/appsutil/java:/data/R12_ERP/db/tech_st/11.1.0/oui/jlib/OraInstaller.jar:/data/R12_ERP/db/tech_st/11.1.0/oui/jlib/ewt3.jar:/data/R12_ERP/db/tech_st/11.1.0/oui/jlib/share.jar:/data/R12_ERP/db/tech_st/11.1.0/oui/jlib/srvm.jar:/data/R12_ERP/db/tech_st/11.1.0/jlib/ojmisc.jar
oracle.apps.ad.clone.StageDBTier -e
/data/R12_ERP/db/tech_st/11.1.0/appsutil/ERPTEST_devdb.xml
-stage
/data/R12_ERP/db/tech_st/11.1.0/appsutil/clone
-tmp /tmp -method
CUSTOM
-showProgress
APPS
Password :
Log
file located at /data/R12_ERP/db/tech_st/11.1.0/appsutil/log/ERPTEST_devdb/StageDBTier_02031145.log
- 50% completed
Completed
Stage...
Sun
Feb 3 11:48:10 2013
bash-3.00$
Run Clone Preparation Script (adpreclone.pl) on Application Tier
bash-3.00$ adopmnctl.sh status
You are running adopmnctl.sh version 120.6.12010000.4
Checking status of OPMN managed processes...
Processes in Instance: ERPTEST_devappl.devaappl.orasol.com
---------------------------------+--------------------+---------+---------
ias-component
| process-type |
pid | status
---------------------------------+--------------------+---------+---------
OC4JGroup:default_group
| OC4J:oafm
| 28611 | Alive
OC4JGroup:default_group
| OC4J:forms |
28580 | Alive
OC4JGroup:default_group
| OC4J:oacore | 28503 |
Alive
HTTP_Server
| HTTP_Server | 28450 |
Alive
adopmnctl.sh: exiting with status 0
adopmnctl.sh:
check the logfile
/appl/R12_ERP/inst/apps/ERPTEST_devappl/logs/appl/admin/log/adopmnctl.txt
for more information ...
bash-3.00$ adpreclone.pl appsTier
Copyright (c) 2002 Oracle Corporation
Redwood Shores, California, USA
Oracle Applications Rapid Clone
Version 12.0.0
adpreclone Version 120.20.12010000.5
Running:
perl
/appl/R12_ERP/apps/apps_st/appl/ad/12.0.0/bin/adclone.pl
java=/appl/R12_ERP/apps/tech_st/10.1.3/appsutil/jdk mode=stage
stage=/appl/R12_ERP/apps/apps_st/comn/clone component=appsTier
method=
appctx=/appl/R12_ERP/inst/apps/ERPTEST_devappl/appl/admin/ERPTEST_devappl.xml
showProgress
APPS Password :
method defaulted to CUSTOM
Beginning application tier Stage - Sun Feb 3 11:54:33 2013
/appl/R12_ERP/apps/tech_st/10.1.3/appsutil/jdk/bin/java
-Xmx600M
-DCONTEXT_VALIDATED=false -Doracle.installer.oui_loc=/oui
-classpath
/appl/R12_ERP/apps/tech_st/10.1.3/lib/xmlparserv2.jar:/appl/R12_ERP/apps/tech_st/10.1.3/jdbc/lib/ojdbc14.jar:/appl/R12_ERP/apps/apps_st/comn/java/classes:/appl/R12_ERP/apps/tech_st/10.1.3/oui/jlib/OraInstaller.jar:/appl/R12_ERP/apps/tech_st/10.1.3/oui/jlib/ewt3.jar:/appl/R12_ERP/apps/tech_st/10.1.3/oui/jlib/share.jar:/appl/R12_ERP/apps/tech_st/10.1.3/oui/jlib/srvm.jar:/appl/R12_ERP/apps/tech_st/10.1.3/jlib/ojmisc.jar
oracle.apps.ad.clone.StageAppsTier -e
/appl/R12_ERP/inst/apps/ERPTEST_devappl/appl/admin/ERPTEST_devappl.xml
-stage /appl/R12_ERP/apps/apps_st/comn/clone -tmp /tmp -method
CUSTOM
-showProgress
Log file located at /appl/R12_ERP/inst/apps/ERPTEST_devappl/admin/log/StageAppsTier_02031154.log
\ 80% completed
Completed Stage...
Sun Feb 3 11:57:14 2013
|
Perform Full DATABASE RMAN Backup:
bash-3.00$
rman target /
Recovery
Manager: Release 11.1.0.7.0 - Production on Sun Feb 3 12:05:35 2013
Copyright
(c) 1982, 2007, Oracle. All rights reserved.
connected
to target database: ERPTEST (DBID=1262470248)
RMAN>
RUN {
2>
configure controlfile autobackup format for device type diks to
'/data/R12_ERP/rman_backup/3feb2013_Bkp/%F';
3>
configure controlfile autobackup on;
4>
allocate channel d1 type disk;
5>
backup tag FULL_DB database plus archivelog format
'/data/R12_ERP/rman_backup/3feb2013_Bkp/db_%t_%s.bkp';
6>
release channel d1;
7>
}
new
RMAN configuration parameters:
CONFIGURE
CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE 'DIKS' TO
'/data/R12_ERP/rman_backup/3feb2013_Bkp/%F';
new
RMAN configuration parameters are successfully stored
new
RMAN configuration parameters:
CONFIGURE
CONTROLFILE AUTOBACKUP ON;
new
RMAN configuration parameters are successfully stored
allocated
channel: d1
channel
d1: SID=359 device type=DISK
Starting
backup at 03-FEB-13
current
log archived
channel
d1: starting archived log backup set
channel
d1: specifying archived log(s) in backup set
input
archived log thread=1 sequence=22 RECID=1 STAMP=805281948
input
archived log thread=1 sequence=23 RECID=2 STAMP=805282565
input
archived log thread=1 sequence=24 RECID=3 STAMP=806418436
channel
d1: starting piece 1 at 03-FEB-13
channel
d1: finished piece 1 at 03-FEB-13
piece
handle=/data/R12_ERP/rman_backup/3feb2013_Bkp/db_806418437_7.bkp tag=FULL_DB
comment=NONE
channel
d1: backup set complete, elapsed time: 00:00:25
Finished
backup at 03-FEB-13
Starting
backup at 03-FEB-13
channel
d1: starting full datafile backup set
channel
d1: specifying datafile(s) in backup set
input
datafile file number=00023 name=/data/R12_ERP/db/apps_st/data/a_txn_data02.dbf
input
datafile file number=00025 name=/data/R12_ERP/db/apps_st/data/a_txn_ind01.dbf
input
datafile file number=00022 name=/data/R12_ERP/db/apps_st/data/a_txn_data01.dbf
input
datafile file number=00024 name=/data/R12_ERP/db/apps_st/data/a_txn_data03.dbf
input
datafile file number=00026 name=/data/R12_ERP/db/apps_st/data/a_txn_ind02.dbf
input
datafile file number=00027 name=/data/R12_ERP/db/apps_st/data/a_txn_ind03.dbf
input
datafile file number=00029 name=/data/R12_ERP/db/apps_st/data/a_txn_ind05.dbf
input
datafile file number=00012 name=/data/R12_ERP/db/apps_st/data/undo01.dbf
input
datafile file number=00028 name=/data/R12_ERP/db/apps_st/data/a_txn_ind04.dbf
input
datafile file number=00009 name=/data/R12_ERP/db/apps_st/data/system09.dbf
input
datafile file number=00008 name=/data/R12_ERP/db/apps_st/data/system08.dbf
input
datafile file number=00020 name=/data/R12_ERP/db/apps_st/data/a_ref02.dbf
input
datafile file number=00019 name=/data/R12_ERP/db/apps_st/data/a_ref01.dbf
input
datafile file number=00015 name=/data/R12_ERP/db/apps_st/data/a_media01.dbf
input
datafile file number=00006 name=/data/R12_ERP/db/apps_st/data/system06.dbf
input
datafile file number=00014 name=/data/R12_ERP/db/apps_st/data/a_int01.dbf
input
datafile file number=00021 name=/data/R12_ERP/db/apps_st/data/a_summ01.dbf
input
datafile file number=00004 name=/data/R12_ERP/db/apps_st/data/system04.dbf
input
datafile file number=00010 name=/data/R12_ERP/db/apps_st/data/system10.dbf
input
datafile file number=00002 name=/data/R12_ERP/db/apps_st/data/system02.dbf
input
datafile file number=00003 name=/data/R12_ERP/db/apps_st/data/system03.dbf
input
datafile file number=00001 name=/data/R12_ERP/db/apps_st/data/system01.dbf
input
datafile file number=00005 name=/data/R12_ERP/db/apps_st/data/system05.dbf
input
datafile file number=00011 name=/data/R12_ERP/db/apps_st/data/system11.dbf
input
datafile file number=00007 name=/data/R12_ERP/db/apps_st/data/system07.dbf
input
datafile file number=00013 name=/data/R12_ERP/db/apps_st/data/a_archive01.dbf
input
datafile file number=00038 name=/data/R12_ERP/db/apps_st/data/a_txn_data4.dbf
input
datafile file number=00017 name=/data/R12_ERP/db/apps_st/data/a_queue01.dbf
input
datafile file number=00018 name=/data/R12_ERP/db/apps_st/data/a_queue02.dbf
input
datafile file number=00036
name=/data/R12_ERP/db/apps_st/data/apps_ts_tools01.dbf
input
datafile file number=00035 name=/data/R12_ERP/db/apps_st/data/sysaux01.dbf
input
datafile file number=00037 name=/data/R12_ERP/db/apps_st/data/interim.dbf
input
datafile file number=00031 name=/data/R12_ERP/db/apps_st/data/odm.dbf
input
datafile file number=00032 name=/data/R12_ERP/db/apps_st/data/olap.dbf
input
datafile file number=00034 name=/data/R12_ERP/db/apps_st/data/portal01.dbf
input
datafile file number=00016 name=/data/R12_ERP/db/apps_st/data/a_nolog01.dbf
input
datafile file number=00030 name=/data/R12_ERP/db/apps_st/data/ctxd01.dbf
input
datafile file number=00033 name=/data/R12_ERP/db/apps_st/data/owad01.dbf
channel
d1: starting piece 1 at 03-FEB-13
channel
d1: finished piece 1 at 03-FEB-13
piece
handle=/data/R12_ERP/db/tech_st/11.1.0/dbs/08o11u10_1_1 tag=FULL_DB comment=NONE
channel
d1: backup set complete, elapsed time: 00:09:55
Finished
backup at 03-FEB-13
Starting
backup at 03-FEB-13
current
log archived
channel
d1: starting archived log backup set
channel
d1: specifying archived log(s) in backup set
input
archived log thread=1 sequence=25 RECID=4 STAMP=806419062
channel
d1: starting piece 1 at 03-FEB-13
channel
d1: finished piece 1 at 03-FEB-13
piece
handle=/data/R12_ERP/rman_backup/3feb2013_Bkp/db_806419062_9.bkp tag=FULL_DB
comment=NONE
channel
d1: backup set complete, elapsed time: 00:00:01
Finished
backup at 03-FEB-13
Starting
Control File Autobackup at 03-FEB-13
piece
handle=/data/R12_ERP/db/tech_st/11.1.0/dbs/c-1262470248-20130203-00
comment=NONE
Finished
Control File Autobackup at 03-FEB-13
released
channel: d1
Copy backup of Oracle Home, database and application on Target Node
bash-3.00$
pwd
/data/R12_ERP/db
bash-3.00$
ls
apps_st
tech_stbash-3.00$ tar -cvf DbHome.tar tech_st
bash-3.00$
ls
DbHome.tar
apps_st tech_st
bash-3.00$
scp DbHome.tar oraclone@testappl:/appl/ERP_CLONE/dbclone
The
authenticity of host 'testappl (10.10.17.53)' can't be established.
RSA
key fingerprint is 04:b2:6a:ac:28:90:12:45:cd:2c:a1:56:fe:cd:2b:a1.
Are
you sure you want to continue connecting (yes/no)? yes
Warning:
Permanently added 'testappl,10.10.17.53' (RSA) to the list of known hosts.
Password:
DbHome.tar
100%
|****************************************************************************************************|
12370 MB 10:37
bash-3.00$
bash-3.00$
scp /data/R12_ERP/db/tech_st/11.1.0/dbs/c-1262470248-20130203-00
oraclone@testappl:/appl/rman_backup
Password:
c-1262470248-2013020
100%
|************************************************************************************************
bash-3.00$
scp -r /data/R12_ERP/rman_backup/3feb2012_backup
oraclone@testappl:/appl/rman_backup
Password:
ERPTEST_DB_06o11r42_
100%
|************************************************************************************************
ERPTEST_DB_05o11qhe_
100% |************************************************************************************************
- On Target Node testappl
bash-3.00$
pwd
/appl/ERP_CLONE/dbclone
bash-3.00$
tar -xvf DbHome.tar
Edit CTXORIG.xml file to modify the port values and run adcfgclone on
database Tier
bash-3.00$
pwd
/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/clone/bin
bash-3.00$
ls
adcfgclone.pl
adchkutl.sh adclone.pl adclonectx.pl
bash-3.00$
export PATH=/usr/ccs/bin:/usr/bin:/usr/ucb:/etc:.
bash-3.00$
perl adcfgclone.pl dbTechStack
Copyright (c) 2002 Oracle Corporation
Redwood Shores, California, USA
Oracle Applications Rapid Clone
Version 12.0.0
adcfgclone Version 120.31.12010000.8
Enter
the APPS password :
Running:
/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/clone/bin/../jre/bin/java
-Xmx600M -cp
/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/clone/jlib/java:/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/clone/jlib/xmlparserv2.jar:/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/clone/jlib/ojdbc5.jar
oracle.apps.ad.context.CloneContext -e
/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/clone/bin/../context/db/CTXORIG.xml
-validate -pairsfile /tmp/adpairsfile_1233.lst
-stage
/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/clone
-dbTechStack
2>
/tmp/adcfgclone_1233.err; echo $? >
/tmp/adcfgclone_1233.res
Log
file located at
/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/clone/bin/CloneContext_0204091224.log
Provide
the values required for creation of the new Database Context file.
Target
System Hostname (virtual or normal) [testappl] :
Target
Instance is RAC (y/n) [n] :
Target
System Database SID : CLONE
Target
System Base Directory : /appl/ERP_CLONE/dbclone
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 [/data/R12_ERP/db/apps_st/data] :
/appl/ERP_CLONE/dbclone/clone_data
Target
System RDBMS ORACLE_HOME Directory [/appl/ERP_CLONE/dbclone/db/tech_st/11.1.0]
: /appl/ERP_CLONE/dbclone/tech_st/11.1.0
Do
you want to preserve the Display [null] (y/n) : n
Target
System Display [testappl:0.0] :
Do
you want the the target system to have the same port values as the source
system (y/n) [y] ? : n
Target
System Port Pool [0-99] : 22
Checking
the port pool 22
done:
Port Pool 22 is free
Report
file located at
/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/temp/portpool.lst
Complete
port information available at
/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/temp/portpool.lst
Creating
the new Database Context file from :
/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/template/adxdbctx.tmp
The
new database context file has been created :
/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/CLONE_testappl.xml
Log
file located at
/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/clone/bin/CloneContext_0204091224.log
Check
Clone Context logfile
/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/clone/bin/CloneContext_0204091224.log
for details.
Running
Rapid Clone with command:
perl
/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/clone/bin/adclone.pl
java=/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/clone/bin/../jre
mode=apply
stage=/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/clone
component=dbTechStack
method=CUSTOM
dbctxtg=/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/CLONE_testappl.xml
showProgress contextValidated=true
Running:
perl
/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/clone/bin/adclone.pl
java=/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/clone/bin/../jre
mode=apply
stage=/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/clone
component=dbTechStack
method=CUSTOM
dbctxtg=/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/CLONE_testappl.xml
showProgress contextValidated=true
APPS
Password :
Beginning
rdbms home Apply - Mon Feb 4 09:13:28 2013
/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/clone/bin/../jre/bin/java
-Xmx600M -DCONTEXT_VALIDATED=true
-Doracle.installer.oui_loc=/appl/ERP_CLONE/dbclone/tech_st/11.1.0/oui
-classpath
/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/clone/jlib/xmlparserv2.jar:/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/clone/jlib/ojdbc6.jar:/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/clone/jlib/java:/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/clone/jlib/oui/OraInstaller.jar:/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/clone/jlib/oui/ewt3.jar:/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/clone/jlib/oui/share.jar:/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/clone/jlib/oui/srvm.jar:/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/clone/jlib/ojmisc.jar
oracle.apps.ad.clone.ApplyDBTechStack -e
/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/CLONE_testappl.xml
-stage
/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/clone
-showProgress
APPS
Password : Log file located at
/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/log/CLONE_testappl/ApplyDBTechStack_02040913.log
\ 0% completed
Completed
Apply...
Mon
Feb 4 09:16:10 2013
Starting
database listener for CLONE:
Running:
/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/scripts/CLONE_testappl/addlnctl.sh
start CLONE
Logfile:
/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/log/CLONE_testappl/addlnctl.txt
You
are running addlnctl.sh version 120.1.12010000.4
Starting
listener process CLONE ...
LSNRCTL
for Solaris: Version 11.1.0.7.0 - Production on 04-FEB-2013 09:16:10
Copyright
(c) 1991, 2008, Oracle. All rights reserved.
Starting
/appl/ERP_CLONE/dbclone/tech_st/11.1.0/bin/tnslsnr: please wait...
TNSLSNR
for Solaris: Version 11.1.0.7.0 - Production
System
parameter file is
/appl/ERP_CLONE/dbclone/tech_st/11.1.0/network/admin/CLONE_testappl/listener.ora
Log
messages written to /appl/ERP_CLONE/dbclone/tech_st/11.1.0/admin/CLONE_testappl/diag/tnslsnr/testappl/clone/alert/log.xml
Listening
on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=testappl.orasol.com)(PORT=1543)))
Connecting
to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=testappl.orasol.com)(PORT=1543)))
STATUS
of the LISTENER
------------------------
Alias
CLONE
Version
TNSLSNR for Solaris: Version 11.1.0.7.0 - Production
Start
Date
04-FEB-2013 09:16:11
Uptime
0 days 0 hr. 0 min. 4 sec
Trace
Level
off
Security
ON: Local OS Authentication
SNMP
OFF
Listener
Parameter File
/appl/ERP_CLONE/dbclone/tech_st/11.1.0/network/admin/CLONE_testappl/listener.ora
Listener
Log File
/appl/ERP_CLONE/dbclone/tech_st/11.1.0/admin/CLONE_testappl/diag/tnslsnr/testappl/clone/alert/log.xml
Listening
Endpoints Summary...
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=testappl.orasol.com)(PORT=1543)))
Services
Summary...
Service
"CLONE" has 1 instance(s).
Instance "CLONE", status UNKNOWN, has 1 handler(s) for this
service...
The
command completed successfully
addlnctl.sh:
exiting with status 0
addlnctl.sh:
check the logfile
/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/log/CLONE_testappl/addlnctl.txt
for more information ...
bash-3.00$
Change ORACLE_SID to ERP test in newly created environment file
As we are not using catalog database from target we need to
first restore and recover database using the same source SID. Later we can
change it to required SID (CLONE) using "nid"
bash-3.00$ ls -l *.env
-rw-r--r-- 1 oraclone dbaclone
4382 Feb 4 09:29 CLONE_testappl.env
-rw-r--r-- 1 oraclone dbaclone
4225 Jan 20 15:14 ERPTEST_devdb.env
bash-3.00$ pwd
/appl/ERP_CLONE/dbclone/tech_st/11.1.0
bash-3.00$
ORACLE_SID="ERPTEST"
export ORACLE_SID
#Original Value is CLONE, replaced for restore and recover of
rman db
|
copy initCLONE.ora to initERPTEST.ora
Edit db_name to ERPTEST instead of clone in newly copied file
and make sure location of control file
db_name = ERPTEST
control_files
= /appl/ERP_CLONE/dbclone/clone_data/cntrl01.dbf
|
Restore and Recover database using rman on target Node:
SQL> startup nomount
ORACLE instance started.
Total System Global Area 1069252608 bytes
Fixed Size 2109352 bytes
Variable Size 427823192 bytes
Database Buffers 624951296 bytes
Redo Buffers 14368768 bytes
SQL>
|
List backup piece of controlfile on source system
RMAN>
list backup of controlfile;
using
target database control file instead of recovery catalog
List
of Backup Sets
===================
BS
Key Type LV Size Device Type Elapsed
Time Completion Time
-------
---- -- ---------- ----------- ------------ ---------------
3
Full 40.27M
DISK 00:00:02
21-JAN-13
BP Key: 3 Status: AVAILABLE Compressed: NO Tag:
TAG20130121T092605
Piece Name: /data/R12_ERP/rman_backup/ERPTEST_DB_03nvv8o3_3_1
Control File Included: Ckp SCN: 77924707 Ckp time: 21-JAN-13
BS
Key Type LV Size Device Type Elapsed
Time Completion Time
-------
---- -- ---------- ----------- ------------ ---------------
6
Full 40.27M
DISK 00:00:03
03-FEB-13
BP Key: 6 Status: AVAILABLE Compressed: NO Tag:
TAG20130203T120813
Piece Name: /data/R12_ERP/rman_backup/3feb2012_backup/ERPTEST_DB_06o11r42_6_1
Control File Included: Ckp SCN: 78217166 Ckp time:
03-FEB-13
BS
Key Type LV Size Device Type Elapsed
Time Completion Time
-------
---- -- ---------- ----------- ------------ ---------------
10
Full 40.27M
DISK 00:00:02
03-FEB-13
BP Key: 10 Status: AVAILABLE Compressed: NO Tag:
TAG20130203T131743
Piece Name: /data/R12_ERP/db/tech_st/11.1.0/dbs/c-1262470248-20130203-00
Control File Included: Ckp SCN: 78223859 Ckp time:
03-FEB-13
Restore control file and mount database
bash-3.00$
pwd
/appl/rman_backup/3feb2012_backup
bash-3.00$
ls -lrt
total
48953331
-rw-r-----
1 oraclone dbaclone 42237952 Feb 3 14:14 c-1262470248-20130203-00
-rw-r-----
1 oraclone dbaclone 42237952 Feb 3 14:15 ERPTEST_DB_06o11r42_6_1
-rw-r-----
1 oraclone dbaclone 24959320064 Feb 3 14:37 ERPTEST_DB_05o11qhe_5_1
bash-3.00$
pwd
/appl/rman_backup/3feb2012_backup
bash-3.00$
rman target / nocatalog
Recovery
Manager: Release 11.1.0.7.0 - Production on Mon Feb 4 10:08:26 2013
Copyright
(c) 1982, 2007, Oracle. All rights reserved.
connected
to target database: ERPTEST (not mounted)
using
target database control file instead of recovery catalog
RMAN>
restore controlfile from
'/appl/rman_backup/3feb2012_backup/c-1262470248-20130203-00';
Starting
restore at 04-FEB-13
allocated
channel: ORA_DISK_1
channel
ORA_DISK_1: SID=383 device type=DISK
channel
ORA_DISK_1: restoring control file
channel
ORA_DISK_1: restore complete, elapsed time: 00:00:01
output
file name=/appl/ERP_CLONE/dbclone/clone_data/cntrl01.dbf
Finished
restore at 04-FEB-13
RMAN>
alter database mount;
database
mounted
released
channel: ORA_DISK_1
Catalog backup Pieces (not required if location of rman bkp same on target)
RMAN>
catalog backuppiece
'/appl/rman_backup/3feb2012_backup/ERPTEST_DB_06o11r42_6_1';
cataloged
backup piece
backup
piece handle=/appl/rman_backup/3feb2012_backup/ERPTEST_DB_06o11r42_6_1 RECID=10
STAMP=806494720
RMAN>
catalog backuppiece
'/appl/rman_backup/3feb2012_backup/ERPTEST_DB_05o11qhe_5_1';
cataloged
backup piece
backup
piece handle=/appl/rman_backup/3feb2012_backup/ERPTEST_DB_05o11qhe_5_1 RECID=11
STAMP=806494728
RMAN>
catalog backuppiece '/appl/rman_backup/3feb2012_backup/db_806418437_7.bkp';
cataloged
backup piece
backup
piece handle=/appl/rman_backup/3feb2012_backup/db_806418437_7.bkp RECID=12
STAMP=806498596
RMAN> catalog backuppiece
'/appl/rman_backup/3feb2012_backup/db_806419062_9.bkp';
cataloged
backup piece
backup
piece handle=/appl/rman_backup/3feb2012_backup/db_806419062_9.bkp RECID=13
STAMP=806498610
Prepare script for rman restore and run script (If target location is same
"ste newname" not required)
bash-3.00$
cat rman_restore.sql
run {
set
newname for datafile 1 to '/appl/ERP_CLONE/dbclone/clone_data/system01.dbf';
set
newname for datafile 2 to '/appl/ERP_CLONE/dbclone/clone_data/system02.dbf';
set
newname for datafile 3 to '/appl/ERP_CLONE/dbclone/clone_data/system03.dbf';
set
newname for datafile 4 to '/appl/ERP_CLONE/dbclone/clone_data/system04.dbf';
set
newname for datafile 5 to '/appl/ERP_CLONE/dbclone/clone_data/system05.dbf';
set
newname for datafile 6 to '/appl/ERP_CLONE/dbclone/clone_data/system06.dbf';
set
newname for datafile 7 to '/appl/ERP_CLONE/dbclone/clone_data/system07.dbf';
set
newname for datafile 8 to '/appl/ERP_CLONE/dbclone/clone_data/system08.dbf';
set
newname for datafile 9 to '/appl/ERP_CLONE/dbclone/clone_data/system09.dbf';
set
newname for datafile 10 to '/appl/ERP_CLONE/dbclone/clone_data/system10.dbf';
set
newname for datafile 11 to '/appl/ERP_CLONE/dbclone/clone_data/system11.dbf';
set
newname for datafile 12 to '/appl/ERP_CLONE/dbclone/clone_data/undo01.dbf';
set
newname for datafile 13 to
'/appl/ERP_CLONE/dbclone/clone_data/a_archive01.dbf';
set
newname for datafile 14 to '/appl/ERP_CLONE/dbclone/clone_data/a_int01.dbf';
set
newname for datafile 15 to '/appl/ERP_CLONE/dbclone/clone_data/a_media01.dbf';
set
newname for datafile 16 to '/appl/ERP_CLONE/dbclone/clone_data/a_nolog01.dbf';
set
newname for datafile 17 to '/appl/ERP_CLONE/dbclone/clone_data/a_queue01.dbf';
set
newname for datafile 18 to '/appl/ERP_CLONE/dbclone/clone_data/a_queue02.dbf';
set
newname for datafile 19 to '/appl/ERP_CLONE/dbclone/clone_data/a_ref01.dbf';
set
newname for datafile 20 to '/appl/ERP_CLONE/dbclone/clone_data/a_ref02.dbf';
set
newname for datafile 21 to '/appl/ERP_CLONE/dbclone/clone_data/a_summ01.dbf';
set
newname for datafile 22 to '/appl/ERP_CLONE/dbclone/clone_data/a_txn_data101.dbf';
set
newname for datafile 23 to
'/appl/ERP_CLONE/dbclone/clone_data/a_txn_data102.dbf';
set
newname for datafile 24 to
'/appl/ERP_CLONE/dbclone/clone_data/a_txn_data103.dbf';
set
newname for datafile 25 to '/appl/ERP_CLONE/dbclone/clone_data/a_txn_ind01.dbf';
set
newname for datafile 26 to
'/appl/ERP_CLONE/dbclone/clone_data/a_txn_ind02.dbf';
set
newname for datafile 27 to
'/appl/ERP_CLONE/dbclone/clone_data/a_txn_ind03.dbf';
set
newname for datafile 28 to '/appl/ERP_CLONE/dbclone/clone_data/a_txn_ind04.dbf';
set
newname for datafile 29 to
'/appl/ERP_CLONE/dbclone/clone_data/a_txn_ind05.dbf';
set
newname for datafile 30 to '/appl/ERP_CLONE/dbclone/clone_data/ctxd01.dbf';
set
newname for datafile 31 to '/appl/ERP_CLONE/dbclone/clone_data/odm.dbf';
set
newname for datafile 32 to '/appl/ERP_CLONE/dbclone/clone_data/olap.dbf';
set
newname for datafile 33 to '/appl/ERP_CLONE/dbclone/clone_data/owad01.dbf';
set
newname for datafile 34 to '/appl/ERP_CLONE/dbclone/clone_data/portal01.dbf';
set
newname for datafile 35 to '/appl/ERP_CLONE/dbclone/clone_data/sysaux01.dbf';
set
newname for datafile 36 to
'/appl/ERP_CLONE/dbclone/clone_data/apps_ts_tools01.dbf';
set
newname for datafile 37 to '/appl/ERP_CLONE/dbclone/clone_data/interim.dbf';
set
newname for datafile 38 to
'/appl/ERP_CLONE/dbclone/clone_data/a_txn_data14.dbf';
restore
database;
switch
datafile all; }
bash-3.00$
pwd
/export/home/oraclone
RMAN>
@/export/home/oraclone/rman_restore.sql
RMAN>
run {
2>
set newname for datafile 1 to
'/appl/ERP_CLONE/dbclone/clone_data/system01.dbf';
3>
set newname for datafile 2 to
'/appl/ERP_CLONE/dbclone/clone_data/system02.dbf';
4>
set newname for datafile 3 to
'/appl/ERP_CLONE/dbclone/clone_data/system03.dbf';
5>
set newname for datafile 4 to
'/appl/ERP_CLONE/dbclone/clone_data/system04.dbf';
6>
set newname for datafile 5 to
'/appl/ERP_CLONE/dbclone/clone_data/system05.dbf';
7>
set newname for datafile 6 to
'/appl/ERP_CLONE/dbclone/clone_data/system06.dbf';
8>
set newname for datafile 7 to '/appl/ERP_CLONE/dbclone/clone_data/system07.dbf';
9>
set newname for datafile 8 to
'/appl/ERP_CLONE/dbclone/clone_data/system08.dbf';
10>
set newname for datafile 9 to
'/appl/ERP_CLONE/dbclone/clone_data/system09.dbf';
11>
set newname for datafile 10 to '/appl/ERP_CLONE/dbclone/clone_data/system10.dbf';
12>
set newname for datafile 11 to
'/appl/ERP_CLONE/dbclone/clone_data/system11.dbf';
13>
set newname for datafile 12 to '/appl/ERP_CLONE/dbclone/clone_data/undo01.dbf';
14>
set newname for datafile 13 to '/appl/ERP_CLONE/dbclone/clone_data/a_archive01.dbf';
15>
set newname for datafile 14 to
'/appl/ERP_CLONE/dbclone/clone_data/a_int01.dbf';
16>
set newname for datafile 15 to
'/appl/ERP_CLONE/dbclone/clone_data/a_media01.dbf';
17>
set newname for datafile 16 to
'/appl/ERP_CLONE/dbclone/clone_data/a_nolog01.dbf';
18>
set newname for datafile 17 to
'/appl/ERP_CLONE/dbclone/clone_data/a_queue01.dbf';
19>
set newname for datafile 18 to
'/appl/ERP_CLONE/dbclone/clone_data/a_queue02.dbf';
20>
set newname for datafile 19 to
'/appl/ERP_CLONE/dbclone/clone_data/a_ref01.dbf';
21>
set newname for datafile 20 to
'/appl/ERP_CLONE/dbclone/clone_data/a_ref02.dbf';
22>
set newname for datafile 21 to
'/appl/ERP_CLONE/dbclone/clone_data/a_summ01.dbf';
23>
set newname for datafile 22 to
'/appl/ERP_CLONE/dbclone/clone_data/a_txn_data101.dbf';
24>
set newname for datafile 23 to
'/appl/ERP_CLONE/dbclone/clone_data/a_txn_data102.dbf';
25>
set newname for datafile 24 to
'/appl/ERP_CLONE/dbclone/clone_data/a_txn_data103.dbf';
26>
set newname for datafile 25 to
'/appl/ERP_CLONE/dbclone/clone_data/a_txn_ind01.dbf';
27>
set newname for datafile 26 to
'/appl/ERP_CLONE/dbclone/clone_data/a_txn_ind02.dbf';
28>
set newname for datafile 27 to
'/appl/ERP_CLONE/dbclone/clone_data/a_txn_ind03.dbf';
29>
set newname for datafile 28 to
'/appl/ERP_CLONE/dbclone/clone_data/a_txn_ind04.dbf';
30>
set newname for datafile 29 to
'/appl/ERP_CLONE/dbclone/clone_data/a_txn_ind05.dbf';
31>
set newname for datafile 30 to '/appl/ERP_CLONE/dbclone/clone_data/ctxd01.dbf';
32>
set newname for datafile 31 to '/appl/ERP_CLONE/dbclone/clone_data/odm.dbf';
33>
set newname for datafile 32 to '/appl/ERP_CLONE/dbclone/clone_data/olap.dbf';
34>
set newname for datafile 33 to '/appl/ERP_CLONE/dbclone/clone_data/owad01.dbf';
35>
set newname for datafile 34 to
'/appl/ERP_CLONE/dbclone/clone_data/portal01.dbf';
36>
set newname for datafile 35 to
'/appl/ERP_CLONE/dbclone/clone_data/sysaux01.dbf';
37>
set newname for datafile 36 to
'/appl/ERP_CLONE/dbclone/clone_data/apps_ts_tools01.dbf';
38>
set newname for datafile 37 to
'/appl/ERP_CLONE/dbclone/clone_data/interim.dbf';
39>
set newname for datafile 38 to
'/appl/ERP_CLONE/dbclone/clone_data/a_txn_data14.dbf';
40>
restore database;
41>
switch datafile all; }
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
executing
command: SET NEWNAME
Starting
restore at 04-FEB-13
allocated
channel: ORA_DISK_1
channel
ORA_DISK_1: SID=381 device type=DISK
channel
ORA_DISK_1: starting datafile backup set restore
channel
ORA_DISK_1: specifying datafile(s) to restore from backup set
channel
ORA_DISK_1: restoring datafile 00001 to
/appl/ERP_CLONE/dbclone/clone_data/system01.dbf
channel
ORA_DISK_1: restoring datafile 00002 to
/appl/ERP_CLONE/dbclone/clone_data/system02.dbf
channel
ORA_DISK_1: restoring datafile 00003 to
/appl/ERP_CLONE/dbclone/clone_data/system03.dbf
channel
ORA_DISK_1: restoring datafile 00004 to /appl/ERP_CLONE/dbclone/clone_data/system04.dbf
channel
ORA_DISK_1: restoring datafile 00005 to
/appl/ERP_CLONE/dbclone/clone_data/system05.dbf
channel
ORA_DISK_1: restoring datafile 00006 to
/appl/ERP_CLONE/dbclone/clone_data/system06.dbf
channel
ORA_DISK_1: restoring datafile 00007 to /appl/ERP_CLONE/dbclone/clone_data/system07.dbf
channel
ORA_DISK_1: restoring datafile 00008 to
/appl/ERP_CLONE/dbclone/clone_data/system08.dbf
channel
ORA_DISK_1: restoring datafile 00009 to
/appl/ERP_CLONE/dbclone/clone_data/system09.dbf
channel
ORA_DISK_1: restoring datafile 00010 to
/appl/ERP_CLONE/dbclone/clone_data/system10.dbf
channel
ORA_DISK_1: restoring datafile 00011 to
/appl/ERP_CLONE/dbclone/clone_data/system11.dbf
channel
ORA_DISK_1: restoring datafile 00012 to /appl/ERP_CLONE/dbclone/clone_data/undo01.dbf
channel
ORA_DISK_1: restoring datafile 00013 to
/appl/ERP_CLONE/dbclone/clone_data/a_archive01.dbf
channel
ORA_DISK_1: restoring datafile 00014 to
/appl/ERP_CLONE/dbclone/clone_data/a_int01.dbf
channel
ORA_DISK_1: restoring datafile 00015 to /appl/ERP_CLONE/dbclone/clone_data/a_media01.dbf
channel
ORA_DISK_1: restoring datafile 00016 to
/appl/ERP_CLONE/dbclone/clone_data/a_nolog01.dbf
channel
ORA_DISK_1: restoring datafile 00017 to
/appl/ERP_CLONE/dbclone/clone_data/a_queue01.dbf
channel
ORA_DISK_1: restoring datafile 00018 to
/appl/ERP_CLONE/dbclone/clone_data/a_queue02.dbf
channel
ORA_DISK_1: restoring datafile 00019 to
/appl/ERP_CLONE/dbclone/clone_data/a_ref01.dbf
channel
ORA_DISK_1: restoring datafile 00020 to /appl/ERP_CLONE/dbclone/clone_data/a_ref02.dbf
channel
ORA_DISK_1: restoring datafile 00021 to
/appl/ERP_CLONE/dbclone/clone_data/a_summ01.dbf
channel
ORA_DISK_1: restoring datafile 00022 to
/appl/ERP_CLONE/dbclone/clone_data/a_txn_data101.dbf
channel
ORA_DISK_1: restoring datafile 00023 to
/appl/ERP_CLONE/dbclone/clone_data/a_txn_data102.dbf
channel
ORA_DISK_1: restoring datafile 00024 to
/appl/ERP_CLONE/dbclone/clone_data/a_txn_data103.dbf
channel
ORA_DISK_1: restoring datafile 00025 to
/appl/ERP_CLONE/dbclone/clone_data/a_txn_ind01.dbf
channel
ORA_DISK_1: restoring datafile 00026 to
/appl/ERP_CLONE/dbclone/clone_data/a_txn_ind02.dbf
channel
ORA_DISK_1: restoring datafile 00027 to
/appl/ERP_CLONE/dbclone/clone_data/a_txn_ind03.dbf
channel
ORA_DISK_1: restoring datafile 00028 to /appl/ERP_CLONE/dbclone/clone_data/a_txn_ind04.dbf
channel
ORA_DISK_1: restoring datafile 00029 to
/appl/ERP_CLONE/dbclone/clone_data/a_txn_ind05.dbf
channel
ORA_DISK_1: restoring datafile 00030 to
/appl/ERP_CLONE/dbclone/clone_data/ctxd01.dbf
channel
ORA_DISK_1: restoring datafile 00031 to
/appl/ERP_CLONE/dbclone/clone_data/odm.dbf
channel
ORA_DISK_1: restoring datafile 00032 to
/appl/ERP_CLONE/dbclone/clone_data/olap.dbf
channel
ORA_DISK_1: restoring datafile 00033 to
/appl/ERP_CLONE/dbclone/clone_data/owad01.dbf
channel
ORA_DISK_1: restoring datafile 00034 to
/appl/ERP_CLONE/dbclone/clone_data/portal01.dbf
channel
ORA_DISK_1: restoring datafile 00035 to
/appl/ERP_CLONE/dbclone/clone_data/sysaux01.dbf
channel
ORA_DISK_1: restoring datafile 00036 to /appl/ERP_CLONE/dbclone/clone_data/apps_ts_tools01.dbf
channel
ORA_DISK_1: restoring datafile 00037 to
/appl/ERP_CLONE/dbclone/clone_data/interim.dbf
channel
ORA_DISK_1: restoring datafile 00038 to
/appl/ERP_CLONE/dbclone/clone_data/a_txn_data14.dbf
channel
ORA_DISK_1: reading from backup piece
/data/R12_ERP/rman_backup/3feb2012_backup/ERPTEST_DB_05o11qhe_5_1
channel
ORA_DISK_1: errors found reading piece
handle=/data/R12_ERP/rman_backup/3feb2012_backup/ERPTEST_DB_05o11qhe_5_1
channel
ORA_DISK_1: failover to piece handle=/appl/rman_backup/3feb2012_backup/ERPTEST_DB_05o11qhe_5_1
tag=TAG20130203T120813
channel
ORA_DISK_1: restored backup piece 1
channel
ORA_DISK_1: restore complete, elapsed time: 00:12:21
Finished
restore at 04-FEB-13
datafile
1 switched to datafile copy
input
datafile copy RECID=39 STAMP=806496604 file
name=/appl/ERP_CLONE/dbclone/clone_data/system01.dbf
datafile
2 switched to datafile copy
input
datafile copy RECID=40 STAMP=806496605 file
name=/appl/ERP_CLONE/dbclone/clone_data/system02.dbf
datafile
3 switched to datafile copy
input
datafile copy RECID=41 STAMP=806496605 file
name=/appl/ERP_CLONE/dbclone/clone_data/system03.dbf
datafile
4 switched to datafile copy
input
datafile copy RECID=42 STAMP=806496606 file
name=/appl/ERP_CLONE/dbclone/clone_data/system04.dbf
datafile
5 switched to datafile copy
input
datafile copy RECID=43 STAMP=806496606 file
name=/appl/ERP_CLONE/dbclone/clone_data/system05.dbf
datafile
6 switched to datafile copy
input
datafile copy RECID=44 STAMP=806496607 file name=/appl/ERP_CLONE/dbclone/clone_data/system06.dbf
datafile
7 switched to datafile copy
input
datafile copy RECID=45 STAMP=806496607 file
name=/appl/ERP_CLONE/dbclone/clone_data/system07.dbf
datafile
8 switched to datafile copy
input
datafile copy RECID=46 STAMP=806496608 file
name=/appl/ERP_CLONE/dbclone/clone_data/system08.dbf
datafile
9 switched to datafile copy
input
datafile copy RECID=47 STAMP=806496609 file
name=/appl/ERP_CLONE/dbclone/clone_data/system09.dbf
datafile
10 switched to datafile copy
input
datafile copy RECID=48 STAMP=806496609 file
name=/appl/ERP_CLONE/dbclone/clone_data/system10.dbf
datafile
11 switched to datafile copy
input
datafile copy RECID=49 STAMP=806496610 file
name=/appl/ERP_CLONE/dbclone/clone_data/system11.dbf
datafile
12 switched to datafile copy
input
datafile copy RECID=50 STAMP=806496611 file
name=/appl/ERP_CLONE/dbclone/clone_data/undo01.dbf
datafile
13 switched to datafile copy
input
datafile copy RECID=51 STAMP=806496612 file
name=/appl/ERP_CLONE/dbclone/clone_data/a_archive01.dbf
datafile
14 switched to datafile copy
input
datafile copy RECID=52 STAMP=806496612 file
name=/appl/ERP_CLONE/dbclone/clone_data/a_int01.dbf
datafile
15 switched to datafile copy
input
datafile copy RECID=53 STAMP=806496613 file name=/appl/ERP_CLONE/dbclone/clone_data/a_media01.dbf
datafile
16 switched to datafile copy
input
datafile copy RECID=54 STAMP=806496613 file
name=/appl/ERP_CLONE/dbclone/clone_data/a_nolog01.dbf
datafile
17 switched to datafile copy
input
datafile copy RECID=55 STAMP=806496614 file name=/appl/ERP_CLONE/dbclone/clone_data/a_queue01.dbf
datafile
18 switched to datafile copy
input
datafile copy RECID=56 STAMP=806496614 file
name=/appl/ERP_CLONE/dbclone/clone_data/a_queue02.dbf
datafile
19 switched to datafile copy
input
datafile copy RECID=57 STAMP=806496615 file
name=/appl/ERP_CLONE/dbclone/clone_data/a_ref01.dbf
datafile
20 switched to datafile copy
input
datafile copy RECID=58 STAMP=806496615 file
name=/appl/ERP_CLONE/dbclone/clone_data/a_ref02.dbf
datafile
21 switched to datafile copy
input
datafile copy RECID=59 STAMP=806496616 file
name=/appl/ERP_CLONE/dbclone/clone_data/a_summ01.dbf
datafile
22 switched to datafile copy
input
datafile copy RECID=60 STAMP=806496617 file
name=/appl/ERP_CLONE/dbclone/clone_data/a_txn_data101.dbf
datafile
23 switched to datafile copy
input
datafile copy RECID=61 STAMP=806496618 file
name=/appl/ERP_CLONE/dbclone/clone_data/a_txn_data102.dbf
datafile
24 switched to datafile copy
input
datafile copy RECID=62 STAMP=806496619 file name=/appl/ERP_CLONE/dbclone/clone_data/a_txn_data103.dbf
datafile
25 switched to datafile copy
input
datafile copy RECID=63 STAMP=806496619 file
name=/appl/ERP_CLONE/dbclone/clone_data/a_txn_ind01.dbf
datafile
26 switched to datafile copy
input
datafile copy RECID=64 STAMP=806496620 file name=/appl/ERP_CLONE/dbclone/clone_data/a_txn_ind02.dbf
datafile
27 switched to datafile copy
input
datafile copy RECID=65 STAMP=806496620 file
name=/appl/ERP_CLONE/dbclone/clone_data/a_txn_ind03.dbf
datafile
28 switched to datafile copy
input
datafile copy RECID=66 STAMP=806496621 file
name=/appl/ERP_CLONE/dbclone/clone_data/a_txn_ind04.dbf
datafile
29 switched to datafile copy
input
datafile copy RECID=67 STAMP=806496621 file
name=/appl/ERP_CLONE/dbclone/clone_data/a_txn_ind05.dbf
datafile
30 switched to datafile copy
input
datafile copy RECID=68 STAMP=806496622 file
name=/appl/ERP_CLONE/dbclone/clone_data/ctxd01.dbf
datafile
31 switched to datafile copy
input
datafile copy RECID=69 STAMP=806496622 file
name=/appl/ERP_CLONE/dbclone/clone_data/odm.dbf
datafile
32 switched to datafile copy
input
datafile copy RECID=70 STAMP=806496623 file
name=/appl/ERP_CLONE/dbclone/clone_data/olap.dbf
datafile
33 switched to datafile copy
input
datafile copy RECID=71 STAMP=806496623 file
name=/appl/ERP_CLONE/dbclone/clone_data/owad01.dbf
datafile
34 switched to datafile copy
input
datafile copy RECID=72 STAMP=806496624 file
name=/appl/ERP_CLONE/dbclone/clone_data/portal01.dbf
datafile
35 switched to datafile copy
input
datafile copy RECID=73 STAMP=806496624 file name=/appl/ERP_CLONE/dbclone/clone_data/sysaux01.dbf
datafile
36 switched to datafile copy
input
datafile copy RECID=74 STAMP=806496625 file
name=/appl/ERP_CLONE/dbclone/clone_data/apps_ts_tools01.dbf
datafile
37 switched to datafile copy
input
datafile copy RECID=75 STAMP=806496625 file
name=/appl/ERP_CLONE/dbclone/clone_data/interim.dbf
datafile
38 switched to datafile copy
input
datafile copy RECID=76 STAMP=806496626 file
name=/appl/ERP_CLONE/dbclone/clone_data/a_txn_data14.dbf
RMAN>
**end-of-file**
RMAN>
List backup of archive logs and recover database until last available seq
RMAN>
list backup of archivelog all;
List
of Backup Sets
===================
BS
Key Size Device Type Elapsed Time Completion Time
-------
---------- ----------- ------------ ---------------
1 822.21M DISK
00:00:11 21-JAN-13
BP Key: 1 Status: AVAILABLE Compressed: NO Tag: TAG20130121T092549
Piece Name:
/data/R12_ERP/rman_backup/ERPTEST_DB_01nvv84u_1_1
List of Archived Logs in backup set 1
Thrd Seq
Low SCN Low Time Next SCN
Next Time
---- ------- ---------- --------- ----------
---------
1
22 77784979 20-JAN-13 77924429 21-JAN-13
BS
Key Size Device Type Elapsed Time Completion Time
-------
---------- ----------- ------------ ---------------
4 103.00K DISK
00:00:00 21-JAN-13
BP Key: 4 Status: AVAILABLE Compressed: NO Tag: TAG20130121T093606
Piece Name:
/data/R12_ERP/rman_backup/ERPTEST_DB_04nvv8o6_4_1
List of Archived Logs in backup set 4
Thrd Seq
Low SCN Low Time Next SCN
Next Time
---- ------- ---------- --------- ----------
---------
1
23 77924429 21-JAN-13 77924713 21-JAN-13
BS
Key Size Device Type Elapsed Time Completion Time
-------
---------- ----------- ------------ ---------------
7 1.20G DISK 00:00:22 03-FEB-13
BP Key: 7 Status: AVAILABLE Compressed: NO Tag: FULL_DB
Piece Name:
/data/R12_ERP/rman_backup/3feb2013_Bkp/db_806418437_7.bkp
List of Archived Logs in backup set 7
Thrd Seq
Low SCN Low Time Next SCN
Next Time
---- ------- ---------- --------- ----------
---------
1
22 77784979 20-JAN-13 77924429 21-JAN-13
1
23 77924429 21-JAN-13 77924713 21-JAN-13
1
24 77924713 21-JAN-13 78223108 03-FEB-13
BS
Key Size Device Type Elapsed Time Completion Time
-------
---------- ----------- ------------ ---------------
9 226.00K DISK
00:00:00 03-FEB-13
BP Key: 9
Status: AVAILABLE Compressed:
NO Tag: FULL_DB
Piece Name:
/data/R12_ERP/rman_backup/3feb2013_Bkp/db_806419062_9.bkp
List of Archived Logs in backup set 9
Thrd Seq
Low SCN Low Time Next SCN
Next Time
---- ------- ---------- --------- ----------
---------
1
25 78223108 03-FEB-13 78223850 03-FEB-13
RMAN>
RUN {
2>
set until sequence 26 thread 1;
3>
recover database;
4>
}
executing
command: SET until clause
Starting
recover at 04-FEB-13
using
channel ORA_DISK_1
starting
media recovery
channel
ORA_DISK_1: starting archived log restore to default destination
channel
ORA_DISK_1: restoring archived log
archived
log thread=1 sequence=24
channel
ORA_DISK_1: reading from backup piece /data/R12_ERP/rman_backup/3feb2013_Bkp/db_806418437_7.bkp
channel
ORA_DISK_1: errors found reading piece
handle=/data/R12_ERP/rman_backup/3feb2013_Bkp/db_806418437_7.bkp
channel
ORA_DISK_1: failover to piece
handle=/appl/rman_backup/3feb2012_backup/db_806418437_7.bkp tag=FULL_DB
channel
ORA_DISK_1: restored backup piece 1
channel
ORA_DISK_1: restore complete, elapsed time: 00:00:15
archived
log file name=/appl/ERP_CLONE/dbclone/clone_data/archive/1_24_805117931.dbf
thread=1 sequence=24
channel
ORA_DISK_1: starting archived log restore to default destination
channel
ORA_DISK_1: restoring archived log
archived
log thread=1 sequence=25
channel
ORA_DISK_1: reading from backup piece
/data/R12_ERP/rman_backup/3feb2013_Bkp/db_806419062_9.bkp
channel
ORA_DISK_1: errors found reading piece handle=/data/R12_ERP/rman_backup/3feb2013_Bkp/db_806419062_9.bkp
channel
ORA_DISK_1: failover to piece
handle=/appl/rman_backup/3feb2012_backup/db_806419062_9.bkp tag=FULL_DB
channel
ORA_DISK_1: restored backup piece 1
channel
ORA_DISK_1: restore complete, elapsed time: 00:00:01
archived
log file name=/appl/ERP_CLONE/dbclone/clone_data/archive/1_25_805117931.dbf
thread=1 sequence=25
media
recovery complete, elapsed time: 00:00:01
Finished
recover at 04-FEB-13
RMAN>
Rename online LOGFILES:
bash-3.00$
sqlplus / as sysdba
SQL*Plus:
Release 11.1.0.7.0 - Production on Mon Feb 4 13:36:24 2013
Copyright
(c) 1982, 2008, Oracle. All rights
reserved.
Connected
to:
Oracle
Database 11g Enterprise Edition Release 11.1.0.7.0 - 64bit Production
With
the Partitioning, OLAP, Data Mining and Real Application Testing options
SQL>
select member from v$logfile;
MEMBER
--------------------------------------------------------------------------------
/data/R12_ERP/db/apps_st/data/log02a.dbf
/data/R12_ERP/db/apps_st/data/log02b.dbf
/data/R12_ERP/db/apps_st/data/log01a.dbf
/data/R12_ERP/db/apps_st/data/log01b.dbf
SQL>
alter database rename file '/data/R12_ERP/db/apps_st/data/log02a.dbf' to
'/appl/ERP_CLONE/dbclone/clone_data/log02a.dbf';
Database
altered.
SQL>
alter database rename file '/data/R12_ERP/db/apps_st/data/log02b.dbf' to
'/appl/ERP_CLONE/dbclone/clone_data/log02b.dbf'
2 ;
Database
altered.
SQL>
alter database rename file '/data/R12_ERP/db/apps_st/data/log01a.dbf' to
'/appl/ERP_CLONE/dbclone/clone_data/log01a.dbf';
Database
altered.
SQL>
alter database rename file '/data/R12_ERP/db/apps_st/data/log01b.dbf' to
'/appl/ERP_CLONE/dbclone/clone_data/log01b.dbf';
Database
altered.
SQL>
Check and Open database using resetlogs:
Select
name from v$datafile where name like '%MISS%';
Select distinct status from v$datafile;
Select
distinct CHECKPOINT_CHANGE# from v$datafile;
SQL>
alter database open resetlogs;
Database
altered.
SQL>
Create and drop TEMP tablespace
SQL>
create TEMPORARY TABLESPACE TEMP3 TEMPFILE '/appl/ERP_CLONE/dbclone/clone_data/temp003.dbf'
size 2048M;
Tablespace
created.
SQL>
ALTER DATABASE DEFAULT TEMPORARY TABLESPACE temp3;
Database
altered.
SQL>
drop tablespace temp1 including contents and datafiles;
Tablespace
dropped.
SQL>
drop tablespace temp2 including contents and datafiles;
Tablespace
dropped.
SQL>
Change database name using "nid" command
bash-3.00$
sqlplus / as sysdba
SQL*Plus:
Release 11.1.0.7.0 - Production on Mon Feb 4 13:59:47 2013
Copyright
(c) 1982, 2008, Oracle. All rights
reserved.
Connected
to:
Oracle
Database 11g Enterprise Edition Release 11.1.0.7.0 - 64bit Production
With
the Partitioning, OLAP, Data Mining and Real Application Testing options
SQL>
shut immediate;
Database
closed.
Database
dismounted.
ORACLE
instance shut down.
SQL>
startup mount
ORACLE
instance started.
Total
System Global Area 1069252608 bytes
Fixed
Size 2109352 bytes
Variable
Size 427823192 bytes
Database
Buffers 624951296 bytes
Redo
Buffers 14368768 bytes
Database
mounted.
SQL>
exit
Disconnected
from Oracle Database 11g Enterprise Edition Release 11.1.0.7.0 - 64bit
Production
With
the Partitioning, OLAP, Data Mining and Real Application Testing options
bash-3.00$
nid TARGET=SYS/oracle DBNAME=CLONE
DBNEWID:
Release 11.1.0.7.0 - Production on Mon Feb 4 14:02:31 2013
Copyright
(c) 1982, 2007, Oracle. All rights
reserved.
Connected
to database ERPTEST (DBID=1262470248)
Connected
to server version 11.1.0
Control
Files in database:
/appl/ERP_CLONE/dbclone/clone_data/cntrl01.dbf
Change
database ID and database name ERPTEST to CLONE? (Y/[N]) => Y
Proceeding
with operation
Changing
database ID from 1262470248 to 1005337143
Changing
database name from ERPTEST to CLONE
Control File /appl/ERP_CLONE/dbclone/clone_data/cntrl01.dbf
- modified
Datafile
/appl/ERP_CLONE/dbclone/clone_data/system01.db - dbid changed, wrote new name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/system02.db - dbid changed, wrote new name
Datafile /appl/ERP_CLONE/dbclone/clone_data/system03.db
- dbid changed, wrote new name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/system04.db - dbid changed, wrote new name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/system05.db - dbid changed, wrote new name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/system06.db - dbid changed, wrote new name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/system07.db - dbid changed, wrote new name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/system08.db - dbid changed, wrote new name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/system09.db - dbid changed, wrote new name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/system10.db - dbid changed, wrote new name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/system11.db - dbid changed, wrote new name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/undo01.db - dbid changed, wrote new name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/a_archive01.db - dbid changed, wrote new
name
Datafile /appl/ERP_CLONE/dbclone/clone_data/a_int01.db
- dbid changed, wrote new name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/a_media01.db - dbid changed, wrote new name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/a_nolog01.db - dbid changed, wrote new name
Datafile /appl/ERP_CLONE/dbclone/clone_data/a_queue01.db
- dbid changed, wrote new name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/a_queue02.db - dbid changed, wrote new name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/a_ref01.db - dbid changed, wrote new name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/a_ref02.db - dbid changed, wrote new name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/a_summ01.db - dbid changed, wrote new name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/a_txn_data101.db - dbid changed, wrote new
name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/a_txn_data102.db - dbid changed, wrote new
name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/a_txn_data103.db - dbid changed, wrote new
name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/a_txn_ind01.db - dbid changed, wrote new
name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/a_txn_ind02.db - dbid changed, wrote new
name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/a_txn_ind03.db - dbid changed, wrote new
name
Datafile /appl/ERP_CLONE/dbclone/clone_data/a_txn_ind04.db
- dbid changed, wrote new name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/a_txn_ind05.db - dbid changed, wrote new
name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/ctxd01.db - dbid changed, wrote new name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/odm.db - dbid changed, wrote new name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/olap.db - dbid changed, wrote new name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/owad01.db - dbid changed, wrote new name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/portal01.db - dbid changed, wrote new name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/sysaux01.db - dbid changed, wrote new name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/apps_ts_tools01.db - dbid changed, wrote new
name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/interim.db - dbid changed, wrote new name
Datafile
/appl/ERP_CLONE/dbclone/clone_data/a_txn_data14.db - dbid changed, wrote new
name
Datafile /appl/ERP_CLONE/dbclone/clone_data/temp003.db
- dbid changed, wrote new name
Control File
/appl/ERP_CLONE/dbclone/clone_data/cntrl01.dbf - dbid changed, wrote new name
Instance shut down
Database
name changed to CLONE.
Modify
parameter file and generate a new password file before restarting.
Database
ID for database CLONE changed to 1005337143.
All
previous backups and archived redo logs for this database are unusable.
Database
has been shutdown, open database with RESETLOGS option.
Succesfully
changed database name and ID.
DBNEWID
- Completed succesfully.
bash-3.00$
Change ORACLE_SID in environment file and start database with reset logs:
bash-3.00$
grep ORACLE_SID CLONE_testappl.env
ORACLE_SID="CLONE"
export
ORACLE_SID
bash-3.00$
pwd
/appl/ERP_CLONE/dbclone/tech_st/11.1.0
bash-3.00$
echo $ORACLE_SID
CLONE
bash-3.00$
sqlplus / as sysdba
SQL*Plus:
Release 11.1.0.7.0 - Production on Mon Feb 4 14:12:56 2013
Copyright
(c) 1982, 2008, Oracle. All rights
reserved.
Connected
to an idle instance.
SQL>
startup mount
ORACLE
instance started.
Total
System Global Area 1069252608 bytes
Fixed
Size 2109352 bytes
Variable
Size 427823192 bytes
Database
Buffers 624951296 bytes
Redo
Buffers 14368768 bytes
Database
mounted.
SQL>
alter database open resetlogs;
Database
altered.
SQL>
select open_mode, name from v$database;
OPEN_MODE NAME
----------
---------
READ
WRITE CLONE
Update failed login attempts
Before starting adcfgclone
run the following command as system or sys user
Alter profile default
limit FAILED_LOGIN_ATTEMPTS UNLIMITED
Run Autoconfig on DB Tier
bash-3.00$ adautocfg.sh
Enter the APPS user password:
The log file for this session is located
at:
/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/log/CLONE_testappl/02041433/adconfig.log
AutoConfig is configuring the Database
environment...
AutoConfig will consider the custom
templates if present.
Using ORACLE_HOME location : /appl/ERP_CLONE/dbclone/tech_st/11.1.0
Classpath :
:/appl/ERP_CLONE/dbclone/tech_st/11.1.0/jdbc/lib/ojdbc6.jar:/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/java/xmlparserv2.jar:/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/java:/appl/ERP_CLONE/dbclone/tech_st/11.1.0/jlib/netcfg.jar:/appl/ERP_CLONE/dbclone/tech_st/11.1.0/jlib/ldapjclnt11.jar
Using Context file :
/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/CLONE_testappl.xml
Context Value Management will now update
the Context file
UnsatisfiedLinkError exception loading
native library: njni11
Updating Context file...COMPLETED
Attempting upload of Context file and templates to
database...COMPLETED
Updating rdbms version in Context file to
db111
Updating rdbms type in Context file to 64
bits
Configuring templates from ORACLE_HOME ...
AutoConfig completed successfully.
|
THE CHECKS
PERFORMED AFTER DB CLONE B4 APPS CLONE
Check the Target - If it’s in ARCHIVELOG / NOARCHIVELOG MODE as desired.
Archivelog list
Show parameter log_archive_dest
|
Create the Temp datafiles , using the commands taken from the control file
, if the temporary tablespace tempfiles is not existing.
ALTER TABLESPACE TEMP ADD TEMPFILE __________ Verify dba_temp_files, for all the temp file entries added to TEMP SQL> select file_name from dba_temp_files; Check for the Default Temporary file – =========================== select * from database_properties where property_name = 'DEFAULT_TEMP_TABLESPACE'; Confirm that this TEMP. If the default is not TEMP, SQL>alter database default temporary tablespace TEMP |
Update global_name if it contains source
select * from global_name; update global_name set global_name='<global db name>'; commit; SQL> select * from global_name; GLOBAL_NAME -------------------------------------------------------------------------------- DEV |
Restoration of files backed up on Target Instance prior to the clone
- You may need to restore the tnsnames.ora , listener.ora
(which was backed up for the target instance prior to clone)
- You may need to restore the spfile/init file , so that the target instance takes the original init parameters (memory/performance parameters) and restart the database. |
Change the directories – if any need to be changed
set heading off
set pages 1000 set linesize 100 select 'CREATE OR REPLACE DIRECTORY '||DIRECTORY_NAME||' AS '||''''||DIRECTORY_PATH||''''||';' from all_directories; spool off - Edit the commands by replacing PROD with DEV ie source with target and Execute. - You would also be required to check and recreate the DB links as per tns entries and requirements in the Target Instance. |
Update apps.wf_systems
(This should show the target Instance and not the source
Instance)
SQL>select name,display_name from apps.wf_systems; SQL>update apps.wf_systems set name=’<SID>’,display_name=’ <SID>.<hostname.domainname>’; SQL>COMMIT; Example after change SQL> select name,display_name from apps.wf_systems; NAME DISPLAY_NAME ------------------------------ ------------------------------------------------------------------------ DEV DEV.DBALOUNGE.COM |
Update Notification status
(This needs to be bone before running adcfgclone on the apps tier , to avoid any Notifications to be sent from the Target Instance)
1. select
status ,mail_status ,end_date from apps.wf_notifications WHERE mail_status in
('MAIL','INVALID','OPEN');
UPDATE apps.wf_notifications SET status ='CLOSED', mail_status ='SENT', end_date ='01-JAN-01' WHERE mail_status in ('MAIL','INVALID','OPEN'); Commit;
2. select
address from apps.wf_agents;
update apps.wf_agents set address = replace ( address,'PROD','DEV' ) ;
commit;
3. select
name ,display_name from apps.wf_systems;
update apps.wf_systems set DISPLAY_NAME = replace ( DISPLAY_NAME, 'PROD.DBALOUNGE.COM','DEV.DBALOUNGE.COM'); Commit; |
Update the target node in CM fnd_concurrent_queues table AND on-hold requests
1. select unique node_name from apps.fnd_nodes;
update fnd_concurrent_queues set
node_name='<target_conc_node>' where
node_name='<source_conc_node>';
select unique node_name from apps.fnd_concurrent_queues;
commit;
commit;
UPDATE
apps.fnd_concurrent_processes
SET process_status_code = 'K'
WHERE process_status_code not in ('K', 'S');
UPDATE apps.fnd_concurrent_queues
SET running_processes = 0, max_processes = 0;
UPDATE apps.fnd_concurrent_queues
SET control_code = NULL
WHERE control_code not in ('E', 'R', 'X')
AND control_code IS NOT NULL;
UPDATE apps.fnd_concurrent_queues
SET target_node = null;
UPDATE apps.fnd_concurrent_requests
SET phase_code = 'C', status_code = 'E'
WHERE status_code ='T' OR phase_code = 'R';
SET process_status_code = 'K'
WHERE process_status_code not in ('K', 'S');
UPDATE apps.fnd_concurrent_queues
SET running_processes = 0, max_processes = 0;
UPDATE apps.fnd_concurrent_queues
SET control_code = NULL
WHERE control_code not in ('E', 'R', 'X')
AND control_code IS NOT NULL;
UPDATE apps.fnd_concurrent_queues
SET target_node = null;
UPDATE apps.fnd_concurrent_requests
SET phase_code = 'C', status_code = 'E'
WHERE status_code ='T' OR phase_code = 'R';
select
phase_code, status_code, hold_flag, count(*) from apps.fnd_concurrent_requests
group by phase_code, status_code, hold_flag;
update apps.fnd_concurrent_requests set hold_flag ='Y'
where phase_code = 'P';
Commit;
Commit;
Check UTL_FILE_DIR paths
select name,
value from v$parameter2 where name='utl_file_dir';
enter the first value of the above for APPLPTMP value in
application clone utl_file_dir
|
Check for any
client specific DB post Clone steps before moving to Apps Clone
Application Clone
Starts Here
Disable auto startup of services
Comment out the following call from the adcfgclone.pl script.
# startup_services();
Or
my $isSkipStartingServices = "true";
|
Edit CTXORIG.xml file to modify the port values
cd
$COMMON_TOP/clone/context/apps
Update failed login attempts
Before starting adcfgclone
run the following command as system or sys user
Alter profile default
limit FAILED_LOGIN_ATTEMPTS UNLIMITED;
Collect info for apps clone and run adcfgclone
bash-3.00$
pwd
/data/appclone/R12_ERP/apps/apps_st/comn/clone/bin
bash-3.00$
export PATH=/usr/ccs/bin:/usr/bin:/usr/ucb:/etc:.
bash-3.00$ 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.8
Enter
the APPS password :
Running:
/data/appclone/R12_ERP/apps/apps_st/comn/clone/bin/../jre/bin/java
-Xmx600M -cp /data/appclone/R12_ERP/apps/apps_st/comn/clone/jlib/java:/data/appclone/R12_ERP/apps/apps_st/comn/clone/jlib/xmlparserv2.jar:/data/appclone/R12_ERP/apps/apps_st/comn/clone/jlib/ojdbc14.jar
oracle.apps.ad.context.CloneContext -e
/data/appclone/R12_ERP/apps/apps_st/comn/clone/bin/../context/apps/CTXORIG.xml
-validate -pairsfile /tmp/adpairsfile_26828.lst -stage
/data/appclone/R12_ERP/apps/apps_st/comn/clone
2> /tmp/adcfgclone_26828.err; echo $? > /tmp/adcfgclone_26828.res
Log
file located at /data/appclone/R12_ERP/apps/apps_st/comn/clone/bin/CloneContext_0205121512.log
Provide
the values required for creation of the new APPL_TOP Context file.
Target
System Hostname (virtual or normal) [testappl] :
Target
System Database SID : CLONE
Target
System Database Server Node [testappl] :
Target
System Database Domain Name [orasol.com] :
Target
System Base Directory : /data/appclone/R12_ERP
Target
System Tools ORACLE_HOME Directory [/data/appclone/R12_ERP/apps/tech_st/10.1.2]
:
Target
System Web ORACLE_HOME Directory [/data/appclone/R12_ERP/apps/tech_st/10.1.3] :
Target
System APPL_TOP Directory [/data/appclone/R12_ERP/apps/apps_st/appl] :
Target
System COMMON_TOP Directory [/data/appclone/R12_ERP/apps/apps_st/comn] :
Target
System Instance Home Directory [/data/appclone/R12_ERP/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 [devappl:0.0] (y/n) : n
Target
System Display [testappl:0.0] :
RC-00217:
Warning: Configuration home directory (s_config_home) evaluates to
/data/appclone/R12_ERP/inst/apps/CLONE_testappl. A directory with this name
already exists and is not empty.
Do
you want to continue (y/n) : y
Do
you want the the target system to have the same port values as the source
system (y/n) [y] ? : n
Target
System Port Pool [0-99] : 22
Checking
the port pool 22
done:
Port Pool 22 is free
Report
file located at /data/appclone/R12_ERP/inst/apps/CLONE_testappl/temp/portpool.lst
Complete
port information available at
/data/appclone/R12_ERP/inst/apps/CLONE_testappl/temp/portpool.lst
UTL_FILE_DIR
on database tier consists of the following directories.
1.
/usr/tmp
2.
/usr/tmp
3.
/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/outbound/CLONE_testappl
4.
/usr/tmp
Choose
a value which will be set as APPLPTMP value on the target node [1] :
Backing
up /data/appclone/R12_ERP/inst/apps/CLONE_testappl/appl/admin/CLONE_testappl.xml
to
/data/appclone/R12_ERP/inst/apps/CLONE_testappl/appl/admin/CLONE_testappl.xml0.bak
Creating
the new APPL_TOP Context file from :
/data/appclone/R12_ERP/apps/apps_st/appl/ad/12.0.0/admin/template/adxmlctx.tmp
The
new APPL_TOP context file has been created :
/data/appclone/R12_ERP/inst/apps/CLONE_testappl/appl/admin/CLONE_testappl.xml
Log
file located at
/data/appclone/R12_ERP/apps/apps_st/comn/clone/bin/CloneContext_0205121512.log
Check
Clone Context logfile /data/appclone/R12_ERP/apps/apps_st/comn/clone/bin/CloneContext_0205121512.log
for details.
Running
Rapid Clone with command:
perl
/data/appclone/R12_ERP/apps/apps_st/comn/clone/bin/adclone.pl
java=/data/appclone/R12_ERP/apps/apps_st/comn/clone/bin/../jre mode=apply
stage=/data/appclone/R12_ERP/apps/apps_st/comn/clone component=appsTier
method=CUSTOM
appctxtg=/data/appclone/R12_ERP/inst/apps/CLONE_testappl/appl/admin/CLONE_testappl.xml
showProgress contextValidated=true
Running:
perl
/data/appclone/R12_ERP/apps/apps_st/comn/clone/bin/adclone.pl
java=/data/appclone/R12_ERP/apps/apps_st/comn/clone/bin/../jre mode=apply
stage=/data/appclone/R12_ERP/apps/apps_st/comn/clone component=appsTier
method=CUSTOM
appctxtg=/data/appclone/R12_ERP/inst/apps/CLONE_testappl/appl/admin/CLONE_testappl.xml
showProgress contextValidated=true
APPS
Password :
Beginning
application tier Apply - Tue Feb 5
12:15:57 2013
/data/appclone/R12_ERP/apps/apps_st/comn/clone/bin/../jre/bin/java
-Xmx600M -DCONTEXT_VALIDATED=true
-Doracle.installer.oui_loc=/oui -classpath /data/appclone/R12_ERP/apps/apps_st/comn/clone/jlib/xmlparserv2.jar:/data/appclone/R12_ERP/apps/apps_st/comn/clone/jlib/ojdbc14.jar:/data/appclone/R12_ERP/apps/apps_st/comn/clone/jlib/java:/data/appclone/R12_ERP/apps/apps_st/comn/clone/jlib/oui/OraInstaller.jar:/data/appclone/R12_ERP/apps/apps_st/comn/clone/jlib/oui/ewt3.jar:/data/appclone/R12_ERP/apps/apps_st/comn/clone/jlib/oui/share.jar:/data/appclone/R12_ERP/apps/apps_st/comn/clone/jlib/oui/srvm.jar:/data/appclone/R12_ERP/apps/apps_st/comn/clone/jlib/ojmisc.jar oracle.apps.ad.clone.ApplyAppsTier -e
/data/appclone/R12_ERP/inst/apps/CLONE_testappl/appl/admin/CLONE_testappl.xml
-stage /data/appclone/R12_ERP/apps/apps_st/comn/clone -showProgress
APPS
Password : Log file located at /data/appclone/R12_ERP/inst/apps/CLONE_testappl/admin/log/ApplyAppsTier_02051215.log
/
89% completed
Completed
Apply...
Tue
Feb 5 12:20:51 2013
Do
you want to startup the Application Services for CLONE? (y/n) [y] :
Starting
application Services for CLONE:
Perform Post clone steps
Checks Performed
After Apps Clone But With Apps Services Down
You may want to Restore the backed up target xml file (DEV xml) file to its
proper location.
We may want to use the same xml file which was in place prior to the clone so that the same ports / configuration is in use.
Remove the log files from APPLCSF/APPLLOG
Make sure Dir are
existing ; Use command to confirm
cd $APPLCSF/$APPLLOG Delete all files under $APPLCSF/$APPLLOG |
You can set the logfile to NULL
update fnd_concurrent_requests set logfile_name = null,
logfile_node_name =
null,outfile_name = null, outfile_node_name = null;
commit; |
Run FND Conc Clean Procedure
SQL> EXEC FND_CONC_CLONE.SETUP_CLEAN;
PL/SQL procedure successfully completed.
SQL> commit;
Commit complete.
SQL> select NODE_NAME from fnd_nodes;
|
Change apps, sys, system, and sysadmin password
bash-3.00$ FNDCPASS apps/apps 0 Y system/manager SYSTEM APPLSYS
appsclone
bash-3.00$ FNDCPASS apps/apps 0 Y system/manager USER SYSADMIN
<password>
|
Change site NAME
select
fnd_profile.value('SITENAME') from dual;
declare
b boolean ; begin b := fnd_profile.save('SITENAME' ,'PAGCRP4 - Refreshed from PRODUCTION - 17-May-2013' , 'SITE'); if b = TRUE then dbms_output.put_line('success'); end if; end; /
commit;
|
Reduce concurrent managers as required depending on the resources
Run cmclean.sql
Run autoconfig on On DB Tier
bash-3.00$
cd $ORACLE_HOME/appsutil/scripts/$CONTEXT_NAME
bash-3.00$
ls
adautocfg.sh adchknls.pl addbctl.sh addlnctl.sh adexecsql.pl adlsnodes.sh adpreclone.pl adstopdb.sql
adstrtdb.sql
bash-3.00$
adautocfg.sh
Enter
the APPS user password:
The
log file for this session is located at:
/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/log/CLONE_testappl/02051300/adconfig.log
AutoConfig
is configuring the Database environment...
AutoConfig
will consider the custom templates if present.
Using ORACLE_HOME location :
/appl/ERP_CLONE/dbclone/tech_st/11.1.0
Classpath : :/appl/ERP_CLONE/dbclone/tech_st/11.1.0/jdbc/lib/ojdbc6.jar:/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/java/xmlparserv2.jar:/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/java:/appl/ERP_CLONE/dbclone/tech_st/11.1.0/jlib/netcfg.jar:/appl/ERP_CLONE/dbclone/tech_st/11.1.0/jlib/ldapjclnt11.jar
Using Context file :
/appl/ERP_CLONE/dbclone/tech_st/11.1.0/appsutil/CLONE_testappl.xml
Context
Value Management will now update the Context file
UnsatisfiedLinkError
exception loading native library: njni11
Updating Context file...COMPLETED
Attempting upload of Context file and
templates to database...COMPLETED
Updating
rdbms version in Context file to db111
Updating
rdbms type in Context file to 64 bits
Configuring
templates from ORACLE_HOME ...
AutoConfig
completed successfully.
Running autoconfig on application
Tier
bash-3.00$ cd $ADMIN_SCRIPTS_HOME
bash-3.00$
adautocfg.sh
Enter
the APPS user password:
The
log file for this session is located at:
/data/appclone/R12_ERP/inst/apps/CLONE_testappl/admin/log/02051301/adconfig.log
AutoConfig
is configuring the Applications environment...
AutoConfig
will consider the custom templates if present.
Using CONFIG_HOME location :
/data/appclone/R12_ERP/inst/apps/CLONE_testappl
Classpath :
/data/appclone/R12_ERP/apps/apps_st/comn/java/lib/appsborg2.zip:/data/appclone/R12_ERP/apps/apps_st/comn/java/classes
Using Context file :
/data/appclone/R12_ERP/inst/apps/CLONE_testappl/appl/admin/CLONE_testappl.xml
Context
Value Management will now update the Context file
Updating Context file...COMPLETED
Attempting upload of Context file and
templates to database...COMPLETED
Configuring
templates from all of the product tops...
Configuring AD_TOP........COMPLETED
Configuring FND_TOP.......COMPLETED
Configuring ICX_TOP.......COMPLETED
Configuring MSC_TOP.......COMPLETED
Configuring IEO_TOP.......COMPLETED
Configuring BIS_TOP.......COMPLETED
Configuring AMS_TOP.......COMPLETED
Configuring CCT_TOP.......COMPLETED
Configuring WSH_TOP.......COMPLETED
Configuring CLN_TOP.......COMPLETED
Configuring OKE_TOP.......COMPLETED
Configuring OKL_TOP.......COMPLETED
Configuring OKS_TOP.......COMPLETED
Configuring CSF_TOP.......COMPLETED
Configuring IGS_TOP.......COMPLETED
Configuring IBY_TOP.......COMPLETED
Configuring JTF_TOP.......COMPLETED
Configuring MWA_TOP.......COMPLETED
Configuring CN_TOP........COMPLETED
Configuring CSI_TOP.......COMPLETED
Configuring WIP_TOP.......COMPLETED
Configuring CSE_TOP.......COMPLETED
Configuring EAM_TOP.......COMPLETED
Configuring FTE_TOP.......COMPLETED
Configuring ONT_TOP.......COMPLETED
Configuring AR_TOP........COMPLETED
Configuring AHL_TOP.......COMPLETED
Configuring OZF_TOP.......COMPLETED
Configuring IES_TOP.......COMPLETED
Configuring CSD_TOP.......COMPLETED
Configuring IGC_TOP.......COMPLETED
AutoConfig
completed successfully.
bash-3.00$
The
Checks Performed after Apps Clone with Apps Services up And Running
Check the custom.env is in place
Check for Client Specific Application Post Clones
Bring up all services
Configure Workflow Mailer
Submit Concurrent Program from backend
CONCSUB APPS/apps \
SYSADMIN \
"System
Administrator" \
SYSADMIN \
WAIT=N \
CONCURRENT \
FND \
FNDSCURS \
PROGRAM_NAME='"Active
Users"';
|
Errors and
Troubleshooting
Concurrent Manager Troubleshooting Script
Purpose: Diagnostic Script for Concurrent Manager
Enter value for
request ID WHEN PROMPT: If you don’t want to enter any value click Enter to
exit
|
Concurrent Processing - After Cloning All the Concurrent Managers Do Not
Start for the Clone [ID 555081.1]
select CONCURRENT_QUEUE_NAME from FND_CONCURRENT_QUEUES
where CONCURRENT_QUEUE_NAME like 'FNDSM%';
Go to $FND_TOP/patch/115/sql Connect SQLPLUS as APPS user and run the following script : SQL> @afdcm037.sql; $AD_TOP/sql/adautoconf.sql -- will give the products installed update fnd_concurrent_queues set NODE_NAME='TEST hostname' where NODE_NAME='PROD hostname'; --if not pointing right |
DB port pool entered for adcfgclone.pl
/u01/oramgr/VISERP/db/tech_st/11.1.0/appsutil/temp
Apps port pool entered for adcfgclone.pl
/u01/applmgr/VISERP/inst/apps/VISCLN3_desktop/admin/out/portpool.lst
WF Mailer Override Address and
Cloning
The
problem is that the only official way to set the override address in the latest
ATG releases is to go through the OAM portal and change the override email via
the GUI interface. The GUI sends a verification code to the email address
entered, asking to enter it on the next screen to confirm the change. The issue
is that we as Apps DBAs do not always have access to the override address mail
box. On top of that if we are looking to script whole EBS cloning process we
need to find SQL-PL/SQL based solution.
I did some searches for an “official” PL/SQL API to be used, however failed to find one (biside of FND_SVC_COMP_PARAM_VALS_PKG.UPDATE_ROW which isn’t the most user friendly interface anyway).
I did some searches for an “official” PL/SQL API to be used, however failed to find one (biside of FND_SVC_COMP_PARAM_VALS_PKG.UPDATE_ROW which isn’t the most user friendly interface anyway).
I
came to the following solution:
select fscpv.parameter_value
from fnd_svc_comp_params_tl fscpt
,fnd_svc_comp_param_vals fscpv
where fscpt.display_name = 'Test Address'
and fscpt.parameter_id = fscpv.parameter_id;
update
fnd_svc_comp_param_vals fscpv
set
fscpv.PARAMETER_VALUE = '<override email address>'
where
fscpv.parameter_id in (
select
fscpt.parameter_id
from
fnd_svc_comp_params_tl fscpt
where
fscpt.display_name = 'Test
Address');
select fscpv.parameter_value
from fnd_svc_comp_params_tl fscpt
,fnd_svc_comp_param_vals fscpv
where fscpt.display_name = 'Test Address'
and fscpt.parameter_id = fscpv.parameter_id;
commit;
|
No comments:
Post a Comment