Clone Steps Rman
Clone Steps Rman
Clone Steps Rman
hot
rman duplicate - PROD (online) - DEV/TEST
Active Duplicate - no backups - there will be load on PROD
Standby database - clone - rman duplicate - no load at all on production
RapidClone
----------
RMAN Cloning
-----------
> start - once the backup is completed - comment out the backup
> don't add datafiles when the cloning/restore are going
log_archive_dest_1 = 'LOCATION=/d01/oracle/DEV/archive'
log_archive_format = archDEV%t_%s_%r.dbf
shutdown immediate
startup mount
alter database archivelog;
alter database open;
rman target /
-- RMAN backup
run {
allocate channel d1 type disk maxpiecesize 2047M;
allocate channel d2 type disk maxpiecesize 2047M;
allocate channel d3 type disk maxpiecesize 2047M;
backup format '/d01/oracle/backup/df_t%t_s%s_p%p' database;
sql 'alter system archive log current';
backup format '/d01/oracle/backup/al_t%t_s%s_p%p' archivelog all;
backup format '/d01/oracle/backup/control%U' current controlfile;
delete noprompt archivelog all backed up 2 times to device type disk;
release channel d1;
}
PROD
----
cd /d02/oracle/QA/12.1.0/appsutil/clone/bin/
-- create xml,init.ora,tnsnames
db folder
database files
db_file_name_convert=("/d01/oracle/PROD/data","/d01/oracle/UAT/data")
log_file_name_convert=("/d01/oracle/PROD/data","/d01/oracle/UAT/data")
tail -f dup.log
connect on db server
sqlplus apps/apps
EXEC FND_CONC_CLONE.SETUP_CLEAN;
run autoconfig
Application clone
/d01/oracle/PROD/fs1/EBSapps/comn/clone/bin
Version 12.2
Provide the values required for creation of the new APPL_TOP Context file.
1. /usr/tmp
2. /usr/tmp/UAT
3. /d01/oracle/UAT/12.1.0/appsutil/outbound/UAT_erp
4. /usr/tmp
Choose a value which will be set as APPLPTMP value on the target node [1] : 2
The new APPL_TOP context file has been created :
/d01/oracle/UAT/fs2/inst/apps/UAT_erp/appl/admin/UAT_erp.xml
Check Clone Context logfile
/d01/oracle/UAT/fs2/EBSapps/comn/clone/bin/CloneContext_0315094935.log for details.
Do you want to startup the Application Services for UAT? (y/n) [n] : n
Web browser -
Finishing Tasks
update applsys.fnd_profile_option_values
set profile_option_value=(select 'TEST Instance. Copy of PROD as of '||
to_char(max(actual_completion_date),'MM/DD/YYYY HH24:MI')
from applsys.fnd_concurrent_requests) where level_id=10001 and
(application_id,profile_option_id) in (select
fpo.application_id,fpo.profile_option_id from applsys.fnd_profile_options
fpo,applsys.fnd_profile_options_tl fpt where
fpo.profile_option_name=fpt.profile_option_name and
fpt.user_profile_option_name='Site Name');
commit;
On prod -
PROD=
(DESCRIPTION=
(ADDRESS=(PROTOCOL=tcp)(HOST=linux4.oracle.com)(PORT=1561))
(CONNECT_DATA=
(SERVICE_NAME=PROD)
(INSTANCE_NAME=PROD)
)
)
cat RMANC_linux4_ifile.ora
db_file_name_convert=("/d02/oracle/UAT/data","/d02/oracle/TEST/data")
log_file_name_convert=("/d02/oracle/UAT/data","/d02/oracle/TEST/data")
oraprod
oradev
startup nomount
-- Backup
-----------------------------------------------------------------------------------
---------
-----------------------------------------------------------------------------------
--------
sh run.sh
-- instance - mount
cd $ORACLE_HOME/appsutil/install/PATCH_testdb
sqlplus "/as sysdba" @adupdlib.sql so
sh adautoconfig
--------------------------------
PROD
startup nomount
TEST
-------------------------------
25618
RAC - NON-RAC
run {
autoconfig - succesfull
apps
issue 2
Database altered.
NAME TYPE
------------------------------------ ---------------------------------
VALUE
------------------------------
db_name string
R12TST
SQL> @control
Database altered.