博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
<<Oracle Applications DBA 基础(第二期)>>Week 13 exercise
阅读量:4176 次
发布时间:2019-05-26

本文共 12683 字,大约阅读时间需要 42 分钟。

1. Apply the following patches on your test system:
9239089, 9171651,9833058, 12404574,12598630

adstpall.sh apps/apps

adadmin menu_option=ENABLE_MAINT_MODE

create table apps.invalids_before_patch as select * from dba_objects where status='INVALID';

unzip p9239089_R12.AD.B_R12_LINUX.zip

cd 9239089

adpatch driver=u9239089.drv

unzip p9171651_R12.OAM.B_R12_GENERIC.zip -d src/

unzip p9833058_R12.OAM.B_R12_GENERIC.zip -d src/

unzip p12404574_R12.OAM.B_R12_GENERIC.zip -d src/

unzip p12598630_R12.OAM.B_R12_GENERIC.zip -d src/

admrgpch -s src/ -d dst/

cd dst/

adpatch driver=u_merged.drv

create table apps.invalids_after_patch as select * from dba_objects where status='INVALID';

select * from invalids_after_patch where object_id not in (select object_id from invalids_before_patch);

adadmin menu_option=DISABLE_MAINT_MODE

adstrtal.sh apps/apps

Run Active User to do sanity test

--EOF--

2. List in SQL*PLUS that you have applied the patches stated in Assignment 1.

SQL> select bug_number,last_update_date,TRACKABLE_ENTITY_ABBR from ad_bugs where bug_number in (9239089, 9171651,9833058, 12404574,12598630);

BUG_NUMBER                     LAST_UPDATE_DATE   TRACKABL
------------------------------ ------------------ --------
9239089                        02-APR-14          ad
12404574                       03-APR-14          oam
12598630                       03-APR-14          oam
9171651                        03-APR-14          oam
9833058                        03-APR-14          oam
SQL>

--EOF--

3. Try to use Rapid Clone to create a clone of your test system.

Oracle EBS R12 - Clone EBS R12.1.1 on Oracle Linux 64 5.7 to Oracle Linux 64 5.7

基于 Oracle Linux 64 5.7 的 EBS R12.1.1 详细克隆步骤
Section 0: Version
Source: R12.1.1 on Oracle Linux 64 5.7, SID=r12dev, host=r12dev.example.com
Target: Oracle Linux 64 5.7, host=r12uat.example.com (to be cloned: R12.1.1,SID=r12dev)
Target should have all necessary rpm packages installed and
have localhost & hostname with correct IP addresses mapped in /etc/hosts.
Section 1: Prerequisite Tasks
1.1 patch
9239089     R12.AD.B.DELTA.3
9171651:R12.OAM.B     12.1 RAPIDCLONE CONSOLIDATED FIXES JUL/2010
9833058:R12.OAM.B     HOT CLONE FAILS WITH ORA-00201 DURING RECOVERY MANAGER
12404574:R12.OAM.B     ORACLE_HOME REGISTRATION DOES NOT HAPPEN WITH CENTRAL INVENTORY ON LOZ
12598630:R12.OAM.B     R12.1 ONE-OFF FOR S_DB_LISTENER BUG 12362010
1.2 run autoconfig on app tier
$ADMIN_SCRIPTS_HOME/adautocfg.sh
1.3 synchronize appsutil to db tier
run perl $AD_TOP/bin/admkappsutil.pl by ap user,
switch to db user and copy generated appsutil.zip from app tier to $ORACLE_HOME on db tier,
unzip -o appsutil.zip by db user.
1.4 run autoconfig on db tier
$ORACLE_HOME/appsutil/scripts/SID_hostname/adautocfg.sh
1.5 maintain snapshot information
AD Administration(adadmin)->Maintain Snapshot Information->Update Current View Snapshot->Update Complete APPL_TOP
Note: If a snapshot was never created for that APPL_TOP, you will need to create a new one before proceeding with the clone.
Section 2: Cloning Tasks
2.1 Prepare the source system
2.1.1 Prepare the source system database tier for cloning
Log on to the source system as the ORACLE user, and run the following commands:
$ cd [RDBMS ORACLE_HOME]/appsutil/scripts/[CONTEXT_NAME]
$ perl adpreclone.pl dbTier
2.1.2 Prepare the source system application tier for cloning
Log on to the source system as the APPLMGR user, and run the following commands on each node that contains an APPL_TOP:
$ cd [INST_TOP]/admin/scripts
$ perl adpreclone.pl appsTier
2.2 Copy the source system to the target system
2.2.1 Copy the application tier file system
Log on to the source system application tier nodes as the APPLMGR user and shut down the application tier server processes. Copy the following application tier directories from the source node to the target application tier node:
    [APPL_TOP]
    [COMMON_TOP]
    Applications Technology Stack:
        [OracleAS Tools ORACLE_HOME]
        [OracleAS Web IAS_ORACLE_HOME]
