Anda di halaman 1dari 4

Cloning Oracle Database in Oracle Applications 11i

If your source and destination database have same SID then only copy the data files and
follow Step 4

If your source and destination database don’t have same SID then follow these steps

1. Shutdown application tier services.


2. Logon to database where cloning will be performed.
a. SQL> show parameter instance
b. SQL> select file_name from dba_data_files;
3. SQL> shutdown immediate
4. SQL> startup mount
5. SQL>alter database backup controlfile to trace;
6. SQL> shutdown immediate

7. Go to $ORACLE_HOME/admin/<SID>/udump and copy the most recently


created file and name it to <SID.ctl>

8. Copy database, log, control files from source applications database to destination
database
9. See permission of all files copied from prod to test
chown oratest:dba *.dbf

10. Go to $ORACLE_HOME/admin/<SID>/udump. Open <SID>.ctl


And perform following modifications
a. Take portion which starts with “ResetLOGS” which will be in create control file.
b. Instead of “reuse database” in create control file command use “set database”
c. Change name to new database name
d. See clone.sql file and adjust accordingly
e. rename .trc file to <sid>.ctl
11. SQL>@sid.ctl
12. shutdown immediate;
13. startup mount;
14. alter database noarchivelog;
15. alter database open;
16. alter tablespace temp add tempfile ‘ ‘ reuse

4. Update the FND_CONCURRENT_% tables


Update the following tables as the APPS user:
sqlplus <APPS username>/<APPS password>
SQL> Update FND_CONCURRENT_REQUESTS
set LOGFILE_NAME = null,
LOGFILE_NODE_NAME = null,
OUTFILE_NAME = null,
OUTFILE_NODE_NAME = null;

SQL> commit;

SQL> Delete From FND_CONCURRENT_QUEUE_SIZE


where CONCURRENT_QUEUE_ID in
(Select CONCURRENT_QUEUE_ID
from FND_CONCURRENT_QUEUES
where MANAGER_TYPE in (2,6));

SQL> commit;
SQL> Delete From FND_CONCURRENT_QUEUES_TL
where CONCURRENT_QUEUE_ID in
(Select CONCURRENT_QUEUE_ID
from FND_CONCURRENT_QUEUES
where MANAGER_TYPE in (2,6));
SQL> commit;

SQL> Update FND_NODES


set NODE_MODE = ‘D’;
SQL> commit;

SQL> Delete from FND_CONCURRENT_QUEUES


where MANAGER_TYPE in (2,6);
SQL> commit;

SQL> Update FND_CONCURRENT_QUEUES


set CONTROL_CODE = null, DIAGNOSTIC_LEVEL = null,
TARGET_NODE = null, MAX_PROCESSES = 0,
RUNNING_PROCESSES = 0;

SQL> commit;

SQL>select node_name from fnd_nodes;


NODE_NAME
------------------------------
TEST
5. Running adconfig as applications operating system user
Log on to the target system as the applmgr user and run AutoConfig to generate
new configuration files for the target system. You will be prompted for the
location of the Applications Context file and the APPS password.
UNIX or Linux:
$ cd $AD_TOP/bin
adconfig.sh contextfile=$APPL_TOP/admin/<contextifle>

6. If GSM is not being used do following steps

Login with user which has system administrator responsibility and go to


System Profile-> and against column profile in “Find Profile Form” search for
“%GSM%” and change “Y” to “N”

If GSM is set to “Yes” then forms and reports services will be handled by concurrent
manager.

7. Changing Instance Name:


Login with user which has system administrator responsibility and go to
System Profile-> and against column profile in “Find Profile Form” search for
“Site Name”

8. Disable Archiving

SQL> shutdown immediate;


SQL> startup mount;
SQL> alter database noarchivelog;
SQL> alter database open;

9. Changing the APPLPTMP value

Log into the system as applmgr user and check the current value of the
APPLPTMP variable using the following command:
$ echo $APPLPTMP
/usr/tmp

Check the permission for all the users on this directory. Now, follow the below steps:
 Shutdown Apps
 Shutdown Database
 Shutdown Listener
 Backup $ORACLE_HOME/initTEST.ora
Edit $ORACLE_HOME/initTEST.ora (added APPLPTMP path to UTL_FIL_DIR)

Now start the application in the following order:


 Startup Listener
 Startup Database
 Startup Apps

Verify the solution has successfully been implemented.

Anda mungkin juga menyukai