|
Some Steps To Do Database Refresh in APPS.... |
Thursday, January 17, 2008 |
Now I do database refresh From Clone System To Source B'coz.
1) Start the database and Applications Tier for testing purpose whether it is working. **** Log on Database user In my Case : su - dbtier check the value of $ORACLE_HOME echo $ORACLE_HOME cd $ORACLE_HOME/appsutil/scripts/clone_apps/ ./addlnctl.sh start clone lsnrctl status clone ./addbctl.sh start sqlplus '/as sysdba' select status from v$instance **** Log on Applications user In my Case su - apptier check the value $COMMON_TOP or $OAD_TOP cd $COMMON_TOP/admin/scripts/clone_apps/ ./adstrtal.sh apps/apps --- This script will start the applications Tier including all the servers. 2) Test the applications http://host_name:port --- Yes It is working Fine Now we need to shutdown the Applications Tier as well as Database Tier.
3) Shutdown **** Firstly Stop the Applications Tier. Log on Applications user In my Case su - apptier check the value $COMMON_TOP or $OAD_TOP cd $COMMON_TOP/admin/scripts/clone_apps/ ./adstpall.sh apps/apps *** Now Shutdown the Database Neatly and cleanly. Log on Database user In my Case : su - dbtier check the value of $ORACLE_HOME echo $ORACLE_HOME cd $ORACLE_HOME/appsutil/scripts/clone_apps/ ./addlnctl.sh stop clone lsnrctl status clone ./addbctl.sh stop sqlplus '/as sysdba' select status from v$instance Note -- Now follow the document 7 steps for database refreshment.......
4) Startup the database in restrict mode. sqlplus '/as sysdba' startup restrict 5) Create a Control file to trace. alter database backup contolfile to trace; check out latest trace file under the $ORACLE_HOME/admin/clone_apps/udump In my Case that is clone_ora_8880.trc nad rename it as .sql format i.e mv clone_ora_8880.trc ctrclone.sql 6) Shutdown the Database. sqlplus '/as sysdba' shutdown immediate; 7) Copy initclone,ctrlclone.sql and datafiles to VIS system. In My Case Copy Initialize parameter file..... cd clone/visdb/9.2.0/dbs/ cp -Rf initclone.ora /u01/oracle/visdb/9.2.0/dbs/ cp -Rf clone_apps_ifile.ora /u01/oracle/visdb/9.2.0/dbs/ Copy Ctrlclone.sql file cd admin/clone_apps/udump/ cp -Rf ctrclone.sql /u01/oracle/visdb/9.2.0/admin/ Copy datafiles cd /u01/clone/ cp -Rf visdata /u01/oracle/ 8) Change the permission at OS level In my case As root user issues these commands.... chmod -Rf 755 9) Now edit the init parameter file change the parameter db_name = vis control_files= /u01/oracle/visdata/cntrl01.dbf,/u01/oracle/visdata/cntrl02.dbf,/u01/oracle/visdata/cntrl03.dbf user_dump_dest = /u01/oracle/visdb/9.2.0/admin/vis_apps/udump background_dump_dest = /u01/oracle/visdb/9.2.0/admin/vis_apps/bdump core_dump_dest = /u01/oracle/visdb/9.2.0/admin/vis_apps/cdump utl_file_dir = /usr/tmp,/usr/tmp,/u01/oracle/visdb/9.2.0/appsutil/outbound/vis_apps,/usr/tmp IFILE=/u01/oracle/visdb/9.2.0/dbs/vis_apps_ifile.ora 10 Make changes in the ctrlclone.sql In my case which is located at /u01/oracle/visdb/9.2.0/admin/ vi ctrlclone.sql STARTUP NOMOUNT pfile=/u01/oracle/visdb/9.2.0/dbs/initVIS.ora CREATE CONTROLFILE set DATABASE "VIS" RESETLOGS NOARCHIVELOG -- SET STANDBY TO MAXIMIZE PERFORMANCE MAXLOGFILES 32 MAXLOGMEMBERS 5 MAXDATAFILES 512 MAXINSTANCES 8 MAXLOGHISTORY 3630 LOGFILE GROUP 1 '/u01/oracle/visdata/log3.dbf' SIZE 50M, GROUP 2 '/u01/oracle/visdata/log2.dbf' SIZE 50M, GROUP 3 '/u01/oracle/visdata/log1.dbf' SIZE 50M -- STANDBY LOGFILE DATAFILE '/u01/oracle/visdata/sys1.dbf', '/u01/oracle/visdata/sys2.dbf', '/u01/oracle/visdata/sys3.dbf', '/u01/oracle/visdata/sys4.dbf', '/u01/oracle/visdata/sys5.dbf', '/u01/oracle/visdata/sys6.dbf', '/u01/oracle/visdata/sys7.dbf', '/u01/oracle/visdata/undo01.dbf', '/u01/oracle/visdata/undo02.dbf', '/u01/oracle/visdata/undo03.dbf', '/u01/oracle/visdata/undo04.dbf', '/u01/oracle/visdata/archive1.dbf', '/u01/oracle/visdata/archive2.dbf', '/u01/oracle/visdata/media1.dbf', '/u01/oracle/visdata/media2.dbf', '/u01/oracle/visdata/media3.dbf', '/u01/oracle/visdata/nologging1.dbf', '/u01/oracle/visdata/queues1.dbf', '/u01/oracle/visdata/queues2.dbf', '/u01/oracle/visdata/reference1.dbf', '/u01/oracle/visdata/reference2.dbf', '/u01/oracle/visdata/summary1.dbf', '/u01/oracle/visdata/summary2.dbf', '/u01/oracle/visdata/summary3.dbf', '/u01/oracle/visdata/summary4.dbf', '/u01/oracle/visdata/summary5.dbf', '/u01/oracle/visdata/tx_data1.dbf', '/u01/oracle/visdata/tx_data2.dbf', '/u01/oracle/visdata/tx_data3.dbf', '/u01/oracle/visdata/tx_data4.dbf', '/u01/oracle/visdata/tx_data5.dbf', '/u01/oracle/visdata/tx_data6.dbf', '/u01/oracle/visdata/tx_data7.dbf', '/u01/oracle/visdata/tx_data8.dbf', '/u01/oracle/visdata/tx_data9.dbf', '/u01/oracle/visdata/tx_data10.dbf', '/u01/oracle/visdata/tx_data11.dbf', '/u01/oracle/visdata/tx_idx1.dbf', '/u01/oracle/visdata/tx_idx2.dbf', '/u01/oracle/visdata/tx_idx3.dbf', '/u01/oracle/visdata/tx_idx4.dbf', '/u01/oracle/visdata/tx_idx5.dbf', '/u01/oracle/visdata/tx_idx6.dbf', '/u01/oracle/visdata/tx_idx7.dbf', '/u01/oracle/visdata/tx_idx8.dbf', '/u01/oracle/visdata/tx_idx9.dbf', '/u01/oracle/visdata/tx_idx10.dbf', '/u01/oracle/visdata/tx_idx11.dbf', '/u01/oracle/visdata/apps_ts_tx_interface.dbf', '/u01/oracle/visdata/ctx1.dbf', '/u01/oracle/visdata/odm.dbf', '/u01/oracle/visdata/olap.dbf', '/u01/oracle/visdata/owa1.dbf', '/u01/oracle/visdata/portal.dbf', '/u01/oracle/visdata/mobile01.dbf' CHARACTER SET UTF8 ;
11) Open the database in resetlog mode. alter database open resetlogs 12) Shutdown the database in normal mode & Take a cold backup as per Oracle recommendation.
13) Startup database and listener.
14 Now login as application user In my Case su - applmgr and run adautocfg.sh Go to $COMMON_TOP/admin/scripts/VIS_apps/ ./adautocfg.sh It will ask you APPS Password give APPS password.Wait for result.In My case it gives error,i checked log file then i come to know listener is not running on database.I started lsnrctl start again it gives error then again i checked logfile i got ORACLE error (ORA-25153: Temporary Tablespace is Empty) then i add datafile in temp tablespace as following. SQL> ALTER TABLESPACE TEMP ADD TEMPFILE '/u01/oracle/visdata/tmp1.dbf' SIZE 2000M REUSE AUTOEXTEND OFF; Tablespace altered. Now again i run adautocfg.sh,it runs successfully. 15) Run AutoConfig on Database tier logon Database tier user su - oracle cd $ORACLE_HOME/appsutil/scripts/VIS_apps/ ./adautocfg.sh It runs successfully. 16) Now start the application Tier logon su - applmgr cd $OAD_TOP/admin/scripts/VIS_apps/ ./adstrtal.sh apps/apps 17) Test the applications. http://host_name:port_no login as sysadmin/sysadmin_password. |
posted by Jaswinder Singh @ 10:06 PM |
|
|
|
|