rsync -aPv apr12dev@192.168.10.101:/u01/r12dev/apps/tech_st .
rsync -aPv apr12dev@192.168.10.101:/u01/r12dev/apps/apps_st .
ap tier = technology stack + application stack
technology stack(tech_st)  = $ORACLE_HOME + $IAS_ORACLE_HOME
application stack(apps_st) = $APPL_TOP + $COMMON_TOP
-bash-3.2$ echo $APPL_TOP
/u01/r12dev/apps/apps_st/appl
-bash-3.2$ echo $COMMON_TOP
/u01/r12dev/apps/apps_st/comn
-bash-3.2$ echo $ORACLE_HOME
/u01/r12dev/apps/tech_st/10.1.2
-bash-3.2$ echo $IAS_ORACLE_HOME
/u01/r12dev/apps/tech_st/10.1.3
2.2.2 Copy the database node file system
Log on to the source system database node as the ORACLE user, and then:
    Perform a normal shutdown of the source system database
    Copy the database (.dbf) files from the source system to the target system
    Copy the source database ORACLE_HOME to the target system
    Start the source Applications system database and application tier processes
rsync -aPv orr12dev@192.168.10.101:/u01/r12dev/db/tech_st .
rsync -aPv orr12dev@192.168.10.101:/u01/r12dev/db/apps_st .
-bash-3.2$ echo $ORACLE_HOME
/u01/r12dev/db/tech_st/11.1.0
-bash-3.2$ ll /u01/r12dev/db/tech_st/
total 4
drwxr-xr-x 77 orr12dev dba 4096 Nov 22 01:13 11.1.0
-bash-3.2$ ll /u01/r12dev/db/apps_st/
total 4
drwxr-xr-x 2 orr12dev dba 4096 Nov 17 14:11 data
2.3 Configure the target system
2.3.1 Configure the target system database server
Log on to the target system as the ORACLE user and enter the following commands:
$ cd [RDBMS ORACLE_HOME]/appsutil/clone/bin
$ perl adcfgclone.pl dbTier
[orr12uat@r12uat bin]$ perl adcfgclone.pl dbTier
                     Copyright (c) 2002 Oracle Corporation
                        Redwood Shores, California, USA
                        Oracle Applications Rapid Clone
                                 Version 12.0.0
                      adcfgclone Version 120.31.12010000.8
