Monday, September 19, 2011

CLONING OF APPLICATIONS IN APPS 11i

Hi,
Lot of times Apps DBAs have to do the task of Cloning,It is one of the frequently doing task for Apps DBA.Below I'm describing one such task.

Concept of Cloning:
* Cloning is the act of creating an identical copy of an existing Oracle applications system.
* The new system, including component versions, operating system and platform type, is identical to the existing system.

Steps for cloning with E-business suite version 11.5.10.2 on linux are as follows:

Why to clone:
- Create a copy of a production system for testing updates.
- Migrate an existing system to new hardware.
- Create a stage area to reduce patching downtime.

* PREREQUISITE TASKS:

1) PREPARE THE SOOURCE SYSTEM:
LOG ON TO SOURCE SYSTEM AS ORACLE USER, RUN THE FOLLOWING COMMANDS.

a)Preparing source system for dbTier:
$cd /apps11i/proddb/9.2.0/appsutil/scripts/PROD_node1
$perl adpreclone.pl dbTier

b)Preparing source system for applicaton tier (appsTier):

$cd /apps11i/prodcomn/admin/scripts/PROD_node1
$perl adpreclone.pl appsTier

2)COPY THE SOURCE SYSTEM TO THE TARGET SYSTEM:

- Properly shutdown the database from the database terminal i.e. the terminal where database environment is set and shutdown the application from application terminal where application environment is set.
- Copy base directory including all its sub-directory (prodappl, prodcomn, proddb, prodora, proddata) manually using OS command.
- The directory should be same on the target machine as on the source machine for easiness.
- Copy the database configuration file and application configuration file i.e. .db and .app from source to target machine.

3)Edit the .db file, change the machine name i.e. from source to target m/c name.

. /apps11i/proddb/9.2.0/PROD_node2.env
PATH=$PATH:/apps11i/proddb/9.2.0/appsutil/scripts/PROD_node2
PATH=$PATH:/apps11i/prodcomn/admin/scripts/PROD_node2
export PATH

4)Now run the post script for dbtier:

$cd /apps11i/proddb/9.2.0/appsutil/clone/bin
$perl adcfgclone.pl dbTier

and supply the required values prompt by script like:

enter APPS password : apps
virtual hostname for tgt node: y
Tgt hostbane ; node2.server.com
Tgt rac instance: n
Tgt. System databse name: PROD
Tgt. System RDBMS oracle_home dir: choose the default (just press enter)
System util_file accessible dirs list:
/apps11i/proddb/9.2.0/appsutil/outbound/PROD_node2
(how to find this path:
On target machine,
Sho parameter %util% )

No of DATA_TOPS on the target system : 1
Tgt system DATA_TOP: select the default
Do u want to preserve the display set to node1:0.0: yes
Do u want to preserve the port values from the src system on the tgt. System: yes

5)Now edit the .app file i.e. change the source name to target name:

. /apps11i/prodappl/APPSPROD_node2.env
PATH=$PATH:/apps11i/prodcomn/admin/scripts/PROD_node2
PATH=$PATH:/apps11i/proddb/9.2.0/appsutil/scripts/PROD_node2
export PATH

6)Now run the .app file and the environment for application:

$cd /apps11i/prodcomn/clone/bin
$perl adcfgclone.pl appsTier

provide the required values prompt by the script.
Do you want to use the virtual host name for the target node: y
Tgt host name: node2.server.com
Tgt system dabase sid: PROD
Tgt. System database server node: node2.server.com
Tgt. System database domain name: server.com
Does the TGT. System has more then one application Tier: no
Is the tgt. System APPL_TOP devided in to multiple mount points: no
Tgt system APPL_TOP mount point:
/apps11i/prodcomn/
Tgt. System 8.0.6 ORACLE_HOME DIR: choose dfault
Tgt system iAS ORACLE_HOME DIR : choose default\
Preserve the display: yes\
Preserve the port value: yes
Web listner port is : 8000
UTL_FILE_DIR on database tier consist of the following dirs.
1. . /usr/tmp
2. /apps11i/prod2.0/appsutil/util/outbound/PROD_node2
3. /apps11i/proddb/9.2.0/appsutil/outbound/PROD_node2
4. /usr/tmp
Choose a value which will be set as APPLTMP value on the target node.

Important Scripts used for Apps DBA:

-Run the .app profile to set the environment for applications
1) addbctl.sh start  To start the database
2) addlnctl.sh start PROD  To start the corresponding listener
3) adstrtal.sh apps/apps  To start all the application services
4) adstpall.sh stop  To stop all services

Hope it helps.

Happy Apps DBA learning

No comments:

Post a Comment