Sunday, January 4, 2009

CLONING OF ORACLE APPS – MANUAL CLONING

CLONING OF ORACLE APPS – MANUAL CLONING
File System is Same(FRESH CLONING)


PREREQUISITES :

 Shut down the Database using Shut Immediate Option.
 Stop the DB listener.
 Stop all the Services.

Stage 1 (SOURCE-SIDE)

In this Stage we need to Copy the Database files , Techstacks and APPL_TOP and COMMON_TOP. In this we copy the below five tops from Source to Target.
 DATA_TOP
 DB_TOP
 APPL_TOP
 COMMON_TOP
 ORA_TOP
Source Server : 192.168.0.202
Target Server : 192.168.0.204

COPY THE FIVE TOPS FROM SOURCE TO TARGET AS BELOW :

 Copy the DATA_TOP from source to target
[app@linux2 ~] scp –r proddata app@192.168.0.204:/oraAPP/app/.
 Copy the DB_TOP from source to target.
[app@linux2 ~] scp –r proddb app@192.168.0.204:/oraAPP/app/.
 Copy the APPL_TOP from source to target.
[app@;inux2 ~] scp –r prodappl app@192.168.0.204:/oraAPP/app.
 Copy the COMMON_TOP from source to target.
[app@linux2 ~] scp –r prodcomn app@192.168.0.204:/oraAPP/app.
 Copy the ORA_TOP from source to target.
[app@linux2 ~] scp –r prodora app@192.168.0.204:/oraAPP/app.

Note : As we are using the same FILE SYSTEM on source and target, there is no need to take the backup of controlfile to trace.

Stage 2 (TARGET SIDE)

In this stage we clone the Database.

Stage 3 (TARGET SIDE)

DATABASE TIER:
 Edit the Context File. Edit the below options.
• Hostname
• Port Numbers (if required)
• SID (if required)
 Rename the XML file. Before renaming the file its better to take the Backup of this file.
[app@linux4 ~] cd $ORACLE_HOME/appsutil
[app@linux4 ~] mv app_linux2.xml app_linux4.xml
 Edit the Hostname for XML file in the script which runs the AUTOCONFIG.
[app@linux4 ~] cd $ORACLE_HOME/appsutil/scripts/app_linux2
[app@linux4 ~] vi adautocfg.sh
 Before running the Autoconfig , we need to add TEMPFILE for Temporary tablespace and assign that Tablespace to Database. For this set the environment manually for the database and connect to SQLPLUS and create tempfile.
[app@linux4 ~] sqlplus
SQL > alter tablespace temp add
tempfile ‘/oraAPP/app/appdata/temp.dbf’ size 2000m;
SQL > alter database default temporary tablespace temp;
 Run the AUTOCONFIG.
[app@linux4 ~] cd $ORACLE_HOME/appsutil/scripts/app_linux2
[app@linux4 ~] ./adautocfg.sh

Result : autoconfig completed successfully without errors. If any errors check for logfile.
Log file Location : $ORACLE_HOME/appsutil/log/app_linux2/mm_dd_yy/adconfig.log

APPLICATION TIER:
 Edit the Context File. Edit the below options.
• Hostname
• Port Numbers (if required)
• SID (if required)
 Rename the XML file. Before renaming the file its better to take the Backup of this file.
[app@linux4 ~] cd $APPL_TOP/admin
[app@linux4 ~] mv app_linux2.xml app_linux4.xml
 Edit the Hostname for XML file in the script which runs the AUTOCONFIG.
[app@linux4 ~] cd $COMMON_TOP/admin/scripts/app_linux2
[app@linux4 ~] vi adautocfg.sh
 Run the AUTOCONFIG.
[app@linux4 ~] cd $COMMON_TOP/admin/scripts/app_linux2
[app@linux4 ~] ./adautocfg.sh

Result : autoconfig completed successfully without errors. If any errors check for logfile.
Log file Location : $APPL_TOP/admin/app_linux2/log/mm_dd_yy/adconfig.log

Stage 3 (POST STEPS)

 Retire the Unnecessary Application Users.
 Update Non-Site level profiles.(if necessary)
 Update Printer settings. (if necessary)
 Update Workflow components. (if necessary)
 Clear Cache in COMMON_TOP/_pages.
 Start Services.


NOTE : In Real Time we need to perform some steps after before running the Autoconfig on Application Tier. The steps are as bellows.
 We need to run the below script as apps user. we need to download this script from metalink.
[app@linux2 ~] sqlplus
SQL > conn apps/apps
SQL > @?/RAPIDMAGIC/admin/cmclean.sql.
 Purge fnd_nodes.
SQL > exec fnd_conc_clone.setup_clone();

No comments:

Post a Comment