Enter the APPS password :
Running:
/u01/r12uat/db/tech_st/11.1.0/appsutil/clone/bin/../jre/bin/java -Xmx600M -cp /u01/r12uat/db/tech_st/11.1.0/appsutil/clone/jlib/java:/u01/r12uat/db/tech_st/11.1.0/appsutil/clone/jlib/xmlparserv2.jar:/u01/r12uat/db/tech_st/11.1.0/appsutil/clone/jlib/ojdbc5.jar oracle.apps.ad.context.CloneContext -e /u01/r12uat/db/tech_st/11.1.0/appsutil/clone/bin/../context/db/CTXORIG.xml -validate -pairsfile /tmp/adpairsfile_5777.lst -stage /u01/r12uat/db/tech_st/11.1.0/appsutil/clone  2> /tmp/adcfgclone_5777.err; echo $? > /tmp/adcfgclone_5777.res
Log file located at /u01/r12uat/db/tech_st/11.1.0/appsutil/clone/bin/CloneContext_1123015149.log
Provide the values required for creation of the new Database Context file.
Target System Hostname (virtual or normal) [r12uat] :
Target Instance is RAC (y/n) [n] :
Target System Database SID : r12uat
Target System Base Directory : /u01/r12uat
Target System utl_file_dir Directory List : /usr/tmp, /u01/r12uat/db/tech_st/11.1.0/appsutil/outbound/r12uat_r12uat
Number of DATA_TOP's on the Target System [1] :
Target System DATA_TOP Directory 1 [/u01/r12dev/db/apps_st/data] : /u01/r12uat/db/apps_st/data
Target System RDBMS ORACLE_HOME Directory [/u01/r12uat/db/tech_st/11.1.0] :
Do you want to preserve the Display [null] (y/n)  :
Target System Display [r12uat:0.0] :
Do you want the the target system to have the same port values as the source system (y/n) [y] ? :
Target System Port Pool [0-99] : 0
Checking the port pool 0
done: Port Pool 0 is free
Report file located at /u01/r12uat/db/tech_st/11.1.0/appsutil/temp/portpool.lst
Complete port information available at /u01/r12uat/db/tech_st/11.1.0/appsutil/temp/portpool.lst
...
-- verify
. SID_hostname.env
lsnrctl status
sqlplus / as sysdba
select instance_name,status from v$instance;
2.3.2 Configure the target system application tier server nodes
Log on to the target system as the APPLMGR user and enter the following commands:
$ cd [COMMON_TOP]/clone/bin
$ perl adcfgclone.pl appsTier
may need manually create inst directory and change owner to ap owner.
[root@r12uat inst]# pwd
/u01/r12uat/inst
[root@r12uat inst]# ll -ld
drwxr-xr-x 3 apr12uat dba 4096 11-23 02:24 .
[apr12uat@r12uat bin]$ perl adcfgclone.pl appsTier
                     Copyright (c) 2002 Oracle Corporation
                        Redwood Shores, California, USA
                        Oracle Applications Rapid Clone
                                 Version 12.0.0
                      adcfgclone Version 120.31.12010000.8
Enter the APPS password :
Running:
/u01/r12uat/apps/apps_st/comn/clone/bin/../jre/bin/java -Xmx600M -cp /u01/r12uat/apps/apps_st/comn/clone/jlib/java:/u01/r12uat/apps/apps_st/comn/clone/jlib/xmlparserv2.jar:/u01/r12uat/apps/apps_st/comn/clone/jlib/ojdbc14.jar oracle.apps.ad.context.CloneContext -e /u01/r12uat/apps/apps_st/comn/clone/bin/../context/apps/CTXORIG.xml -validate -pairsfile /tmp/adpairsfile_11821.lst -stage /u01/r12uat/apps/apps_st/comn/clone  2> /tmp/adcfgclone_11821.err; echo $? > /tmp/adcfgclone_11821.res
Log file located at /u01/r12uat/apps/apps_st/comn/clone/bin/CloneContext_1123022411.log
Provide the values required for creation of the new APPL_TOP Context file.
Target System Hostname (virtual or normal) [r12uat] :
Target System Database SID : r12uat
Target System Database Server Node [r12uat] :
Target System Database Domain Name [example.com] :
Target System Base Directory : /u01/r12uat
Target System Tools ORACLE_HOME Directory [/u01/r12uat/apps/tech_st/10.1.2] :
Target System Web ORACLE_HOME Directory [/u01/r12uat/apps/tech_st/10.1.3] :
Target System APPL_TOP Directory [/u01/r12uat/apps/apps_st/appl] :
Target System COMMON_TOP Directory [/u01/r12uat/apps/apps_st/comn] :
Target System Instance Home Directory [/u01/r12uat/inst] :
Target System Root Service [enabled] :
Target System Web Entry Point Services [enabled] :
Target System Web Application Services [enabled] :
Target System Batch Processing Services [enabled] :
Target System Other Services [disabled] :
Do you want to preserve the Display [r12dev:0.0] (y/n)  : n
Target System Display [r12uat:0.0] :  
Do you want the the target system to have the same port values as the source system (y/n) [y] ? :
Complete port information available at /u01/r12uat/apps/apps_st/comn/clone/bin/out/r12uat_r12uat/portpool.lst
UTL_FILE_DIR on database tier consists of the following directories.
1. /usr/tmp
2. /usr/tmp
3. /u01/r12uat/db/tech_st/11.1.0/appsutil/outbound/r12uat_r12uat
4. /u01/r12uat/db/tech_st/11.1.0/appsutil/outbound/r12uat_r12uat
5. /usr/tmp
Choose a value which will be set as APPLPTMP value on the target node [1] :
Creating the new APPL_TOP Context file from :
  /u01/r12uat/apps/apps_st/appl/ad/12.0.0/admin/template/adxmlctx.tmp
The new APPL_TOP context file has been created :
  /u01/r12uat/inst/apps/r12uat_r12uat/appl/admin/r12uat_r12uat.xml
Log file located at /u01/r12uat/apps/apps_st/comn/clone/bin/CloneContext_1123022411.log
Check Clone Context logfile /u01/r12uat/apps/apps_st/comn/clone/bin/CloneContext_1123022411.log for details.
...
--verify
submit request - Active Users, check if normal completed and output there.
Section 3: Finishing Tasks
Update profile options
Rapid Clone updates only site level profile options. If any other profile options are set to instance specific values, you must update them manually.
Update printer settings
If the new cloned system needs to utilize different printers, update the target system with the new printer settings now.
Update Workflow configuration settings
Cloning an Oracle Applications instance will not update the host and instance-specific information used by Oracle Workflow. Review the tables and columns listed in Table 4 to check for any instance-specific data in the Workflow configuration on the target system.
Verify the APPLCSF variable setting
Source the APPS environment and review that the variable APPLCSF (identifying the top-level directory for concurrent manager log and output files) points to a suitable directory. To modify it, change the value of the s_applcsf variable in the context file and then run AutoConfig.
Update the SESSION_COOKIE_DOMAIN value in ICX_PARAMETERS
If the target system is in a different domain name than the source system and SESSION_COOKIE_DOMAIN was not null in the source system, update that value to reflect the new domain name.
Re-Implement SSL and SSO configuration
If the Source System was SSL or SSO enabled, and the Target is wished to be SSL or SSO enabled, then reconfigure the Target by following the SSL/SSO documentation. Otherwise, if the Target is wished to be non-SSL or non-SSO, then follow the same SSL/SSO documentation to undo the SSL/SSO setup.
REF:
Cloning Oracle Applications Release 12 with Rapid Clone [ID 406982.1]

FROM MY BLOG: http://blog.csdn.net/t0nsha/article/details/8214791

--EOF--

4. What's the meaning of "options=nocompiledb" when doing adpatch ? when we may try to do this ?

Meaning:

Tells AutoPatch to automatically compile invalid objects in the database after running actions normally found in the database driver.
Scenario:
In cases where multiple non-merged patches are applied in a maintenance window, you can use nocompiledb to save time. However, merging multiple patches and applying a single merged patch is usually a better strategy.
--EOF--

你可能感兴趣的文章
Hibernate中通过FetchProfile的方式实现动态数据获取
查看>>
Hibernate中通过JPA entity graph的方式实现动态数据获取
查看>>
Hibernate中的数据获取方式及时机(fetching)
查看>>
Hibernate的二级缓存概述
查看>>
Hibernate二级缓存的全局配置
查看>>
Hibernate应用中通过JPA配置Entity缓存
查看>>
Hibernate中配置二级缓存的并发策略
查看>>
Hibernate的Entity cache(实体缓存)
查看>>
Hibernate中的Query cache(查询缓存)
查看>>
Hibernate的interceptors与events
查看>>
TestNG概述
查看>>
TestNG中测试方法的依赖关系详解
查看>>
TestNG中的运行时测试实例工厂详解
查看>>
TestNG测试的并发执行详解
查看>>
TestNG的监听器概述
查看>>
TestNG的IAnnotationTransformer监听器详解
查看>>
TestNG的IMethodInterceptor监听器详解
查看>>
TestNG的IHookable监听器详解
查看>>
TestNG的IConfigurable监听器详解
查看>>
TestNG的IConfigurationListener监听器详解
查看>>