how to zip ?
tar cvf - apps_St gzip -c > apps_st18june.tgz
Thursday, July 16, 2009
Oracle Applications Current Patchset Comparison Utility - patchsets.sh
Oracle Applications Current Patchsets Comparison Utility (Script to Analyze)
Program: patchsets.sh, Tool Version: 4.43
Last Updated: Mon June 08 12:17:10 EDT 2009
Purpose
This program (a unix shell script) was created to help customers evaluate the currently installed Oracle Applications' patchsets and Family Packs. The program compares the currently installed patchsets and family packs to the most recently available ones generated by Oracle Development. This is an Oracle Support provided script and therefore has limited support, but OAM also provides a means to check your patch history directly from the Product.
How it Works
This program utilizes the the applptch.txt file for 10.7-11.0. For 11i and R12, it utilizes a combination of tables such as AD_BUGS and AD_APPLIED_PATCHES to create the installed patch list. If the 11i release does not use these AD tables (11.5.4 or lower and have not applied 11i.AD.E or higher) it still supports using applptch.txt for 11i. In order to keep this script up to date, it is put out on the Oracle ftp site on a nightly basis with the most recent patchset/family pack listings included in it. Therefore, the patchset analysis that you do is only as up to date as the last time you download this script.
Scope & Application
This script can be used for 10.7, 11.0.x, 11.5.x, 12.0.x, and 12.1.x The patchset listings are generated automatically from the latest release information from Development. If a patchset referenced by this tool is not available on the external ftp site, an i-Tar can be logged to obtain it.
What is not included: APS Rollup Patches.
Please see: "How to Determine the Latest APS Rollup Patch Applied to the System" or Note 252108.1 for scripts to help analyze what Rollup patches have been applied.
Contents
1. Latest Patchsets Comparison Download Locations
2. Running the Patchsets Comparison Tool
3. Understanding the Patchset Comparison Output
4. More Details on the Patchsets Comparison Tool
5. Applied Patches SQL Report added for 11i/R12
6. Possible problems with this Tool
1. Latest Patchsets Comparison Download Locations
Unix or NT:
ftp://ftp.oracle.com/support/outgoing/PATCHSET_COMPARE_TOOL/patchsets.sh (External Access) (Oracle Internal Link)
Note: The NT version works with the MKS shell that is required for Release 11i. For comparison of Releases prior to 11i, copy the applptch.txt to a Unix machine and run the script there with the explicit path to the applptch.txt file. ie. $ patchsets.sh applptch=/tmp/applptch.txt
top
2. Running the Patchsets Comparison Tool
Warning: The patchsets.sh program is generated every night with the latest patchsets data in it.
So, this means that you need to get the latest version to get an up-to-date report.
Setup Requirements:
Must have connectivity to EBS database via sql*net with $TWO_TASK set
Source $APPL_TOP/APPSxx.env file or just setup database env such as ORACLE_HOME and TWO_TASK
# 11i - $ . $APPL_TOP/APPSORA.env
# R12 - $ . $APPL_TOP/APPS{sid}_{machine}.env
Note: As long as you can connect with sqlplus and $TWO_TASK, the script should have the access it needs.
Usage: $ patchsets.sh [connect=11i_login/pw|applptch=/path/applptch.txt] [-h]
[silent=y] default is n, [htmlout=file]
Example Help:
$ patchsets.sh -h
Check Applied Patchsets Tool - patchsets.sh
#############################################################################
## Name: patchsets.sh Version: 4.36
## By: steve.andrew@oracle.com Last Modified: Nov 09, 2007
## Written: 6/22/99
#############################################################################
##
## Usage: patchsets.sh connect=Apps_login/pw
## [ad_bug_date=DD-MON-YY] (11i/R12 only)
## [htmlout=file_name] - Report.txt converted to html
## [htmlout11i=file_name] - Report_11i.txt to html
## [htmloutR12=file_name] - Report_R12.txt to html
## [applptch=applptch_file.txt]
## [silent=y] default is n
##
## connect=apps/apps@connection (11i/R12 only)
## [ad_bug_date=DD-MON-YY] (11i/R12 only)
##
## [patch_list=ad_applied_patches|your_file.csv]
## default is to use: ad_bugs table
## It is alot faster to go against ad_applied_patches
## but this only works if you are NOT using admrgpch to
## merge patchsets. Also, if providing your_file.csv
## the format is: short_name, possible_patchset_number
## The short_name is not used but a value is required.
##
## New Reports
## a) Applied Patches
## $ ./patchsets.sh connect=apps/apps report=applied_patches
## Note: Gets generated automatically during normal runs, 11i/R12
## b) Merged Patches
## $ ./patchsets.sh connect=apps/apps@connection report=merged_patches
## [bug=patch#] | [product={short_name}] | [applied_date=DD-MON-YY]
## Note: Be sure to restrict to a patch or product and date or it could be huge!
##
## patchsets.sh -h|?|help (for Help)
##
## Additional Parms:
## If 11i and latest AD Patchset E or F
## or > 11.5.4
## connect=apps/apps@connection
## [patch_list=ad_applied_patches|your_file.csv]
## default is to use: ad_bugs table
#############################################################################
Purpose: To Aid in analysis of the latest available patchsets in relationship
to all patchsets that have been applied. If patches in the db the
program uses ad_bugs & ad_applied_patches table or applptch.txt file.
Typical Usage:
# 11i Usage when latest AD patchsets (E or more) have been applied or > 11.5.4
$ ./patchsets.sh connect=apps/apps (Most Common Usage)
$ ./patchsets.sh connect=apps/apps patch_list=ad_applied_patches
$ ./patchsets.sh connect=apps/apps@VIS1157 ad_bug_date=01-FEB-02
$ ./patchsets.sh
$ ./patchsets.sh applptch=/tmp/applptch.txt
$ ./patchsets.sh connect=apps/apps debug=y
$ ./patchsets.sh connect=apps/apps debug=y (if you have a problem send this)
$ ./patchsets.sh connect=apps/apps available=metalink
(Restrict to Metalink Available patchsets)
# All other Oracle Applications Installs
$ ./patchsets.sh
defaults to $APPL_TOP/admin/$TWO_TASK/applptch.txt or equiv
$ ./patchsets.sh applptch=/tmp/my_applptch.txt
NOTE: Removed 10sc, 10.7 and 10.7NCA support in version 4.12
Put back 10.7 in 4.13 due to need still in upgrade assistants program.
- For more information on this program, get the latest version,
and find examples of its use you can go to the following:
http://poseidon.us.oracle.com:7500/shtml/patchsets.sh (Internal)
or
ftp://ftp.oracle.com/support/outgoing/PATCHSET_COMPARE_TOOL/patchsets.sh (External)
Example Run:
$ ./patchsets.sh applptch=/applptch_11i.txt
The raw patchsets files have been put in your /tmp:
====================================================
/tmp/107NCA_patchsets.txt /tmp/110_patchsets.txt /tmp/16_patchsets.txt
/tmp/107_patchsets.txt /tmp/11i_patchsets.txt
====================================================
The Report.txt and Patch.csv files can be found
in your Current Directory: D:/lap/Scripts/patchsets
Report.txt - Patchset Comparison with ARU
Patch.csv - Listing(csv) of all patches applied
====================================================
Warning: This report is only as up-to-date as when it
was most recently downloaded by you...
Download the most recent version whenever you want to
get the updated ARU patchset listings.
Find Updates at:
http://poseidon.us.oracle.com:7500/shtml/patchsets.sh (Internal)
or
ftp://ftp.oracle.com/support/outgoing/PATCHSET_COMPARE_TOOL/patchsets.sh (External)
Example Html Output in Silent Mode:
$ ./patchsets.sh applptch=/applptch_11i.txt htmlout=Report.html silent=y
top
3. Understanding the Patchset Comparison Output
The patchsets.sh script is build every night by a cron job. The cron job first runs several sql scripts against our internal ARU system (maintained by Development) to get the latest patchset listing for each of the current releases. These listings are then merged by the cron into the patchsets.sh script which is then put on the oracle ftp site. This is why the results from running this script are only current at the time you download the script. This is IMPORTANT to remember.
For 10.7-11.0, the script simply greps the applptch.txt file to build a list of all the unique patch numbers. For 11i, the script generates the applied patchset listing from the ad_bugs and ad_applied_patches tables. It also utilizes other tables. At this time the program also generates a simple summary listing (Patch.csv) in comma delimited format of all the unique patches that will be compared. This Excel readable format may be useful for other purposes in your organization.
In 10.7-11.0, the top of the applptch.txt file has the Current Oracle Applications Release version (CURRENT_RELEASE: 1x.x.x). Based on this release version the program compares that versions current patchsets one-by-one and creates the Report.txt file showing if it is a patchset that you have applied, and the current ARU Status of that patchset. This patchsets listing includes all patchsets, not just the most recent. This allows for a complete listing of all the patchsets that have been applied to this applptch.txt file.
When using 11i, the Current Release is based on FND tables. This is then the basis of the Baseline patchset listing that are generated from and stored in the patchsets.sh program. These baseline patches along with your applied (ad_xx tables) patches is what is used to compare to the complete list of all 11i patchsets. (11i_patchsets.txt which is also generated when the patchsets.sh program executes against 11.5.X).
NOTE: The Output might not show the Minipack for some modules if they are not available on metalink for download. this might occur if they are only "Distributed" with Family Packs."
Typical Output of the Report.txt
A
$ more Report.txt
=============================================================================
=============================================================================
Report Generated: Tue Apr 19 12:16:55 EDT 2005 Tool Version: 4.19
Patchsets List Updated: Apr 18 22:30
Machine/OS: SunOS poseidon 5.8 Generic_108528-15 sun4u sparc SUNW,Sun-Blade-100
Domain: us.oracle.com
applptch Source: Patch.csv
Version from APPLPTCH: 11.5.5
Database: VIS1155
Limited Report to: APPLFULL and APPLSHAR products
APPLFULL: AK ALR AMS AP AR AS ASF ASO AST AU AX AZ BEN BIC BIL BIM BIS BIX BOM CCT CE CHV CN CRP CS CSC CSD CSF CSP CSR CSS CUF CUS CZ EC ECX ENG FA FII FLM FND FPT GL GMA GMD GME GMF GMI GML GMP GMS GR HRI HXC HXT HZ IBA IBE IBP IBU IBY ICX IEB IEM IEO IES IEU IEX IGW INV ISC JA JE JG JL JTF ME MRP MSC MSD MSO MSR OKC OKE OKS OKX ONT OPI OTA OZF OZP OZS PA PAY PER PJM PMI PN PO POA POM PSB PSP QA QP RG RHX RLM SSP VEA WIP WPS WSH WSM XDP XLA XNC XNM XNP XNS XTR
APPLSHAR: AD AMV ASG CUA CUI CUN CUP DT FF GHR IPA MFG OE PQH PQP RLA SHT VEH
Pseudo Products: ADX AME AML BPA CAC CSK CTB EDW EWS FWK HCT IGP IPATCH IRC ISX ITA JTA JTH JTO JTP JTT JTU JTY MSX OAM OCM OIE OIR OIT OWF PJR POV RCM RTC TXK UMX
Written By: Oracle Support, COE, SSANDREW
Program Updates: ftp://ftp.oracle.com/support/outgoing/PATCHSET_COMPARE_TOOL/patchsets.sh
Download Patchsets: Go to link below or click on Patches
from My Oracle Support
=============================================================================
Applied Patchsets that Match ARU:
FAMILY PACKS
Prod Patchset Bug RELEASED Release Status Distribution
=======================================================================================
dmf_pf 11i.DMF_PF.D 1551167 31-JAN-01 Patchset Superseded By_Metalink
dmf_pf 11i.DMF_PF.E 1745355 24-MAY-01 Patchset Superseded By_Metalink
fin_pf 11i.FIN_PF.C 2380068 16-AUG-02 Patchset Superseded By_Metalink
om_pf 11i.OM_PF.D 1550583 01-FEB-01 Patchset Superseded By_Metalink
om_pf 11i.OM_PF.E 1745389 31-MAY-01 Patchset Superseded By_Metalink
opm_pf 11i.OPM_PF.E 1614311 05-FEB-01 Patchset Superseded By_Metalink
opm_pf 11i.OPM_PF.F 1688968 30-MAR-01 Patchset Superseded By_Metalink
prc_pf 11i.PRC_PF.D 1554100 01-FEB-01 Patchset Superseded By_Metalink
prc_pf 11i.PRC_PF.E 1745369 18-MAY-01 Patchset Superseded By_Metalink
scp_pf 11i.SCP_PF.D 1552650 31-JAN-01 Patchset Superseded By_Metalink
scp_pf 11i.SCP_PF.E.1 1801717 14-MAY-01 Patchset Superseded By_Metalink
B
Applied Patchsets that Match ARU:
APPLIED PATCHSETS
Prod Patchset Bug RELEASED Release Status Distribution
=======================================================================================
abm 11i.ABM.D 1741310 31-MAY-01 Patchset Superseded By_Dev
ad 11i.AD.A 1351004 07-OCT-00 Patchset Superseded By_Metalink
ad 11i.AD.C 1475426 19-JAN-01 Patchset Superseded By_Metalink
ad 11i.AD.D 1627493 04-FEB-01 Patchset Superseded By_Metalink
ad 11i.AD.E 1945611 02-NOV-01 Patchset Superseded By_Metalink
ad 11i.AD.F 2141471 21-FEB-02 Patchset Superseded By_Metalink
ad 11i.AD.G 2344175 05-NOV-02 Patchset Superseded By_Metalink
ak 11i.AK.A 1343449 05-SEP-00 Patchset Superseded By_Metalink
ak 11i.AK.B 1455027 15-DEC-00 Patchset Superseded By_Metalink
ak 11i.AK.C 1553747 05-FEB-01 Patchset Superseded By_Metalink
alr 11i.ALR.A 1348277 07-SEP-00 Patchset Superseded By_Metalink
alr 11i.ALR.B 1459186 12-OCT-00 Patchset Superseded By_Metalink
alr 11i.ALR.C 1575525 02-FEB-01 Patchset Superseded By_Metalink
ams 11i.AMS.B 1339203 07-OCT-00 Patchset Superseded Not_Distributed
ams 11i.AMS.C 1568669 18-FEB-01 Patchset Superseded By_Dev
amv 11i.AMV.D 1615230 27-FEB-01 Patchset Superseded By_Metalink
...
xtr 11i.XTR.C 1565561 02-FEB-01 Patchset Superseded By_Metalink
xtr 11i.XTR.D 1711366 18-MAY-01 Patchset Superseded By_Metalink
xtr 11i.XTR.G 2223523 12-APR-02 Patchset Superseded By_Metalink
C
The Most Recent Release Family Packs (Not Included Above) are:
=======================================================================================
atg_pf 11i.ATG_PF.H 3438354 11-NOV-04 Patchset Released By_Metalink
bis_pf 11i.BIS_PF.D.1 4054609 21-JAN-05 Patchset Released By_Metalink
cc_pf 11i.CC_PF.R 3202573 05-NOV-04 Patchset Released By_Metalink
com_pf 11i.COM_PF.A 2036253 04-NOV-01 Patchset Released By_Dev
dmf_pf 11i.DMF_PF.J 2771139 17-SEP-04 Patchset Released Not_Distributed
exchg_pf 11i.EXCHG_PF.C 2147366 31-JAN-02 Patchset Released By_Metalink
fin_pf 11i.FIN_PF.F 3153675 05-NOV-04 Patchset Released By_Metalink
...
The Most Recent Release Patchsets (Not Included Above) are:
=======================================================================================
ad 11i.AD.I.1 4038964 02-DEC-04 Patchset Released By_Metalink
adx 11i.ADX.E.1 3817226 08-JUL-04 Patchset Released By_Metalink
ak 11i.AK.G 3263645 04-NOV-04 Patchset Released By_Metalink
alr 11i.ALR.G 3261254 04-NOV-04 Patchset Released By_Metalink
ame 11i.AME.A 3962268 01-DEC-04 Patchset Released By_Metalink
aml 11i.AML.B 3236242 08-OCT-04 Patchset Released Not_Distributed
ams 11i.AMS.I 3025816 08-OCT-04 Patchset Released Not_Distributed
amv 11i.AMV.I 3134012 07-OCT-04 Patchset Released Not_Distributed
...
D
Base Patchset List for 11.5.5 included below:
=============================================================================
1612182 - bic Customer Intelligence, Minipack I
1610593 - bim Marketing Intelligence, Minipack H
1612601 - bil Sales Intelligence, Minipack I
1791967 - bix Call Center Intelligence, Minipack K
...
Note: This does not include the prior Baseline listings which are also used to build the applied list (B). Those listings can be found in the /tmp directory as 11XX_Base.txt.
Over Each Section:
A The top of the script shows when the patchset data was last updated that this report was run against: "Patchsets List Updated: Apr 4 22:30", when the report was run: "Report Generated: Thu Apr 5 12:07:08 EDT 2001", the current Release Version from the applptch.txt file or the database: "Version from APPLPTCH: 11.5.1" and where to get a new version of the patchsets.sh script with the latest patchset data.
B This is a complete list of the patchsets applied after install or matching the compared applied list of patches from AD_ tables or the applptch.txt file.
C These are the patchsets that have a "Released" Status and were not found in A. In other words, these are the most recent patchsets for each of the Products that have not yet been applied.
D The baseline for any given product includes patchsets that are applied to that release before it is packaged up and put on the CD. This is the listing that is used along with all the previous version patchset baselines to build your installed baseline listing. ie. If you are currently on 11.5.4, the baseline listing is 11.5.1-11.5.4. These baseline patchset listings are taken from the "Release Notes" for each release. More recently, that baseline has been augmented with the FND_PRODUCT_INSTALLATIONS.PATCH_LEVEL listing when the base release CD was published. They can be found after a run in the /tmp directory as XXXX_Base.txt where XXXX would be the version like 1157, 1159, 1200, 1211. ie. 1211_Base.txt.
Misc Notes about the Report.txt Report
Note: APPLFULL and APPLSHAR
This Most Recent Released Patchsets are limited to the installed and shared
products listed in APPLFULL and APPLSHAR variables. For 11i, this is based on
an fnd table when using connect= and an ad_bugs table exists.
Note2: Baseline Details
Starting with version 3.6 of this program, the Baseline patchsets
and Family Packs are included in the above listing so the list is
alot more than you have applied. To see what was delivered for each
baseline review the /tmp/11XX_Base.txt files.
Note3:
Not_Distributed: the patch is only available by a Family Pack. No one off patch available
By_Dev : the patch is only available by a Family Pack. No one off patch available
By_Metalink : the patch can be downloaded from My Oracle Support. see 'Patches and Updates' center.
Note4:
Some products have have started patchset releases that are not in APPLFULL or APPLSHAR listing.
This means the program will have to be changed to support listing the latest of all patchsets and not
just the FULL/SHARED patchsets based products. An example of this is JTF is now distributed as
JTA and JTT, but both still patch JTF_TOP.
Typical Output of the Report_11i.txt
$ more Report_11i.txt
=============================================================================
Report Generated: Tue Apr 19 12:17:10 EDT 2005 Tool Version: 4.19
Patchsets List Updated: Apr 18 22:30
Machine/OS: SunOS poseidon 5.8 Generic_108528-15 sun4u sparc SUNW,Sun-Blade-100
Domain: us.oracle.com
applptch Source: Patch.csv
Version from APPLPTCH: 11.5.5
Database: VIS1155
Limited Report to: APPLFULL and APPLSHAR products
APPLFULL: AK ALR AMS AP AR AS ASF ASO AST AU AX AZ BEN BIC BIL BIM BIS BIX BOM CCT CE CHV CN CRP CS CSC CSD CSF CSP CSR CSS CUF CUS CZ EC ECX ENG FA FII FLM FND FPT GL GMA GMD GME GMF GMI GML GMP GMS GR HRI HXC HXT HZ IBA IBE IBP IBU IBY ICX IEB IEM IEO IES IEU IEX IGW INV ISC JA JE JG JL JTF ME MRP MSC MSD MSO MSR OKC OKE OKS OKX ONT OPI OTA OZF OZP OZS PA PAY PER PJM PMI PN PO POA POM PSB PSP QA QP RG RHX RLM SSP VEA WIP WPS WSH WSM XDP XLA XNC XNM XNP XNS XTR
APPLSHAR: AD AMV ASG CUA CUI CUN CUP DT FF GHR IPA MFG OE PQH PQP RLA SHT VEH
Pseudo Products: ADX AME AML BPA CAC CSK CTB EDW EWS FWK HCT IGP IPATCH IRC ISX ITA JTA JTH JTO JTP JTT JTU JTY MSX OAM OCM OIE OIR OIT OWF PJR POV RCM RTC TXK UMX
Written By: Oracle Support Services
Program Updates: ftp://ftp.oracle.com/support/outgoing/PATCHSET_COMPARE_TOOL/
Download Patchsets: Go to link below or click on Patches
on My Oracle Support
=============================================================================
FAMILY PACK PATCHES
Product Baseline Version Running Version Latest Available,Status
------- ----------------- --------------- -----------------------
atg_pf 11i.ATG_PF.H(3438354), Rel-By_Metal
bis_pf 11i.BIS_PF.D.1(4054609), Rel-By_Metal
cc_pf 11i.CC_PF.R(3202573), Rel-By_Metal
com_pf 11i.COM_PF.A(2036253), Rel-By_Dev
dmf_pf 11i.DMF_PF.E(1745355) 11i.DMF_PF.E(1745355) 11i.DMF_PF.J(2771139), Rel-Not_Dist
exchg_pf 11i.EXCHG_PF.C(2147366), Rel-By_Metal
fin_pf 11i.FIN_PF.C(2380068) 11i.FIN_PF.F(3153675), Rel-By_Metal
finap_pf 11i.FINAP_PF.A(1712173), Obs-By_Metal
finar_pf 11i.FINAR_PF.A(1712197), Obs-By_Metal
...
FULLY INSTALLED PRODUCTS
Product Baseline Version Running Version Latest Available,Status
------- ----------------- --------------- -----------------------
ak 11i.AK.C(1553747) 11i.AK.C(1553747) 11i.AK.G(3263645), Rel-By_Metal
alr 11i.ALR.C(1575525) 11i.ALR.C(1575525) 11i.ALR.G(3261254), Rel-By_Metal
ams 11i.AMS.B(1339203) 11i.AMS.C(1568669) 11i.AMS.I(3025816), Rel-Not_Dist
ap 11i.AP.E(1715446) 11i.AP.J(2375849) 11i.AP.M(3151444), Rel-Not_Dist
...
SHARED INSTALL PRODUCTS
Product Baseline Version Running Version Latest Available,Status
------- ----------------- --------------- -----------------------
ad 11i.AD.D(1627493) 11i.AD.G(2344175) 11i.AD.I.1(4038964), Rel-By_Metal
amv 11i.AMV.D(1615230) 11i.AMV.D(1615230) 11i.AMV.I(3134012), Rel-Not_Dist
asg 11i.ASG.D(1580949) 11i.ASG.D(1580949) 11i.ASG.R(3263401), Rel-By_Metal
cua 11i.CUA.B(1422989) 11i.CUA.B(1422989) 11i.CUA.B(1422989), Rel-By_Metal
...
PSEUDO PRODUCTS
Product Baseline Version Running Version Latest Available,Status
------- ----------------- --------------- -----------------------
adx 11i.ADX.E.1(3817226), Rel-By_Metal
ame 11i.AME.A(3962268), Rel-By_Metal
...
ipatch 11i.IPATCH.B(2495518), Rel-By_Dev
jta 11i.JTA.F(3262486), Rel-By_Metal
jth 11i.JTH.R(3100686), Rel-By_Metal
jto 11i.JTO.R(3105667), Rel-By_Metal
jtp 11i.JTP.A(2014756), Obs-By_Metal
jtt 11i.JTT.E(3127042), Rel-By_Metal
...
oam 11i.OAM.H(3258830), Rel-By_Metal
ocm 11i.OCM.B(3373464), Rel-By_Dev
oie 11i.OIE.B(1633913) 11i.OIE.E(1960506) 11i.OIE.J(3618125), Rel-By_Metal
oir 11i.OIR.C(2396507) 11i.OIR.F(3151380), Rel-By_Metal
oit 11i.OIT.B(1675976) 11i.OIT.B(1675976) 11i.OIT.D(2397276), Rel-By_Metal
owf 11i.OWF.H(3258819), Rel-By_Metal
...
Report_11i.txt Details
This is generally the same as the Report.txt report except it provides the Baseline, Running and Available all on one line. It does not include the patchsets availability, which can be obtained on Metalink or by looking at the Report.txt report. Some patchsets, may not be distributed only in Family Packs. Please review the following definitions:
Baseline Version: This is the baseline release version that came with your release i.e. 11.5.X
Running Version: This would be at a higher level than the Baseline if any patchsets have been applied for that Product.
Latest Available, Status: This is the highest available version available for that release. The Status part of this field shows two parts. 1) Patchsets/Family Pack Status 2) Distribution Status. They are explained below.
Status Field
1) PATCHSET STATUS:
Rel=Released, Sup=Superseded, Obs=Obsoleted
2) DISTRIBUTION STATUS:
By_Metal=On Metalink, Not_Dist=Not Available, By_Dev=Available from Development only
The Status Field was added in version 4.14. To have the report only show patchsets available for download from metalink, use the optional command line flag: latest=metalink
What are PSEUDO PRODUCTS? These are products that are not part of the core applications, but supporting these core products. A couple of good examples would be Workflow (OWF), and Oracle Application Manager (OAM). These were added in V. 4.17.
What are Consolidated Updates (CU) ? It is the latest Family of Patches for ATG and all critical patches since the latest ATG patchset. So with the new CU for ATG, 11i.ATG_PF.H(3438354) is the last Family Pack for ATG. All future code code updates for ATG will be released by CUs. The CUs only require that you apply the latest one.
top
4. More Details on the Patchsets Comparison Tool
This tool can be downloaded automatically from the Oracle ftp site and then run as a cron job with the output going to a web page. This will allow an internal web site that will always show what patchsets have been applied to that APPL_TOP.
ie. Basic Steps:
1. Use a web based get or download tool like wget.
2. Then run the script to generate the output in html format to the correct directory:
1. Download the patchsets.sh script
$ wget ftp://ftp.oracle.com/support/outgoing/PATCHSET_COMPARE_TOOL/patchsets.sh
--13:29:35-- ftp://ftp.oracle.com/support/outgoing/PATCHSET_COMPARE_TOOL/patchsets.sh
.sh
=> `patchsets.sh'
Connecting to www-proxy.us.oracle.com:21... connected!
Logging in as anonymous@oracle-ftp ... Logged in!
==> TYPE I ... done. ==> CWD apps/outgoing/patchanal ... done.
==> PORT ... done. ==> RETR patchsets.sh ... done.
Length: 177,074 (unauthoritative)
0K -> .......... .......... .......... .......... .......... [ 28%]
50K -> .......... .......... .......... .......... .......... [ 57%]
100K -> .......... .......... .......... .......... .......... [ 86%]
150K -> .......... .......... .. [100%]
13:29:39 (67.63 KB/s) - `patchsets.sh' saved [177074]
2. Run your comparison and output to html
$ patchsets.sh htmlout=$OA_HTML/Report.html silent=y
top
5. Applied Patches SQL Report added for 11i/R12
If the report is run against 11i or R12 an additional sql report is generated showing the applied patches:
# 11i - Applied_Patches_11i.sql generates Applied_Patches_11i.txt
# R12 - Applied_Patches_R12.sql generates Applied_Patches_R12.txt
These reports can also be run without running the complete patchset comparison or using the provided sql generated after a normal run.
$ patchsets.sh connect=apps/apps@$TWO_TASK report=applied_patches
top
6. Possible problems with this Tool
If you have problems running this tool:
1) Make sure the program is executable and will run: $ chmod 755 patchsets.sh, patchsets.sh -h
If 11i/R12, make sure you can connect to the database. ie. $ tnsping $TWO_TASK, and sqlplus apps/apps.
2) If the program is taking a long time to run and your not sure it is working: $ ps -ef | grep `whoami`
There should be some grep and awk processes running while the program runs. It has been run with applptch.txt files as large as 22 Megs. If it seems to hang, try splitting the file into two leaving the top file header lines.
3) If the program fails for other reasons, then use the patchset lists created in the /tmp directory to do your own analysis. This tool is being offered as is, and is still early in its development. Therefore, please do not call support on its use. Any questions on current patchsets for a given release and product should be directed to each Product Support Group. For example: If you are not sure on the release status for GL's Patchset B, then log an i-Tar to the GL group.
The raw patchsets listings get put in the /tmp directory when the program runs:
====================================================
/tmp/107NCA_patchsets.txt /tmp/16_patchsets.txt /tmp/107_patchsets.txt
/tmp/110_patchsets.txt /tmp/11i_patchsets.txt /tmp/1101_Base.txt
/tmp/1102_Base.txt /tmp/1152_Base.txt /tmp/1153_Base.txt
====================================================
Note: The files named xyz_Base.txt are a list of the Baseline patchsets that came with a given release
or the list of patches that came with that upgrade release.
4) Platform Specific Issues
TO RUN UNDER NT with MKS:
a) Get to the drive where the appl_top is.
C:> D:
D:\>
Make a tmp directory on that drives root.
D:> mkdir tmp (this is where the patchset lists get created)
b) cd to the APPL_TOP path and then execute the envshell to setup the env variables.
D:\> cd D:\apps\visappl
D:\apps\visappl> envshell
-> A new window spawns with the correct env settings, use it for step 3
c) Start the MKS SHELL,
D:\apps\visappl> sh
$
d) Run the patchsets program from the APPL_TOP/admin/ directory
$ cd /admin/VIS
$ ./patchsets.sh applptch=applptch.txt
IF AIX GIVES: 0403-029 BUFFER ERROR:
a) Install X11.dt.rte on AIX (this gave me /usr/dt/bin/dtksh version 93 of ksh)
b) I modified your script (just a little)
add: #!/usr/dt/bin/dtksh (as the first line of the script)
c) Running the script then no longer had the
./patchsets.sh[57]: 0403-029
AIX Update: If you are getting the above error, check that you have the latest version of the program.
This was fixed in Version: 4.17 to not need the newer AIX shell. There was also an
option aix=y which is no longer needed for AIX either.
5) FAMILY PACK WARNING:
Relationship between patchsets and family packs:
The Report_11i.txt has been confusing because of the Most Recently Available column.
The question is what should go in this column
A) The most recently available patchsets Available for Download on Metalink OR
B) The most recently available patchsets EVEN if Not available on Metalink for Download (but may be found in a Family Pack)
The User base requested A) for a while, and we are currently back to B). In order to make this less confusing, a legend and ",Status" was added to the "Latest Available" field.
The Status Field typically looks like this:
FAMILY PACK PATCHES
Product Baseline Version Running Version Latest Available,Status
------- ----------------- --------------- -----------------------
atg_pf 11i.ATG_PF.H(3438354), Rel-By_Metal
dmf_pf 11i.DMF_PF.E(1745355) 11i.DMF_PF.E(1745355) 11i.DMF_PF.J(2771139), Rel-Not_Dist
exchg_pf 11i.EXCHG_PF.C(2147366), Rel-By_Metal
fin_pf 11i.FIN_PF.C(2380068) 11i.FIN_PF.F(3153675), Rel-By_Metal
finap_pf 11i.FINAP_PF.A(1712173), Obs-By_Metal
...
As of v.4.14, the limit to only show patchsets available for download on Metalink was removed because the bulk of users wanted the old way back. So, an optional flag to limit Latest Available to patches only available on metailink for download was added: ie. Add: available=metalink to command line.
Key to new Status Field
DEVELOPMENT STATUS:
Rel=Released, Sup=Superseded, Obs=Obsoleted
DISTRIBUTION STATUS:
By_Metal=On Metalink, Not_Dist=Not Available, By_Dev=Available from Development only
So, in summary, if you have some patchsets that are the latest and not available by Metalink, you will probably have to apply them by a Family Pack.
For specific patchsets questions, please first check ARU on Metalink.
This note was last updated for on: Tue Apr 19 12:17:10 EDT 2005 and for patchsets.sh Tool Version: 4.19.
top
6) Ftp Problem
If the ftp link is not working, try manual ftp as follows:
NOTE: Put the full path in for the get.
ftp ftp.oracle.com
login as an anonymous user, and then:
get support/outgoing/PATCHSET_COMPARE_TOOL/patchsets.sh
.
Program: patchsets.sh, Tool Version: 4.43
Last Updated: Mon June 08 12:17:10 EDT 2009
Purpose
This program (a unix shell script) was created to help customers evaluate the currently installed Oracle Applications' patchsets and Family Packs. The program compares the currently installed patchsets and family packs to the most recently available ones generated by Oracle Development. This is an Oracle Support provided script and therefore has limited support, but OAM also provides a means to check your patch history directly from the Product.
How it Works
This program utilizes the the applptch.txt file for 10.7-11.0. For 11i and R12, it utilizes a combination of tables such as AD_BUGS and AD_APPLIED_PATCHES to create the installed patch list. If the 11i release does not use these AD tables (11.5.4 or lower and have not applied 11i.AD.E or higher) it still supports using applptch.txt for 11i. In order to keep this script up to date, it is put out on the Oracle ftp site on a nightly basis with the most recent patchset/family pack listings included in it. Therefore, the patchset analysis that you do is only as up to date as the last time you download this script.
Scope & Application
This script can be used for 10.7, 11.0.x, 11.5.x, 12.0.x, and 12.1.x The patchset listings are generated automatically from the latest release information from Development. If a patchset referenced by this tool is not available on the external ftp site, an i-Tar can be logged to obtain it.
What is not included: APS Rollup Patches.
Please see: "How to Determine the Latest APS Rollup Patch Applied to the System" or Note 252108.1 for scripts to help analyze what Rollup patches have been applied.
Contents
1. Latest Patchsets Comparison Download Locations
2. Running the Patchsets Comparison Tool
3. Understanding the Patchset Comparison Output
4. More Details on the Patchsets Comparison Tool
5. Applied Patches SQL Report added for 11i/R12
6. Possible problems with this Tool
1. Latest Patchsets Comparison Download Locations
Unix or NT:
ftp://ftp.oracle.com/support/outgoing/PATCHSET_COMPARE_TOOL/patchsets.sh (External Access) (Oracle Internal Link)
Note: The NT version works with the MKS shell that is required for Release 11i. For comparison of Releases prior to 11i, copy the applptch.txt to a Unix machine and run the script there with the explicit path to the applptch.txt file. ie. $ patchsets.sh applptch=/tmp/applptch.txt
top
2. Running the Patchsets Comparison Tool
Warning: The patchsets.sh program is generated every night with the latest patchsets data in it.
So, this means that you need to get the latest version to get an up-to-date report.
Setup Requirements:
Must have connectivity to EBS database via sql*net with $TWO_TASK set
Source $APPL_TOP/APPSxx.env file or just setup database env such as ORACLE_HOME and TWO_TASK
# 11i - $ . $APPL_TOP/APPSORA.env
# R12 - $ . $APPL_TOP/APPS{sid}_{machine}.env
Note: As long as you can connect with sqlplus and $TWO_TASK, the script should have the access it needs.
Usage: $ patchsets.sh [connect=11i_login/pw|applptch=/path/applptch.txt] [-h]
[silent=y] default is n, [htmlout=file]
Example Help:
$ patchsets.sh -h
Check Applied Patchsets Tool - patchsets.sh
#############################################################################
## Name: patchsets.sh Version: 4.36
## By: steve.andrew@oracle.com Last Modified: Nov 09, 2007
## Written: 6/22/99
#############################################################################
##
## Usage: patchsets.sh connect=Apps_login/pw
## [ad_bug_date=DD-MON-YY] (11i/R12 only)
## [htmlout=file_name] - Report.txt converted to html
## [htmlout11i=file_name] - Report_11i.txt to html
## [htmloutR12=file_name] - Report_R12.txt to html
## [applptch=applptch_file.txt]
## [silent=y] default is n
##
## connect=apps/apps@connection (11i/R12 only)
## [ad_bug_date=DD-MON-YY] (11i/R12 only)
##
## [patch_list=ad_applied_patches|your_file.csv]
## default is to use: ad_bugs table
## It is alot faster to go against ad_applied_patches
## but this only works if you are NOT using admrgpch to
## merge patchsets. Also, if providing your_file.csv
## the format is: short_name, possible_patchset_number
## The short_name is not used but a value is required.
##
## New Reports
## a) Applied Patches
## $ ./patchsets.sh connect=apps/apps report=applied_patches
## Note: Gets generated automatically during normal runs, 11i/R12
## b) Merged Patches
## $ ./patchsets.sh connect=apps/apps@connection report=merged_patches
## [bug=patch#] | [product={short_name}] | [applied_date=DD-MON-YY]
## Note: Be sure to restrict to a patch or product and date or it could be huge!
##
## patchsets.sh -h|?|help (for Help)
##
## Additional Parms:
## If 11i and latest AD Patchset E or F
## or > 11.5.4
## connect=apps/apps@connection
## [patch_list=ad_applied_patches|your_file.csv]
## default is to use: ad_bugs table
#############################################################################
Purpose: To Aid in analysis of the latest available patchsets in relationship
to all patchsets that have been applied. If patches in the db the
program uses ad_bugs & ad_applied_patches table or applptch.txt file.
Typical Usage:
# 11i Usage when latest AD patchsets (E or more) have been applied or > 11.5.4
$ ./patchsets.sh connect=apps/apps (Most Common Usage)
$ ./patchsets.sh connect=apps/apps patch_list=ad_applied_patches
$ ./patchsets.sh connect=apps/apps@VIS1157 ad_bug_date=01-FEB-02
$ ./patchsets.sh
$ ./patchsets.sh applptch=/tmp/applptch.txt
$ ./patchsets.sh connect=apps/apps debug=y
$ ./patchsets.sh connect=apps/apps debug=y (if you have a problem send this)
$ ./patchsets.sh connect=apps/apps available=metalink
(Restrict to Metalink Available patchsets)
# All other Oracle Applications Installs
$ ./patchsets.sh
defaults to $APPL_TOP/admin/$TWO_TASK/applptch.txt or equiv
$ ./patchsets.sh applptch=/tmp/my_applptch.txt
NOTE: Removed 10sc, 10.7 and 10.7NCA support in version 4.12
Put back 10.7 in 4.13 due to need still in upgrade assistants program.
- For more information on this program, get the latest version,
and find examples of its use you can go to the following:
http://poseidon.us.oracle.com:7500/shtml/patchsets.sh (Internal)
or
ftp://ftp.oracle.com/support/outgoing/PATCHSET_COMPARE_TOOL/patchsets.sh (External)
Example Run:
$ ./patchsets.sh applptch=/applptch_11i.txt
The raw patchsets files have been put in your /tmp:
====================================================
/tmp/107NCA_patchsets.txt /tmp/110_patchsets.txt /tmp/16_patchsets.txt
/tmp/107_patchsets.txt /tmp/11i_patchsets.txt
====================================================
The Report.txt and Patch.csv files can be found
in your Current Directory: D:/lap/Scripts/patchsets
Report.txt - Patchset Comparison with ARU
Patch.csv - Listing(csv) of all patches applied
====================================================
Warning: This report is only as up-to-date as when it
was most recently downloaded by you...
Download the most recent version whenever you want to
get the updated ARU patchset listings.
Find Updates at:
http://poseidon.us.oracle.com:7500/shtml/patchsets.sh (Internal)
or
ftp://ftp.oracle.com/support/outgoing/PATCHSET_COMPARE_TOOL/patchsets.sh (External)
Example Html Output in Silent Mode:
$ ./patchsets.sh applptch=/applptch_11i.txt htmlout=Report.html silent=y
top
3. Understanding the Patchset Comparison Output
The patchsets.sh script is build every night by a cron job. The cron job first runs several sql scripts against our internal ARU system (maintained by Development) to get the latest patchset listing for each of the current releases. These listings are then merged by the cron into the patchsets.sh script which is then put on the oracle ftp site. This is why the results from running this script are only current at the time you download the script. This is IMPORTANT to remember.
For 10.7-11.0, the script simply greps the applptch.txt file to build a list of all the unique patch numbers. For 11i, the script generates the applied patchset listing from the ad_bugs and ad_applied_patches tables. It also utilizes other tables. At this time the program also generates a simple summary listing (Patch.csv) in comma delimited format of all the unique patches that will be compared. This Excel readable format may be useful for other purposes in your organization.
In 10.7-11.0, the top of the applptch.txt file has the Current Oracle Applications Release version (CURRENT_RELEASE: 1x.x.x). Based on this release version the program compares that versions current patchsets one-by-one and creates the Report.txt file showing if it is a patchset that you have applied, and the current ARU Status of that patchset. This patchsets listing includes all patchsets, not just the most recent. This allows for a complete listing of all the patchsets that have been applied to this applptch.txt file.
When using 11i, the Current Release is based on FND tables. This is then the basis of the Baseline patchset listing that are generated from and stored in the patchsets.sh program. These baseline patches along with your applied (ad_xx tables) patches is what is used to compare to the complete list of all 11i patchsets. (11i_patchsets.txt which is also generated when the patchsets.sh program executes against 11.5.X).
NOTE: The Output might not show the Minipack for some modules if they are not available on metalink for download. this might occur if they are only "Distributed" with Family Packs."
Typical Output of the Report.txt
A
$ more Report.txt
=============================================================================
=============================================================================
Report Generated: Tue Apr 19 12:16:55 EDT 2005 Tool Version: 4.19
Patchsets List Updated: Apr 18 22:30
Machine/OS: SunOS poseidon 5.8 Generic_108528-15 sun4u sparc SUNW,Sun-Blade-100
Domain: us.oracle.com
applptch Source: Patch.csv
Version from APPLPTCH: 11.5.5
Database: VIS1155
Limited Report to: APPLFULL and APPLSHAR products
APPLFULL: AK ALR AMS AP AR AS ASF ASO AST AU AX AZ BEN BIC BIL BIM BIS BIX BOM CCT CE CHV CN CRP CS CSC CSD CSF CSP CSR CSS CUF CUS CZ EC ECX ENG FA FII FLM FND FPT GL GMA GMD GME GMF GMI GML GMP GMS GR HRI HXC HXT HZ IBA IBE IBP IBU IBY ICX IEB IEM IEO IES IEU IEX IGW INV ISC JA JE JG JL JTF ME MRP MSC MSD MSO MSR OKC OKE OKS OKX ONT OPI OTA OZF OZP OZS PA PAY PER PJM PMI PN PO POA POM PSB PSP QA QP RG RHX RLM SSP VEA WIP WPS WSH WSM XDP XLA XNC XNM XNP XNS XTR
APPLSHAR: AD AMV ASG CUA CUI CUN CUP DT FF GHR IPA MFG OE PQH PQP RLA SHT VEH
Pseudo Products: ADX AME AML BPA CAC CSK CTB EDW EWS FWK HCT IGP IPATCH IRC ISX ITA JTA JTH JTO JTP JTT JTU JTY MSX OAM OCM OIE OIR OIT OWF PJR POV RCM RTC TXK UMX
Written By: Oracle Support, COE, SSANDREW
Program Updates: ftp://ftp.oracle.com/support/outgoing/PATCHSET_COMPARE_TOOL/patchsets.sh
Download Patchsets: Go to link below or click on Patches
from My Oracle Support
=============================================================================
Applied Patchsets that Match ARU:
FAMILY PACKS
Prod Patchset Bug RELEASED Release Status Distribution
=======================================================================================
dmf_pf 11i.DMF_PF.D 1551167 31-JAN-01 Patchset Superseded By_Metalink
dmf_pf 11i.DMF_PF.E 1745355 24-MAY-01 Patchset Superseded By_Metalink
fin_pf 11i.FIN_PF.C 2380068 16-AUG-02 Patchset Superseded By_Metalink
om_pf 11i.OM_PF.D 1550583 01-FEB-01 Patchset Superseded By_Metalink
om_pf 11i.OM_PF.E 1745389 31-MAY-01 Patchset Superseded By_Metalink
opm_pf 11i.OPM_PF.E 1614311 05-FEB-01 Patchset Superseded By_Metalink
opm_pf 11i.OPM_PF.F 1688968 30-MAR-01 Patchset Superseded By_Metalink
prc_pf 11i.PRC_PF.D 1554100 01-FEB-01 Patchset Superseded By_Metalink
prc_pf 11i.PRC_PF.E 1745369 18-MAY-01 Patchset Superseded By_Metalink
scp_pf 11i.SCP_PF.D 1552650 31-JAN-01 Patchset Superseded By_Metalink
scp_pf 11i.SCP_PF.E.1 1801717 14-MAY-01 Patchset Superseded By_Metalink
B
Applied Patchsets that Match ARU:
APPLIED PATCHSETS
Prod Patchset Bug RELEASED Release Status Distribution
=======================================================================================
abm 11i.ABM.D 1741310 31-MAY-01 Patchset Superseded By_Dev
ad 11i.AD.A 1351004 07-OCT-00 Patchset Superseded By_Metalink
ad 11i.AD.C 1475426 19-JAN-01 Patchset Superseded By_Metalink
ad 11i.AD.D 1627493 04-FEB-01 Patchset Superseded By_Metalink
ad 11i.AD.E 1945611 02-NOV-01 Patchset Superseded By_Metalink
ad 11i.AD.F 2141471 21-FEB-02 Patchset Superseded By_Metalink
ad 11i.AD.G 2344175 05-NOV-02 Patchset Superseded By_Metalink
ak 11i.AK.A 1343449 05-SEP-00 Patchset Superseded By_Metalink
ak 11i.AK.B 1455027 15-DEC-00 Patchset Superseded By_Metalink
ak 11i.AK.C 1553747 05-FEB-01 Patchset Superseded By_Metalink
alr 11i.ALR.A 1348277 07-SEP-00 Patchset Superseded By_Metalink
alr 11i.ALR.B 1459186 12-OCT-00 Patchset Superseded By_Metalink
alr 11i.ALR.C 1575525 02-FEB-01 Patchset Superseded By_Metalink
ams 11i.AMS.B 1339203 07-OCT-00 Patchset Superseded Not_Distributed
ams 11i.AMS.C 1568669 18-FEB-01 Patchset Superseded By_Dev
amv 11i.AMV.D 1615230 27-FEB-01 Patchset Superseded By_Metalink
...
xtr 11i.XTR.C 1565561 02-FEB-01 Patchset Superseded By_Metalink
xtr 11i.XTR.D 1711366 18-MAY-01 Patchset Superseded By_Metalink
xtr 11i.XTR.G 2223523 12-APR-02 Patchset Superseded By_Metalink
C
The Most Recent Release Family Packs (Not Included Above) are:
=======================================================================================
atg_pf 11i.ATG_PF.H 3438354 11-NOV-04 Patchset Released By_Metalink
bis_pf 11i.BIS_PF.D.1 4054609 21-JAN-05 Patchset Released By_Metalink
cc_pf 11i.CC_PF.R 3202573 05-NOV-04 Patchset Released By_Metalink
com_pf 11i.COM_PF.A 2036253 04-NOV-01 Patchset Released By_Dev
dmf_pf 11i.DMF_PF.J 2771139 17-SEP-04 Patchset Released Not_Distributed
exchg_pf 11i.EXCHG_PF.C 2147366 31-JAN-02 Patchset Released By_Metalink
fin_pf 11i.FIN_PF.F 3153675 05-NOV-04 Patchset Released By_Metalink
...
The Most Recent Release Patchsets (Not Included Above) are:
=======================================================================================
ad 11i.AD.I.1 4038964 02-DEC-04 Patchset Released By_Metalink
adx 11i.ADX.E.1 3817226 08-JUL-04 Patchset Released By_Metalink
ak 11i.AK.G 3263645 04-NOV-04 Patchset Released By_Metalink
alr 11i.ALR.G 3261254 04-NOV-04 Patchset Released By_Metalink
ame 11i.AME.A 3962268 01-DEC-04 Patchset Released By_Metalink
aml 11i.AML.B 3236242 08-OCT-04 Patchset Released Not_Distributed
ams 11i.AMS.I 3025816 08-OCT-04 Patchset Released Not_Distributed
amv 11i.AMV.I 3134012 07-OCT-04 Patchset Released Not_Distributed
...
D
Base Patchset List for 11.5.5 included below:
=============================================================================
1612182 - bic Customer Intelligence, Minipack I
1610593 - bim Marketing Intelligence, Minipack H
1612601 - bil Sales Intelligence, Minipack I
1791967 - bix Call Center Intelligence, Minipack K
...
Note: This does not include the prior Baseline listings which are also used to build the applied list (B). Those listings can be found in the /tmp directory as 11XX_Base.txt.
Over Each Section:
A The top of the script shows when the patchset data was last updated that this report was run against: "Patchsets List Updated: Apr 4 22:30", when the report was run: "Report Generated: Thu Apr 5 12:07:08 EDT 2001", the current Release Version from the applptch.txt file or the database: "Version from APPLPTCH: 11.5.1" and where to get a new version of the patchsets.sh script with the latest patchset data.
B This is a complete list of the patchsets applied after install or matching the compared applied list of patches from AD_ tables or the applptch.txt file.
C These are the patchsets that have a "Released" Status and were not found in A. In other words, these are the most recent patchsets for each of the Products that have not yet been applied.
D The baseline for any given product includes patchsets that are applied to that release before it is packaged up and put on the CD. This is the listing that is used along with all the previous version patchset baselines to build your installed baseline listing. ie. If you are currently on 11.5.4, the baseline listing is 11.5.1-11.5.4. These baseline patchset listings are taken from the "Release Notes" for each release. More recently, that baseline has been augmented with the FND_PRODUCT_INSTALLATIONS.PATCH_LEVEL listing when the base release CD was published. They can be found after a run in the /tmp directory as XXXX_Base.txt where XXXX would be the version like 1157, 1159, 1200, 1211. ie. 1211_Base.txt.
Misc Notes about the Report.txt Report
Note: APPLFULL and APPLSHAR
This Most Recent Released Patchsets are limited to the installed and shared
products listed in APPLFULL and APPLSHAR variables. For 11i, this is based on
an fnd table when using connect= and an ad_bugs table exists.
Note2: Baseline Details
Starting with version 3.6 of this program, the Baseline patchsets
and Family Packs are included in the above listing so the list is
alot more than you have applied. To see what was delivered for each
baseline review the /tmp/11XX_Base.txt files.
Note3:
Not_Distributed: the patch is only available by a Family Pack. No one off patch available
By_Dev : the patch is only available by a Family Pack. No one off patch available
By_Metalink : the patch can be downloaded from My Oracle Support. see 'Patches and Updates' center.
Note4:
Some products have have started patchset releases that are not in APPLFULL or APPLSHAR listing.
This means the program will have to be changed to support listing the latest of all patchsets and not
just the FULL/SHARED patchsets based products. An example of this is JTF is now distributed as
JTA and JTT, but both still patch JTF_TOP.
Typical Output of the Report_11i.txt
$ more Report_11i.txt
=============================================================================
Report Generated: Tue Apr 19 12:17:10 EDT 2005 Tool Version: 4.19
Patchsets List Updated: Apr 18 22:30
Machine/OS: SunOS poseidon 5.8 Generic_108528-15 sun4u sparc SUNW,Sun-Blade-100
Domain: us.oracle.com
applptch Source: Patch.csv
Version from APPLPTCH: 11.5.5
Database: VIS1155
Limited Report to: APPLFULL and APPLSHAR products
APPLFULL: AK ALR AMS AP AR AS ASF ASO AST AU AX AZ BEN BIC BIL BIM BIS BIX BOM CCT CE CHV CN CRP CS CSC CSD CSF CSP CSR CSS CUF CUS CZ EC ECX ENG FA FII FLM FND FPT GL GMA GMD GME GMF GMI GML GMP GMS GR HRI HXC HXT HZ IBA IBE IBP IBU IBY ICX IEB IEM IEO IES IEU IEX IGW INV ISC JA JE JG JL JTF ME MRP MSC MSD MSO MSR OKC OKE OKS OKX ONT OPI OTA OZF OZP OZS PA PAY PER PJM PMI PN PO POA POM PSB PSP QA QP RG RHX RLM SSP VEA WIP WPS WSH WSM XDP XLA XNC XNM XNP XNS XTR
APPLSHAR: AD AMV ASG CUA CUI CUN CUP DT FF GHR IPA MFG OE PQH PQP RLA SHT VEH
Pseudo Products: ADX AME AML BPA CAC CSK CTB EDW EWS FWK HCT IGP IPATCH IRC ISX ITA JTA JTH JTO JTP JTT JTU JTY MSX OAM OCM OIE OIR OIT OWF PJR POV RCM RTC TXK UMX
Written By: Oracle Support Services
Program Updates: ftp://ftp.oracle.com/support/outgoing/PATCHSET_COMPARE_TOOL/
Download Patchsets: Go to link below or click on Patches
on My Oracle Support
=============================================================================
FAMILY PACK PATCHES
Product Baseline Version Running Version Latest Available,Status
------- ----------------- --------------- -----------------------
atg_pf 11i.ATG_PF.H(3438354), Rel-By_Metal
bis_pf 11i.BIS_PF.D.1(4054609), Rel-By_Metal
cc_pf 11i.CC_PF.R(3202573), Rel-By_Metal
com_pf 11i.COM_PF.A(2036253), Rel-By_Dev
dmf_pf 11i.DMF_PF.E(1745355) 11i.DMF_PF.E(1745355) 11i.DMF_PF.J(2771139), Rel-Not_Dist
exchg_pf 11i.EXCHG_PF.C(2147366), Rel-By_Metal
fin_pf 11i.FIN_PF.C(2380068) 11i.FIN_PF.F(3153675), Rel-By_Metal
finap_pf 11i.FINAP_PF.A(1712173), Obs-By_Metal
finar_pf 11i.FINAR_PF.A(1712197), Obs-By_Metal
...
FULLY INSTALLED PRODUCTS
Product Baseline Version Running Version Latest Available,Status
------- ----------------- --------------- -----------------------
ak 11i.AK.C(1553747) 11i.AK.C(1553747) 11i.AK.G(3263645), Rel-By_Metal
alr 11i.ALR.C(1575525) 11i.ALR.C(1575525) 11i.ALR.G(3261254), Rel-By_Metal
ams 11i.AMS.B(1339203) 11i.AMS.C(1568669) 11i.AMS.I(3025816), Rel-Not_Dist
ap 11i.AP.E(1715446) 11i.AP.J(2375849) 11i.AP.M(3151444), Rel-Not_Dist
...
SHARED INSTALL PRODUCTS
Product Baseline Version Running Version Latest Available,Status
------- ----------------- --------------- -----------------------
ad 11i.AD.D(1627493) 11i.AD.G(2344175) 11i.AD.I.1(4038964), Rel-By_Metal
amv 11i.AMV.D(1615230) 11i.AMV.D(1615230) 11i.AMV.I(3134012), Rel-Not_Dist
asg 11i.ASG.D(1580949) 11i.ASG.D(1580949) 11i.ASG.R(3263401), Rel-By_Metal
cua 11i.CUA.B(1422989) 11i.CUA.B(1422989) 11i.CUA.B(1422989), Rel-By_Metal
...
PSEUDO PRODUCTS
Product Baseline Version Running Version Latest Available,Status
------- ----------------- --------------- -----------------------
adx 11i.ADX.E.1(3817226), Rel-By_Metal
ame 11i.AME.A(3962268), Rel-By_Metal
...
ipatch 11i.IPATCH.B(2495518), Rel-By_Dev
jta 11i.JTA.F(3262486), Rel-By_Metal
jth 11i.JTH.R(3100686), Rel-By_Metal
jto 11i.JTO.R(3105667), Rel-By_Metal
jtp 11i.JTP.A(2014756), Obs-By_Metal
jtt 11i.JTT.E(3127042), Rel-By_Metal
...
oam 11i.OAM.H(3258830), Rel-By_Metal
ocm 11i.OCM.B(3373464), Rel-By_Dev
oie 11i.OIE.B(1633913) 11i.OIE.E(1960506) 11i.OIE.J(3618125), Rel-By_Metal
oir 11i.OIR.C(2396507) 11i.OIR.F(3151380), Rel-By_Metal
oit 11i.OIT.B(1675976) 11i.OIT.B(1675976) 11i.OIT.D(2397276), Rel-By_Metal
owf 11i.OWF.H(3258819), Rel-By_Metal
...
Report_11i.txt Details
This is generally the same as the Report.txt report except it provides the Baseline, Running and Available all on one line. It does not include the patchsets availability, which can be obtained on Metalink or by looking at the Report.txt report. Some patchsets, may not be distributed only in Family Packs. Please review the following definitions:
Baseline Version: This is the baseline release version that came with your release i.e. 11.5.X
Running Version: This would be at a higher level than the Baseline if any patchsets have been applied for that Product.
Latest Available, Status: This is the highest available version available for that release. The Status part of this field shows two parts. 1) Patchsets/Family Pack Status 2) Distribution Status. They are explained below.
Status Field
1) PATCHSET STATUS:
Rel=Released, Sup=Superseded, Obs=Obsoleted
2) DISTRIBUTION STATUS:
By_Metal=On Metalink, Not_Dist=Not Available, By_Dev=Available from Development only
The Status Field was added in version 4.14. To have the report only show patchsets available for download from metalink, use the optional command line flag: latest=metalink
What are PSEUDO PRODUCTS? These are products that are not part of the core applications, but supporting these core products. A couple of good examples would be Workflow (OWF), and Oracle Application Manager (OAM). These were added in V. 4.17.
What are Consolidated Updates (CU) ? It is the latest Family of Patches for ATG and all critical patches since the latest ATG patchset. So with the new CU for ATG, 11i.ATG_PF.H(3438354) is the last Family Pack for ATG. All future code code updates for ATG will be released by CUs. The CUs only require that you apply the latest one.
top
4. More Details on the Patchsets Comparison Tool
This tool can be downloaded automatically from the Oracle ftp site and then run as a cron job with the output going to a web page. This will allow an internal web site that will always show what patchsets have been applied to that APPL_TOP.
ie. Basic Steps:
1. Use a web based get or download tool like wget.
2. Then run the script to generate the output in html format to the correct directory:
1. Download the patchsets.sh script
$ wget ftp://ftp.oracle.com/support/outgoing/PATCHSET_COMPARE_TOOL/patchsets.sh
--13:29:35-- ftp://ftp.oracle.com/support/outgoing/PATCHSET_COMPARE_TOOL/patchsets.sh
.sh
=> `patchsets.sh'
Connecting to www-proxy.us.oracle.com:21... connected!
Logging in as anonymous@oracle-ftp ... Logged in!
==> TYPE I ... done. ==> CWD apps/outgoing/patchanal ... done.
==> PORT ... done. ==> RETR patchsets.sh ... done.
Length: 177,074 (unauthoritative)
0K -> .......... .......... .......... .......... .......... [ 28%]
50K -> .......... .......... .......... .......... .......... [ 57%]
100K -> .......... .......... .......... .......... .......... [ 86%]
150K -> .......... .......... .. [100%]
13:29:39 (67.63 KB/s) - `patchsets.sh' saved [177074]
2. Run your comparison and output to html
$ patchsets.sh htmlout=$OA_HTML/Report.html silent=y
top
5. Applied Patches SQL Report added for 11i/R12
If the report is run against 11i or R12 an additional sql report is generated showing the applied patches:
# 11i - Applied_Patches_11i.sql generates Applied_Patches_11i.txt
# R12 - Applied_Patches_R12.sql generates Applied_Patches_R12.txt
These reports can also be run without running the complete patchset comparison or using the provided sql generated after a normal run.
$ patchsets.sh connect=apps/apps@$TWO_TASK report=applied_patches
top
6. Possible problems with this Tool
If you have problems running this tool:
1) Make sure the program is executable and will run: $ chmod 755 patchsets.sh, patchsets.sh -h
If 11i/R12, make sure you can connect to the database. ie. $ tnsping $TWO_TASK, and sqlplus apps/apps.
2) If the program is taking a long time to run and your not sure it is working: $ ps -ef | grep `whoami`
There should be some grep and awk processes running while the program runs. It has been run with applptch.txt files as large as 22 Megs. If it seems to hang, try splitting the file into two leaving the top file header lines.
3) If the program fails for other reasons, then use the patchset lists created in the /tmp directory to do your own analysis. This tool is being offered as is, and is still early in its development. Therefore, please do not call support on its use. Any questions on current patchsets for a given release and product should be directed to each Product Support Group. For example: If you are not sure on the release status for GL's Patchset B, then log an i-Tar to the GL group.
The raw patchsets listings get put in the /tmp directory when the program runs:
====================================================
/tmp/107NCA_patchsets.txt /tmp/16_patchsets.txt /tmp/107_patchsets.txt
/tmp/110_patchsets.txt /tmp/11i_patchsets.txt /tmp/1101_Base.txt
/tmp/1102_Base.txt /tmp/1152_Base.txt /tmp/1153_Base.txt
====================================================
Note: The files named xyz_Base.txt are a list of the Baseline patchsets that came with a given release
or the list of patches that came with that upgrade release.
4) Platform Specific Issues
TO RUN UNDER NT with MKS:
a) Get to the drive where the appl_top is.
C:> D:
D:\>
Make a tmp directory on that drives root.
D:> mkdir tmp (this is where the patchset lists get created)
b) cd to the APPL_TOP path and then execute the envshell to setup the env variables.
D:\> cd D:\apps\visappl
D:\apps\visappl> envshell
-> A new window spawns with the correct env settings, use it for step 3
c) Start the MKS SHELL,
D:\apps\visappl> sh
$
d) Run the patchsets program from the APPL_TOP/admin/ directory
$ cd /admin/VIS
$ ./patchsets.sh applptch=applptch.txt
IF AIX GIVES: 0403-029 BUFFER ERROR:
a) Install X11.dt.rte on AIX (this gave me /usr/dt/bin/dtksh version 93 of ksh)
b) I modified your script (just a little)
add: #!/usr/dt/bin/dtksh (as the first line of the script)
c) Running the script then no longer had the
./patchsets.sh[57]: 0403-029
AIX Update: If you are getting the above error, check that you have the latest version of the program.
This was fixed in Version: 4.17 to not need the newer AIX shell. There was also an
option aix=y which is no longer needed for AIX either.
5) FAMILY PACK WARNING:
Relationship between patchsets and family packs:
The Report_11i.txt has been confusing because of the Most Recently Available column.
The question is what should go in this column
A) The most recently available patchsets Available for Download on Metalink OR
B) The most recently available patchsets EVEN if Not available on Metalink for Download (but may be found in a Family Pack)
The User base requested A) for a while, and we are currently back to B). In order to make this less confusing, a legend and ",Status" was added to the "Latest Available" field.
The Status Field typically looks like this:
FAMILY PACK PATCHES
Product Baseline Version Running Version Latest Available,Status
------- ----------------- --------------- -----------------------
atg_pf 11i.ATG_PF.H(3438354), Rel-By_Metal
dmf_pf 11i.DMF_PF.E(1745355) 11i.DMF_PF.E(1745355) 11i.DMF_PF.J(2771139), Rel-Not_Dist
exchg_pf 11i.EXCHG_PF.C(2147366), Rel-By_Metal
fin_pf 11i.FIN_PF.C(2380068) 11i.FIN_PF.F(3153675), Rel-By_Metal
finap_pf 11i.FINAP_PF.A(1712173), Obs-By_Metal
...
As of v.4.14, the limit to only show patchsets available for download on Metalink was removed because the bulk of users wanted the old way back. So, an optional flag to limit Latest Available to patches only available on metailink for download was added: ie. Add: available=metalink to command line.
Key to new Status Field
DEVELOPMENT STATUS:
Rel=Released, Sup=Superseded, Obs=Obsoleted
DISTRIBUTION STATUS:
By_Metal=On Metalink, Not_Dist=Not Available, By_Dev=Available from Development only
So, in summary, if you have some patchsets that are the latest and not available by Metalink, you will probably have to apply them by a Family Pack.
For specific patchsets questions, please first check ARU on Metalink.
This note was last updated for on: Tue Apr 19 12:17:10 EDT 2005 and for patchsets.sh Tool Version: 4.19.
top
6) Ftp Problem
If the ftp link is not working, try manual ftp as follows:
NOTE: Put the full path in for the get.
ftp ftp.oracle.com
login as an anonymous user, and then:
get support/outgoing/PATCHSET_COMPARE_TOOL/patchsets.sh
.
How to check which Techstack patchsets have been applied
SET head off Lines 120 pages 100
col n_patch format A65
col bug_number format A10
col patch_name format A10
spool atg_pf_ptch_level.txt
select ' atg_pf ' FROM dual;
/
select bug_number, decode(bug_number,
'3438354', '11i.ATG_PF.H'
,'4017300' ,'11i.ATG_PF.H.RUP1'
,'4125550' ,'11i.ATG_PF.H.RUP2'
,'4334965' ,'11i.ATG_PF.H RUP3'
,'4676589' ,'11i.ATG_PF.H RUP4'
,'5382500' ,'11i.ATG_PF.H RUP5 HELP'
,'5473858' ,'11i.ATG_PF.H.5'
,'5674941' ,'11i.ATG_PF.H RUP5 SSO Integrat'
,'5903765' ,'11i.ATG_PF.H RUP6'
,'6117031' ,'11i.ATG_PF.H RUP6 SSO 10g Integration'
,'6330890' ,'11i.ATG_PF.H RUP6 HELP'
) n_patch, last_update_date
FROM ad_bugs
WHERE bug_number
IN ( '3438354', '4017300', '4125550', '4334965', '4676589', '5382500', '5473858', '5674941', '5903765', '6117031', '6330890' );
col n_patch format A65
col bug_number format A10
col patch_name format A10
spool atg_pf_ptch_level.txt
select ' atg_pf ' FROM dual;
/
select bug_number, decode(bug_number,
'3438354', '11i.ATG_PF.H'
,'4017300' ,'11i.ATG_PF.H.RUP1'
,'4125550' ,'11i.ATG_PF.H.RUP2'
,'4334965' ,'11i.ATG_PF.H RUP3'
,'4676589' ,'11i.ATG_PF.H RUP4'
,'5382500' ,'11i.ATG_PF.H RUP5 HELP'
,'5473858' ,'11i.ATG_PF.H.5'
,'5674941' ,'11i.ATG_PF.H RUP5 SSO Integrat'
,'5903765' ,'11i.ATG_PF.H RUP6'
,'6117031' ,'11i.ATG_PF.H RUP6 SSO 10g Integration'
,'6330890' ,'11i.ATG_PF.H RUP6 HELP'
) n_patch, last_update_date
FROM ad_bugs
WHERE bug_number
IN ( '3438354', '4017300', '4125550', '4334965', '4676589', '5382500', '5473858', '5674941', '5903765', '6117031', '6330890' );
Clonning 11i EBS
Cloning Oracle Application:
There are three phases to the cloning process:
1.Prepare the Source System
Execute the following commands to prepare the Source System for cloning.
a.Prepare the Source System Database Tier for cloning
Log on to the Source System as the ORACLE user and run the following commands:
cd
perl adpreclone.pl dbTier
b.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
perl adpreclone.pl appsTier
2.Copy the Source System to the Target System
Copy the Application Tier File System from the Source Applications System to the Target Node by
executing the following steps in the order listed. Ensure the Application Tier files copied to
the Target System are owned by the Target APPLMGR user, and that the Database Tier files are owned
by the ORACLE user.
a.Copy the Application Tier File System
Log on to the Source System Application Tier Nodes as the APPLMGR user.
Shut down the Application Tier Server processes
Copy the following Application Tier directories from the Source Node to the Target Application
Tier Node:
<806 ORACLE_HOME>
b.Copy the Database Tier File System
Log on to the Source System Database Node as the ORACLE user.
Perform a normal shutdown of the Source System Database
Copy the Database (DBF) files from the Source to the Target System
Copy the Source Database ORACLE_HOME to the Target System
Start up the Source Applications System Database and Application Tier processes
Note: Unix/Linux users, make sure that the softlinks are preserved when copying.
3.Configure the Target System
Execute the following commands to configure the Target System. You will be prompted for the Target
System specific values (SID, Paths, Ports, etc)
a.Configure the Target System Database Server
Log on to the Target System as the ORACLE user and type the following commands to configure and
start the Database:
cd
perl adcfgclone.pl dbTier
b.Configure the Target System Application Tier Server Nodes
Log on to the Target System as the APPLMGR user and type the following commands:
cd
perl adcfgclone.pl appsTier
Attention: Windows users only:
add <806 ORACLE_HOME>\bin to the System Path before running this step.
Wednesday, July 15, 2009
Cloning Oracle Applications Release 12 with Rapid Clone
Terminology
Cloning is the process used to create a copy of an existing Oracle Applications system. There are various scenarios for cloning an Oracle Applications system, including:
* Standard cloning - Making a copy of an existing Oracle Applications system, for example a copy of a production system to test updates.
* System scale-up - Adding new machines to an Oracle Applications system to provide the capacity for processing an increased workload.
* System transformations - Altering system data or file systems, including actions such as platform migration, data scrambling, and provisioning of high availability architectures.
* Patching and upgrading - Delivering new versions of Applications components, and providing a mechanism for creating rolling environments to minimize downtime.
An important principle in Oracle Applications cloning is that the system is cloned, rather than the topology. Producing an exact copy of the patch level and data is much more important than creating an exact copy of the topology, as a cloned system must be able to provide the same output to the end user as the source system. However, while a cloned system need not have the full topology of its source, it must have available to it all the topology components that are available to the source.
Conventions used in this document include the following:
Term or Usage Meaning or Action
Source system Oracle Applications system being cloned.
Target system Oracle Applications system being created as a copy of the source.
APPLMGR User that owns the application tier file system (APPL_TOP and application tier technology stack).
ORACLE User that owns the database tier file system (RDBMS ORACLE_HOME and database files).
CONTEXT_NAME The CONTEXT_NAME variable refers to the name of the Applications context file. By default, CONTEXT_NAME is_.
Monospace Text Represents command line text. Type this command exactly as shown.
< > Text enclosed in angle brackets represents a variable. Substitute a value for the variable text. Do not type the angle brackets.
Section 1: Prerequisite Tasks
Before cloning, prepare the source system by applying any required patches and running AutoConfig.
1. Verify OS requirements on target system
Before cloning to a new server, ensure the target system meets all the requirements for Oracle Applications Release 12 stated on the Oracle Applications Release Notes, and on the Oracle Applications Installation and Upgrade Notes for each Platform. For the latest installation guidelines refer to My Oracle Support Knowledge Document 405565.1.
Note: On Microsoft Windows, Rapid Clone is not currently certified for use from Domain User Accounts.
2. Verify source and target system software components and versions
In addition to the Oracle Applications software requirements (see Oracle Applications Installation Guide: Using Rapid Install), the following software component versions must exist on the source or target nodes as applicable. The 'Location' column indicates the node where the software component must reside.
Table 1: Software Requirements
Software Component Minimum Version Required Location Comments
Zip 2.3 All source system nodes Download from InfoZip. Zip must be in your $PATH.
Unzip 5.52 All source system nodes Download from InfoZip. Unzip must be in your $PATH.
Operating system utilities N/A All target system nodes The required operating system utilities for your platform must be in your $PATH when running adcfgclone.pl. For example, make, ld, and ar on UNIX. Refer to Oracle Applications Installation Guide: Using Rapid Install (see Footnote 1)
Perl 5.x All target system nodes Use the Perl shipped with OracleAS 10.1.3 and Database 10g, or download it from Perl.com. Perl must be in your $PATH, and $PERL5LIB must be set correctly before cloning.
Footnote 1 This is the Release 12.1.1 version; versions for earlier releases are also available from the Oracle E-Business Suite Online Documentation Library
3. Apply the latest AD patch
Apply patch 6510214 (R12.AD.A.DELTA.4) or higher. Refer to My Oracle Support to obtain the latest AD patch.
4. Apply the latest AutoConfig template patch
Update the Oracle Applications file system with the latest AutoConfig template files by applying the TXK AutoConfig Template rollup patch to all application tier server nodes. Refer to My Oracle Support Knowledge Document 387859.1 for details of the latest AutoConfig Template rollup patch.
5. Apply the latest Rapid Clone patches
Update the Oracle Applications file system with the latest Rapid Clone files by applying the following patches to all Applications nodes.
* For Release 12.0:
Apply patches as listed in Table 2.
Table 2: Release 12.0 Rapid Clone patches
Patch Description
5484000 Oracle E-Business Suite 12.0.2 Release Update Pack (RUP2) or higher
7164226 12.0 RAPIDCLONE CONSOLIDATED FIXES MAY/2009
7699109 Required for Microsoft Windows Server 2003 R2 (64-bit AMD64 and Intel EM64T)
8221919 Required for HP Itanium (HP-IA) and Microsoft Windows (32-bit).
8246709 Required for Microsoft Windows if using OracleAS 10.1.3.4. This patch must be re-applied to the OracleAS 10.1.3.4 ORACLE_HOME before every cloning operation.
* For Release 12.1:
No patches are required at present.
Note: If new Rapid Clone or AutoConfig updates are applied to the system, steps 6, 7, and 8 below must be executed again in order to apply the new files to the database node.
6. Run AutoConfig on the application tiers
Follow the steps under section " Run AutoConfig on the Application Tiers " in My Oracle Support Knowledge Document 387859.1 to run AutoConfig on all application tier nodes.
7. Synchronize appsutil on the database tier nodes
Follow the steps under section "Copy AutoConfig to the RDBMS ORACLE_HOME" in My Oracle Support Knowledge Document 387859.1 to copy AutoConfig and Rapid Clone files to each database node via the admkappsutil.pl utility.
8. Run AutoConfig on the database tier
Follow the steps under section "Run AutoConfig on the Database Tier" in My Oracle Support Knowledge Document 387859.1 to run AutoConfig on the database tier nodes.
9. Maintain snapshot information
Log in to each application tier node as the APPLMGR user, and run "Maintain Snapshot information" in AD Administration. Refer to Oracle Applications Maintenance Utilities for more information (this is the Release 12.1 version; versions for earlier releases are also available from the Oracle E-Business Suite Online Documentation Library).
Section 2: Cloning Tasks
Use Rapid Clone to create template files for cloning on the source system. After the source system is copied to the target, Rapid Clone updates these templates to contain the new target system configuration settings.
Note: Rapid Clone never changes the source system configuration.
The cloning process consists of three phases, each of which is made up of several logical sections and their steps.
1. Prepare the source system
Execute the following commands to prepare the source system for cloning:
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/appsutil/scripts/
$ perl adpreclone.pl dbTier
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/admin/scripts
$ perl adpreclone.pl appsTier
Note: If new Rapid Clone or AutoConfig updates are applied to the system, adpreclone.pl must be executed again on the dbTier and on the appsTier in order to apply the new files into the clone directory structures that will be used during the cloning configuration stage.
2. Copy the source system to the target system
Copy the application tier file system from the source Applications system to the target node by executing the following steps in the order listed. Ensure the application tier files copied to the target system are owned by the target APPLMGR user, and that the database node files are owned by the target ORACLE user.
Note: In the copying tasks below, UNIX/Linux users should ensure that the symbolic links (soft links) are preserved when copying. On most UNIX platforms, this can be accomplished with the cp -RH command. Consult the UNIX man page for the cp command to check the parameters available on your platform.
For example: cd /target_dest_dir/db cp -RH /source_dir/db/*
Alternatively, the tar command can be used to compress the directories into a temporary staging area. If you use this command, you may require the -h option to follow symbolic links, as following symbolic links is not the default behavior on all platforms. Consult the UNIX man page for the tar command.
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:
*
*
* Applications Technology Stack:
o
o
2. Copy the database node file system
Log on to the source system database node as the ORACLE user, and then:
1. Perform a normal shutdown of the source system database
2. Copy the database (.dbf) files from the source system to the target system
3. Copy the source database ORACLE_HOME to the target system
4. Start the source Applications system database and application tier processes
3. Configure the target system
Run the following commands to configure the target system. You will be prompted for specific target system values such as SID, paths, and ports.
1. Configure the target system database server
Log on to the target system as the ORACLE user and enter the following commands:
$ cd/appsutil/clone/bin
$ perl adcfgclone.pl dbTier
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/clone/bin
$ perl adcfgclone.pl appsTier
Section 3: Finishing Tasks
This section lists tasks that may be necessary, depending on your implementation and the intended use of the cloned system.
1. 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.
2. Update printer settings
If the new cloned system needs to utilize different printers, update the target system with the new printer settings now.
3. 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 3 to check for any instance-specific data in the Workflow configuration on the target system.
Table 3: Workflow configuration settings
Table Name Column Name Column Value Details
WF_NOTIFICATION_ATTRIBUTES TEXT_VALUE Value starts with http://: Update to new web host.
WF_ITEM_ATTRIBUTE_VALUES TEXT_VALUE Value starts with "http://: Update to new web host.
WF_SYSTEMS GUID Using the Workflow Administrator Web Applications responsibility, create a new system defined as the new global database name.
WF_SYSTEMS NAME Replace value with the database global name.
WF_AGENTS ADDRESS Update database link with the new database global name.
FND_FORM_FUNCTIONS WEB_HOST_NAME Update with the new web host name.
FND_FORM_FUNCTIONS WEB_AGENT_NAME Update to point at the new PL/SQL listener name.
FND_CONCURRENT_REQUESTS LOGFILE_NAME Update with the correct path to the logfile directory.
FND_CONCURRENT_REQUESTS OUTFILE_NAME Update with the new directory path on the target system.
4. 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.
5. 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.
Section 4: Advanced Cloning Options
This section describes various advanced cloning procedures that may need to be employed in the appropriate circumstances.
Option 1: Refreshing a Target System
You may need to refresh the target system periodically to synchronize it with changes to the source system.
Note: Back up the target context file on the target system before refreshing the database or application tiers.
To refresh the target system, perform the following steps as described in previous sections:
1. Prepare the source system.
2. Copy the source system to the target system.
1. If the application tier file system if the APPL_TOP, COMMON_TOP, or technology stack needs to be refreshed, copy the portion of the application tier file system that has been updated
2. If the RDBMS ORACLE_HOME or the database needs to be refreshed, copy the database node file system. If refreshing the database, the ORACLE_HOME should be refreshed at the same time.
3. Configure the target system.
Specify the existing target system context file when running adcfgclone.pl commands.
1. Configure the target system database server by logging on to the target system as the ORACLE user and entering the following commands to configure and start the database:
$cd/appsutil/clone/bin
perl adcfgclone.pl dbTier
Where Database target context file is/appsutil/.xml>
2. Configure the target system application tier server nodes by logging on to the target system as the APPLMGR user and entering the following commands:
$ cd/clone/bin
$ perl adcfgclone.pl appsTier
Where APPL_TOP target context file is/appl/admin/.xml>
4. Perform the standard finishing tasks.
Option 2: Cloning a Multi-Node System
This procedure allows the source system or target system to be a multi-node system. As of Release 12, all APPL_TOPs are unified APPL_TOPs. This means that all files required for all application tier services are installed on every application tier node. Thus, only one copy of the applications tier node files needs to be copied to the target system, regardless of whether a shared file system is being used on the source or target system. Multiple application tier nodes are distinguished from each other by the services running.
1. Perform the standard prerequisite tasks.
Carry out these steps on all source and target nodes.
2. Carry out the previously-described cloning tasks.
Prepare, copy and configure the cloned Applications system. When creating more than one application tier node on the target system, follow these steps:
1. Perform a full clone (Prepare, copy and configure steps) of the database node and primary application tier node.
2. To add shared application tier nodes on the target system, follow the instructions in My Oracle Support Knowledge Document 384248.1, Section 4: Adding a node to a Shared Application Tier File System.
3. To add non-shared application tier nodes, execute the copy and configure steps as on the primary node.
4. Specify the services to start on each target Applications tier node when responding to the prompts during the configuration step.
3. Perform the required finishing tasks
Option 3: Adding a New Node to an Existing System
You can use Rapid Clone to clone a node and add it to the existing Applications system, a process also known as scale up or scale out. The new node can run the same services as the source node, or different services. Follow the instructions in the Application tier part of Cloning Tasks.
1. Prepare the source system, copy it to the new node and configure it.
2. After adcfgclone.pl completes, source the Applications environment and run the following commands on the target system:
$ cd/clone/bin
$ perl adaddnode.pl
Note: After adding new nodes, refer to My Oracle Support Knowledge Document 380489.1 for details of how to set up load balancing.
Note: If SQL*Net Access security is enabled in the existing system, you first need to authorize the new node to access the database through SQL*Net. See the Oracle Applications Manager on line help for instructions on how to accomplish this.
Option 4: Cloning an Oracle RAC system
For instructions on how to Clone RAC-Enabled Systems with Rapid Clone, refer to My Oracle Support Knowledge Document 559518.1.
Option 5: Adding a Node to an Existing Oracle RAC Cluster
From Release 12, Rapid Clone is no longer used to migrate a database tier to Oracle RAC. Refer to My Oracle Support Knowledge Document 388577.1 for instructions on how to perform this task.
Option 6: Cloning the Database Separately
Some situations require the database to be recreated separately, without using Rapid Clone. Typical scenarios are when system downtime is not feasible, or advanced database replication tools like RMAN are being used to copy the database in hot backup mode.
This section documents the steps needed to allow manual creation of the target database control files within the Rapid Clone process. This method needs to be used for databases located on raw partitions, or when cloning a hot backup. Follow the complete steps in Cloning Tasks, but replace Step 3a (Configure the target system database server) with the following steps:
1. Log on to the target system as the ORACLE user
2. Configure the
$ cd/appsutil/clone/bin
$ perl adcfgclone.pl dbTechStack
3. Create the target database control files manually
In this step, you copy and recreate the database using your preferred method, such as RMAN restore, Flash Copy, Snap View, or Mirror View.
4. Start the target database in open mode
5. Run the library update script against the database
$ cd/appsutil/install/
$ sqlplus "/ as sysdba" @adupdlib.sql
Where should be set to 'sl' for HP-UX, 'so' for any other UNIX platform, or 'dll' for Windows.
6. Configure the target database
The database must be running and open before performing this step.
$ cd/appsutil/clone/bin
$ perl adcfgclone.pl dbconfig
Where Database target context file is:/appsutil/.xml.
Note: The dbconfig option will configure the database with the required settings for the new target, but it will not recreate the control files.
Change Log
Date Description
Jun 24, 2009
* Restructured document.
Jun 23, 2009
* Moved Appendix A into the Advanced Cloning Options and added some more details.
May 08, 2009
* Replaced Rapid Clone Consolidated Patch with 7164226 (May 2009).
Apr 09, 2009
* Corrected hyperlink in Section 4, Step 3.
Mar 13, 2009
* Added Reference to Patch 8246709 for OracleAS 10.1.3.4 Oracle Home.
Mar 02, 2009
* Added Reference to Note 783188.1.
Feb 16, 2009
* Added Clarification for MS Windows (32-bit) on Patch 8221919.
Feb 13, 2009
* Added Patch 8221919 on Section 1, Step 5.
Jan 22, 2009
* Added Patch 7699109 on Section 1, Step 5.
* Added Clarification for RUP2 or higher.
Aug 07, 2008
* Replaced Rapid Clone Consolidated Patch with 6776948 (Jul 2008).
* Removed Patch 6854328 since its included on 6776948 (Jul 2008).
Jul 29, 2008
* Removed Rapid Clone restriction for RAC-enabled Systems in Section 4, Steps 4 and 5.
* Added reference to Document 559518.1 for RAC cloning instructions.
* Added tracking bug number 7276544 to add a node on an existing RAC system without cloning.
* Added tracking bug number 7275583 to add a node while cloning a RAC system.
Mar 24, 2008
* Added Unzip 5.52 to Section 1, Step 2.
* Included Patch 6854328 for Windows 64-bit in Section 5, Step 5.
* Fixed post patch steps on note box.
Feb 28, 2008
* Adjusted heading format in Section 2, Step 2.
Jan 25, 2008
* Added AD.A.DELTA.4 and latest Rapid Clone consolidated patch.
Dec 18, 2007
* Minor layout changes.
* Added requirement to apply the latest AD Patch.
* Added clarification to backup the context file when refreshing a target system on 4.1.
* Included step to verify OS requirements.
Dec 17, 2007
* Modified cp command usage.
Dec 07, 2007
* Included Windows Itanium patch.
Jul 30, 2007
* Removed Windows desupport notice.
* Added Warning to re-run post-clone steps after patching the system.
Jun 25, 2007
* Included clarification on how to use cp command to preserve symbolic links.
May 18, 2007
* Removed reference to HP OpenVMS Alpha since this is not a certified or supported platform for any tier with Release 12.
May 10, 2007
* Corrected link to Oracle Applications Maintenance Utilities on Section 1, Step 7.
Feb 23, 2007
* Added reference to Note 380489.1 for Load Balancing.
Feb 22, 2007
* Added note that using Rapid Clone on Windows is not currently supported.
Jan 24, 2007
* Created initial document.
My Oracle Support Knowledge Document 406982.1 by Oracle E-Business Suite Development
Copyright © 2007, 2009 Oracle and/or its affiliates. All rights reserved.
.
Cloning is the process used to create a copy of an existing Oracle Applications system. There are various scenarios for cloning an Oracle Applications system, including:
* Standard cloning - Making a copy of an existing Oracle Applications system, for example a copy of a production system to test updates.
* System scale-up - Adding new machines to an Oracle Applications system to provide the capacity for processing an increased workload.
* System transformations - Altering system data or file systems, including actions such as platform migration, data scrambling, and provisioning of high availability architectures.
* Patching and upgrading - Delivering new versions of Applications components, and providing a mechanism for creating rolling environments to minimize downtime.
An important principle in Oracle Applications cloning is that the system is cloned, rather than the topology. Producing an exact copy of the patch level and data is much more important than creating an exact copy of the topology, as a cloned system must be able to provide the same output to the end user as the source system. However, while a cloned system need not have the full topology of its source, it must have available to it all the topology components that are available to the source.
Conventions used in this document include the following:
Term or Usage Meaning or Action
Source system Oracle Applications system being cloned.
Target system Oracle Applications system being created as a copy of the source.
APPLMGR User that owns the application tier file system (APPL_TOP and application tier technology stack).
ORACLE User that owns the database tier file system (RDBMS ORACLE_HOME and database files).
CONTEXT_NAME The CONTEXT_NAME variable refers to the name of the Applications context file. By default, CONTEXT_NAME is
Monospace Text Represents command line text. Type this command exactly as shown.
< > Text enclosed in angle brackets represents a variable. Substitute a value for the variable text. Do not type the angle brackets.
Section 1: Prerequisite Tasks
Before cloning, prepare the source system by applying any required patches and running AutoConfig.
1. Verify OS requirements on target system
Before cloning to a new server, ensure the target system meets all the requirements for Oracle Applications Release 12 stated on the Oracle Applications Release Notes, and on the Oracle Applications Installation and Upgrade Notes for each Platform. For the latest installation guidelines refer to My Oracle Support Knowledge Document 405565.1.
Note: On Microsoft Windows, Rapid Clone is not currently certified for use from Domain User Accounts.
2. Verify source and target system software components and versions
In addition to the Oracle Applications software requirements (see Oracle Applications Installation Guide: Using Rapid Install), the following software component versions must exist on the source or target nodes as applicable. The 'Location' column indicates the node where the software component must reside.
Table 1: Software Requirements
Software Component Minimum Version Required Location Comments
Zip 2.3 All source system nodes Download from InfoZip. Zip must be in your $PATH.
Unzip 5.52 All source system nodes Download from InfoZip. Unzip must be in your $PATH.
Operating system utilities N/A All target system nodes The required operating system utilities for your platform must be in your $PATH when running adcfgclone.pl. For example, make, ld, and ar on UNIX. Refer to Oracle Applications Installation Guide: Using Rapid Install (see Footnote 1)
Perl 5.x All target system nodes Use the Perl shipped with OracleAS 10.1.3 and Database 10g, or download it from Perl.com. Perl must be in your $PATH, and $PERL5LIB must be set correctly before cloning.
Footnote 1 This is the Release 12.1.1 version; versions for earlier releases are also available from the Oracle E-Business Suite Online Documentation Library
3. Apply the latest AD patch
Apply patch 6510214 (R12.AD.A.DELTA.4) or higher. Refer to My Oracle Support to obtain the latest AD patch.
4. Apply the latest AutoConfig template patch
Update the Oracle Applications file system with the latest AutoConfig template files by applying the TXK AutoConfig Template rollup patch to all application tier server nodes. Refer to My Oracle Support Knowledge Document 387859.1 for details of the latest AutoConfig Template rollup patch.
5. Apply the latest Rapid Clone patches
Update the Oracle Applications file system with the latest Rapid Clone files by applying the following patches to all Applications nodes.
* For Release 12.0:
Apply patches as listed in Table 2.
Table 2: Release 12.0 Rapid Clone patches
Patch Description
5484000 Oracle E-Business Suite 12.0.2 Release Update Pack (RUP2) or higher
7164226 12.0 RAPIDCLONE CONSOLIDATED FIXES MAY/2009
7699109 Required for Microsoft Windows Server 2003 R2 (64-bit AMD64 and Intel EM64T)
8221919 Required for HP Itanium (HP-IA) and Microsoft Windows (32-bit).
8246709 Required for Microsoft Windows if using OracleAS 10.1.3.4. This patch must be re-applied to the OracleAS 10.1.3.4 ORACLE_HOME before every cloning operation.
* For Release 12.1:
No patches are required at present.
Note: If new Rapid Clone or AutoConfig updates are applied to the system, steps 6, 7, and 8 below must be executed again in order to apply the new files to the database node.
6. Run AutoConfig on the application tiers
Follow the steps under section " Run AutoConfig on the Application Tiers " in My Oracle Support Knowledge Document 387859.1 to run AutoConfig on all application tier nodes.
7. Synchronize appsutil on the database tier nodes
Follow the steps under section "Copy AutoConfig to the RDBMS ORACLE_HOME" in My Oracle Support Knowledge Document 387859.1 to copy AutoConfig and Rapid Clone files to each database node via the admkappsutil.pl utility.
8. Run AutoConfig on the database tier
Follow the steps under section "Run AutoConfig on the Database Tier" in My Oracle Support Knowledge Document 387859.1 to run AutoConfig on the database tier nodes.
9. Maintain snapshot information
Log in to each application tier node as the APPLMGR user, and run "Maintain Snapshot information" in AD Administration. Refer to Oracle Applications Maintenance Utilities for more information (this is the Release 12.1 version; versions for earlier releases are also available from the Oracle E-Business Suite Online Documentation Library).
Section 2: Cloning Tasks
Use Rapid Clone to create template files for cloning on the source system. After the source system is copied to the target, Rapid Clone updates these templates to contain the new target system configuration settings.
Note: Rapid Clone never changes the source system configuration.
The cloning process consists of three phases, each of which is made up of several logical sections and their steps.
1. Prepare the source system
Execute the following commands to prepare the source system for cloning:
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
$ perl adpreclone.pl dbTier
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
$ perl adpreclone.pl appsTier
Note: If new Rapid Clone or AutoConfig updates are applied to the system, adpreclone.pl must be executed again on the dbTier and on the appsTier in order to apply the new files into the clone directory structures that will be used during the cloning configuration stage.
2. Copy the source system to the target system
Copy the application tier file system from the source Applications system to the target node by executing the following steps in the order listed. Ensure the application tier files copied to the target system are owned by the target APPLMGR user, and that the database node files are owned by the target ORACLE user.
Note: In the copying tasks below, UNIX/Linux users should ensure that the symbolic links (soft links) are preserved when copying. On most UNIX platforms, this can be accomplished with the cp -RH command. Consult the UNIX man page for the cp command to check the parameters available on your platform.
For example: cd /target_dest_dir/db cp -RH /source_dir/db/*
Alternatively, the tar command can be used to compress the directories into a temporary staging area. If you use this command, you may require the -h option to follow symbolic links, as following symbolic links is not the default behavior on all platforms. Consult the UNIX man page for the tar command.
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:
*
*
* Applications Technology Stack:
o
o
2. Copy the database node file system
Log on to the source system database node as the ORACLE user, and then:
1. Perform a normal shutdown of the source system database
2. Copy the database (.dbf) files from the source system to the target system
3. Copy the source database ORACLE_HOME to the target system
4. Start the source Applications system database and application tier processes
3. Configure the target system
Run the following commands to configure the target system. You will be prompted for specific target system values such as SID, paths, and ports.
1. Configure the target system database server
Log on to the target system as the ORACLE user and enter the following commands:
$ cd
$ perl adcfgclone.pl dbTier
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
$ perl adcfgclone.pl appsTier
Section 3: Finishing Tasks
This section lists tasks that may be necessary, depending on your implementation and the intended use of the cloned system.
1. 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.
2. Update printer settings
If the new cloned system needs to utilize different printers, update the target system with the new printer settings now.
3. 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 3 to check for any instance-specific data in the Workflow configuration on the target system.
Table 3: Workflow configuration settings
Table Name Column Name Column Value Details
WF_NOTIFICATION_ATTRIBUTES TEXT_VALUE Value starts with http://
WF_ITEM_ATTRIBUTE_VALUES TEXT_VALUE Value starts with "http://
WF_SYSTEMS GUID Using the Workflow Administrator Web Applications responsibility, create a new system defined as the new global database name.
WF_SYSTEMS NAME Replace value with the database global name.
WF_AGENTS ADDRESS Update database link with the new database global name.
FND_FORM_FUNCTIONS WEB_HOST_NAME Update with the new web host name.
FND_FORM_FUNCTIONS WEB_AGENT_NAME Update to point at the new PL/SQL listener name.
FND_CONCURRENT_REQUESTS LOGFILE_NAME Update with the correct path to the logfile directory.
FND_CONCURRENT_REQUESTS OUTFILE_NAME Update with the new directory path on the target system.
4. 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.
5. 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.
Section 4: Advanced Cloning Options
This section describes various advanced cloning procedures that may need to be employed in the appropriate circumstances.
Option 1: Refreshing a Target System
You may need to refresh the target system periodically to synchronize it with changes to the source system.
Note: Back up the target context file on the target system before refreshing the database or application tiers.
To refresh the target system, perform the following steps as described in previous sections:
1. Prepare the source system.
2. Copy the source system to the target system.
1. If the application tier file system if the APPL_TOP, COMMON_TOP, or technology stack needs to be refreshed, copy the portion of the application tier file system that has been updated
2. If the RDBMS ORACLE_HOME or the database needs to be refreshed, copy the database node file system. If refreshing the database, the ORACLE_HOME should be refreshed at the same time.
3. Configure the target system.
Specify the existing target system context file when running adcfgclone.pl commands.
1. Configure the target system database server by logging on to the target system as the ORACLE user and entering the following commands to configure and start the database:
$cd
perl adcfgclone.pl dbTier
Where Database target context file is
2. Configure the target system application tier server nodes by logging on to the target system as the APPLMGR user and entering the following commands:
$ cd
$ perl adcfgclone.pl appsTier
Where APPL_TOP target context file is
4. Perform the standard finishing tasks.
Option 2: Cloning a Multi-Node System
This procedure allows the source system or target system to be a multi-node system. As of Release 12, all APPL_TOPs are unified APPL_TOPs. This means that all files required for all application tier services are installed on every application tier node. Thus, only one copy of the applications tier node files needs to be copied to the target system, regardless of whether a shared file system is being used on the source or target system. Multiple application tier nodes are distinguished from each other by the services running.
1. Perform the standard prerequisite tasks.
Carry out these steps on all source and target nodes.
2. Carry out the previously-described cloning tasks.
Prepare, copy and configure the cloned Applications system. When creating more than one application tier node on the target system, follow these steps:
1. Perform a full clone (Prepare, copy and configure steps) of the database node and primary application tier node.
2. To add shared application tier nodes on the target system, follow the instructions in My Oracle Support Knowledge Document 384248.1, Section 4: Adding a node to a Shared Application Tier File System.
3. To add non-shared application tier nodes, execute the copy and configure steps as on the primary node.
4. Specify the services to start on each target Applications tier node when responding to the prompts during the configuration step.
3. Perform the required finishing tasks
Option 3: Adding a New Node to an Existing System
You can use Rapid Clone to clone a node and add it to the existing Applications system, a process also known as scale up or scale out. The new node can run the same services as the source node, or different services. Follow the instructions in the Application tier part of Cloning Tasks.
1. Prepare the source system, copy it to the new node and configure it.
2. After adcfgclone.pl completes, source the Applications environment and run the following commands on the target system:
$ cd
$ perl adaddnode.pl
Note: After adding new nodes, refer to My Oracle Support Knowledge Document 380489.1 for details of how to set up load balancing.
Note: If SQL*Net Access security is enabled in the existing system, you first need to authorize the new node to access the database through SQL*Net. See the Oracle Applications Manager on line help for instructions on how to accomplish this.
Option 4: Cloning an Oracle RAC system
For instructions on how to Clone RAC-Enabled Systems with Rapid Clone, refer to My Oracle Support Knowledge Document 559518.1.
Option 5: Adding a Node to an Existing Oracle RAC Cluster
From Release 12, Rapid Clone is no longer used to migrate a database tier to Oracle RAC. Refer to My Oracle Support Knowledge Document 388577.1 for instructions on how to perform this task.
Option 6: Cloning the Database Separately
Some situations require the database to be recreated separately, without using Rapid Clone. Typical scenarios are when system downtime is not feasible, or advanced database replication tools like RMAN are being used to copy the database in hot backup mode.
This section documents the steps needed to allow manual creation of the target database control files within the Rapid Clone process. This method needs to be used for databases located on raw partitions, or when cloning a hot backup. Follow the complete steps in Cloning Tasks, but replace Step 3a (Configure the target system database server) with the following steps:
1. Log on to the target system as the ORACLE user
2. Configure the
$ cd
$ perl adcfgclone.pl dbTechStack
3. Create the target database control files manually
In this step, you copy and recreate the database using your preferred method, such as RMAN restore, Flash Copy, Snap View, or Mirror View.
4. Start the target database in open mode
5. Run the library update script against the database
$ cd
$ sqlplus "/ as sysdba" @adupdlib.sql
Where
6. Configure the target database
The database must be running and open before performing this step.
$ cd
$ perl adcfgclone.pl dbconfig
Where Database target context file is:
Note: The dbconfig option will configure the database with the required settings for the new target, but it will not recreate the control files.
Change Log
Date Description
Jun 24, 2009
* Restructured document.
Jun 23, 2009
* Moved Appendix A into the Advanced Cloning Options and added some more details.
May 08, 2009
* Replaced Rapid Clone Consolidated Patch with 7164226 (May 2009).
Apr 09, 2009
* Corrected hyperlink in Section 4, Step 3.
Mar 13, 2009
* Added Reference to Patch 8246709 for OracleAS 10.1.3.4 Oracle Home.
Mar 02, 2009
* Added Reference to Note 783188.1.
Feb 16, 2009
* Added Clarification for MS Windows (32-bit) on Patch 8221919.
Feb 13, 2009
* Added Patch 8221919 on Section 1, Step 5.
Jan 22, 2009
* Added Patch 7699109 on Section 1, Step 5.
* Added Clarification for RUP2 or higher.
Aug 07, 2008
* Replaced Rapid Clone Consolidated Patch with 6776948 (Jul 2008).
* Removed Patch 6854328 since its included on 6776948 (Jul 2008).
Jul 29, 2008
* Removed Rapid Clone restriction for RAC-enabled Systems in Section 4, Steps 4 and 5.
* Added reference to Document 559518.1 for RAC cloning instructions.
* Added tracking bug number 7276544 to add a node on an existing RAC system without cloning.
* Added tracking bug number 7275583 to add a node while cloning a RAC system.
Mar 24, 2008
* Added Unzip 5.52 to Section 1, Step 2.
* Included Patch 6854328 for Windows 64-bit in Section 5, Step 5.
* Fixed post patch steps on note box.
Feb 28, 2008
* Adjusted heading format in Section 2, Step 2.
Jan 25, 2008
* Added AD.A.DELTA.4 and latest Rapid Clone consolidated patch.
Dec 18, 2007
* Minor layout changes.
* Added requirement to apply the latest AD Patch.
* Added clarification to backup the context file when refreshing a target system on 4.1.
* Included step to verify OS requirements.
Dec 17, 2007
* Modified cp command usage.
Dec 07, 2007
* Included Windows Itanium patch.
Jul 30, 2007
* Removed Windows desupport notice.
* Added Warning to re-run post-clone steps after patching the system.
Jun 25, 2007
* Included clarification on how to use cp command to preserve symbolic links.
May 18, 2007
* Removed reference to HP OpenVMS Alpha since this is not a certified or supported platform for any tier with Release 12.
May 10, 2007
* Corrected link to Oracle Applications Maintenance Utilities on Section 1, Step 7.
Feb 23, 2007
* Added reference to Note 380489.1 for Load Balancing.
Feb 22, 2007
* Added note that using Rapid Clone on Windows is not currently supported.
Jan 24, 2007
* Created initial document.
My Oracle Support Knowledge Document 406982.1 by Oracle E-Business Suite Development
Copyright © 2007, 2009 Oracle and/or its affiliates. All rights reserved.
.
Recovery - How It Works and Some Examples
RECOVERY
========
This document will discuss the various scenarios relating to recovering an
Oracle Database from a mixture of datafiles and/or archived redo log-files.
Most of this information is available in the current DBA guide and the online
RECOVERY.DOC file. The location of the latter is OS dependant.
A degree of understanding of the Oracle Version 6 architecture is assumed.
Before we begin lets take a look at how Oracle manages and tracks the various
elements involved in the recovery process :
The CONTROL FILE
----------------
The Control file is in effect the central repository regarding the physical
layout of the database. More importantly,for our discussion, it also records
the SEQUENCE information related to the REDO LOG Files and their
relationship to the one or more DATABASE Files.
Whenever a LOG Switch occurs (i.e. the current on-line REDO LOG is full) the
control file is updated with the new SEQUENCE number - at the same time ALL
ON-LINE Database file headers are updated with the same SEQUENCE number.
There is one important exception - Database File Headers of any TABLESPACE in
BACKUP mode are not updated until the END BACKUP command is issued AND
a LOG Switch occurs.
For each Database File - the Control File also records - the last LOG SEQUENCE
Number applied to this Datafile.
The SEQUENCE Number of each REDO LOG File is held as part of the
REDO LOG HEADER. (see appendix A)
N.B. We are using the term LOG Switch above to indicate the occurence of a
CHECKPOINT. It is of course possible to have a CHECKPOINT occur
multiple times within a Log file depending on the INIT.ORA parameter
LOG_CHECKPOINT_INTERVAL =
however remains and most systems are set to CHECKPOINT when a
LOG Switch occurs.
Given the above information lets now take a look at a Database which we are
about to STARTUP - do some work - and then SHUTDOWN.
Assuming the following :
There are 2 on-line log files - SEQUENCE Numbers 10 and 11
(we establised this via the command ARCHIVE LOG LIST)
The Current On-Line LOG is sequence 11
The DATABASE was Shutdown cleanly
All the Database Files are on-line
At this point (before we startup) the Control File would record the value 11
as the being Current LOG SEQUENCE Number as well as the Last Log Sequence
Number applied to each Database File.
All the Database File Headers would have the same value for the LOG SEQUENCE
Number.
On Startup Oracle will compare the value of the LOG SEQUENCE Number in each
on-line Database File Header against those held in the Control File - if both
these values are the same no recovery is necessary.
The Control File is then updated and the LOG SEQUNCE Number held against
each Database File is set to INFINITY and the Database opened.
We now do some amount of work which results in,say 5, LOG Switches occuring
thus bringing the current on-line LOG SEQUENCE Number to 16. At each LOG
Switch the Control File and all on-line Database File Headers would be
updated to reflect this increment in the SEQUENCE Number.
CLEAN SHUTDOWN
--------------
The Database is now Shutdown cleanly - at this point the LOG SEQUENCE
Numbers against each on-line Database File,in the Control File, are updated
to 16 and the Database is Closed and Dismounted.
N.B. Both SHUTDOWN NORMAL | IMMEDIATE are considered CLEAN.
ABNORMAL SHUTDOWN
-----------------
If instead the Instance terminates abnormally - the LOG SEQUENCE Numbers held
against each Database File in the Control File would be left at INFINITY. When
we attempt to Startup - the SEQUENCE number check would fail and Oracle would
automatically Recover all on-line Database Files starting from the LOG SEQUENCE
Number held in the Datafile Headers upto the Current on-line LOG SEQUENCE
Number stored in the Control File - in our example - 16.
The mechanisms described above can now be applied to any form of Recovery we
wish to analyse.
TERMINOLOGY
-----------
Before taking a look at some Recovery scenarios - lets briefly look at some of
the terminology we will be using.
COLD BACKUP
-----------
A Cold Backup is assumed to be a copy of ALL Database,On-Line Redo-Log and
Control Files taken when the Database is Shutdown.
HOT BACKUP
----------
A Hot Backup is assumed to be a copy of one or more Datafiles belonging to
one or more Tablespaces which have been placed in Backup mode i.e the command
ALTER TABLESPACE
has been issued.
ARCHIVE LOGGING
---------------
Archive Logging is a mechanism whereby On-line Redo Logs are copied to an
Off-Line location (disk or tape) when they are filled. These Off-Line Logs
are exact replicas of the On-Line Logs. Oracle will not perform a Log Switch
operation if the Redo Log it would switch to has not been archived.
1. LOSS OF CURRENT ON-LINE REDO LOG FILE
----------------------------------------
Loss of the Curent on-line Redo Log File is a single-point of failure in
Oracle Version 6. This can occur due to media failure or user error. In either
case the Database cannot be started without some remedial action being taken.
The simplest course of action is to restore ALL files from the last Cold
Backup and start the Database. If this option is chosen the rest of this
discussion may be ignored.
Other options are discussed below :
The first step is to restore a Redo Log File with the same name and size as
the one that is missing. This can be done by either :
a) Copy of an Archived Redo-Log
b) Copy of another on-line Redo Log.
It is important in either case that the file size is identical and is part of
the same Database (the Database name is stored in the Redo Log Header).
If you cannot do either a) or b) the only other option is to add a new Log File
and take copies of it as required. This can be achieved by :
STARTUP MOUNT
CONNECT INTERNAL
ALTER DATABASE ADD LOGFILE '
OS copies of the new file can then be taken.
There are now 2 courses of action open to us :
a) Only available if running in ARCHIVELOG Mode.
Restore ONLY the Database Files from your last Cold/Hot Backup and Roll Forward
through till the last Archived Redo Log. This approach will guarantee the
consistency of the Database at the end of the recovery operation.
STARTUP MOUNT -> We are using the current Control File at this time
CONNECT INTERNAL
RECOVER DATABASE MANUAL
We will now be prompted for the Log File Sequence as determined by the
information the the Datafile Headers.
As each Log File is applied the Sequence Number in the Datafile Headers is
updated to reflect the fact.
Apply all Archived Redo Logs until you are prompted for one that does not exist:
e.g Enter name for archive log sequence number 72 ("CANCEL" to cancel):
N.B. It is possible that the Redo Log you are being prompted for has not yet
been archived - if you are unsure you can now enter the name of each
of the On-line Redo Log files. Oracle will reject them if they do not
have the correct SEQUENCE Number.
Enter CANCEL at this point
ALTER DATABASE OPEN RESETLOGS
This command first initializes all the On-line Redo Log Files and then resets
the SEQUENCE Number of the Current On-line Log to be that of that last
Archive Log File applied to the Database. The Database is then opened.
b) Using all the current files - 'Fake' Manual Recovery.
STARTUP MOUNT
CONNECT INTERNAL
RECOVER DATABASE MANUAL
When prompted for a Log File Sequence - enter the name of non-existant file
(JUNK is normally a good bet) - you will get a couple of informational
messages telling you that the file does not exist and asking you to re-enter.
Enter CANCEL at this point.
ALTER DATABASE OPEN RESETLOGS.
This will perform as above.
If the Instance had terminated abnormally the above steps will NOT guarantee
the consistency of the Database and the safest thing to do would be an
Export -> Re-create the Database -> Import.
The reason for the uncertainty is that the RESETLOGS option,as mentioned above,
initializes the On-line log files. In our case we did not have one but that is
immmaterial as there was potentially information in the Log which should have
been applied to the Database.
If however the Database was Shutdown cleanly there should be no problem.
A Cold Backup of the Database should be taken at this point.
2. LOSS OF ONE OR MORE DATA FILES
---------------------------------
Recovering from the loss of one or more Datafile(s) depends very much on the
File(s) in question.
The worst-case scenario is the loss of a file(s) from the SYSTEM Tablespace.
a) If the Database is not in ARCHIVELOG Mode you have NO choice except to return
to your last Cold Backup. In this instance you would restore ALL the files.
b) If you are running Archiving :
- Restore the lost/damaged File(s) ONLY from the last Cold/Hot Backup
- STARTUP MOUNT -> using current Control File
- CONNECT INTERNAL
- RECOVER DATABASE
You will be prompted for all necessary Archived Redo Log Files
- ALTER DATABASE OPEN
If the file(s) lost/damaged are from a non-SYSTEM Tablespace:
a) If the Database is not in ARCHIVELOG Mode you have 2 choices :
i) Restore ALL files from your last Cold Backup.
ii) STARTUP MOUNT -> using current Control File
CONNECT INTERNAL
ALTER DATABASE DATAFILE '
(The above statement may be issued for as many files as necessary
ALTER DATABASE OPEN
The Database is now running minus one or more files. It is strongly
recommended that at this stage you decide to either do a full EXPORT and
rebuild the database or take the Tablespace(s) containing the missing
Datafile(s) offline and drop them. This is to avoid Oracle attempting to
allocate space in the offline Datafile(s).
b) If the Database is in ARCHIVELOG Mode you have 2 choices :
i) Restore ONLY the missing/damaged File(s) from the last Cold/Hot Backup.
STARTUP MOUNT -> using current Control File
CONNECT INTERNAL
RECOVER DATABASE
You will be prompted for all the necessary Archive Log Files
ALTER DATABASE OPEN
ii) Restore ONLY the missing/damaged File(s) from the last Cold/Hot Backup
STARTUP MOUNT -> using current Control File
CONNECT INTERNAL
ALTER DATABASE DATAFILE '
Issue this for as many Datafiles as necessary
ALTER DATABASE OPEN
ALTER TABLESPACE
Issue this for all Tablespaces which have missing/damaged Files
The Database can now be used except for the parts OFFLINE
You can now issue one of 2 commands :
- RECOVER TABLESPACE
- RECOVER DATAFILE '
In each case you will be prompted for the necessary Archive Log Files
You can run multiple recovery sessions in Parallel using either of the
above commands.
N.B. This implies that the remainder of the Database can be used while
Datafile/Tablespace Recovery is in progress.
When all the Archive Logs have been applied you can issue
ALTER TABLESPACE
This will bring the Tablespaces and associated Datafiles ONLINE.
3. TABLESPACE(S) LEFT IN BACKUP MODE
------------------------------------
This is only applicable if the Database is in ARCHIVELOG Mode. Having put
one or more Tablespaces in Backup mode via the command :
ALTER TABLESPACE
The files are now backed up at the OS level but the Tablespaces are NOT taken
out of Backup Mode via :
ALTER TABLESPACE
The Instance is now Shutdown or terminates abnormally.
As mentioned earlier this results in the LOG SEQUENCE Number in the associated
Datafile(s) header remaining 'frozen' at the time the BEGIN BACKUP was issued.
The Control File has meanwhile been updated as Log Switches have occured.
Regardless of how the Instance terminated - any attempt to Open the Database
will fail as Oracle will assume that media recovery is necessary starting with
the earliest Log Sequence Number in the 'frozen' Datafile Headers.
There are 2 alternatives :
a) The safest option is to perform the Recovery as demanded by Oracle. There
is no need to restore any files apart from Archive Log Files which are not
on-line.
- STARTUP MOUNT -> using current Control File
- CONNECT INTERNAL
- RECOVER DATABASE
You will be prompted for all required Archive Redo Log files
- ALTER DATABASE OPEN
- ALTER TABLESPACE
This should be issued for all Tablespaces left in Backup Mode. If unsure
the command can be issued for all Tablespaces with no ill effects.
- ALTER SYSTEM SWITCH LOGFILE
b) This option will NOT guarantee the consistency of the Database and should
be used with the greatest discretion ONLY under the guidance of support staff.
If the necessary Archive Redo Logs are not available this is the only option
possible unless a Cold Backup can be used.
Do not restore any files from a backup.
Set the INIT.ORA parameter - _ALLOW_RESETLOGS_CORRUPTION = TRUE
Follow the 'fake' Manual Recovery Procedures documented in 1(b).
Issue the END BACKUP commands for the necessary Tablespaces (see above)
- ALTER SYSTEM SWITCH LOGFILE
A Cold Backup of the Database should now be taken.
ADDITIONAL INFORMATION
----------------------
The contents of the Datafile/Redo File Headers and Control File are an
invaluable source of information when problems occur.
Getting this information is relatively easy. The following commands should
all be issued from SQLDBA while connected INTERNAL.
The output will be sent to the default Trace directory.
ALTER SESSION SET EVENTS 'IMMEDIATE TRACE NAME CONTROLF LEVEL 10'
- dumps the contents of the Control File
ALTER SESSION SET EVENTS 'IMMEDIATE TRACE NAME FILE_HDRS LEVEL 10'
- dumps the Headers of all Database Files
ALTER SESSION SET EVENTS 'IMMEDIATE TRACE NAME REDOHDR LEVEL 10'
- dumps the Headers of all on-line Redo Log Files
See appendix A for annotated samples of the output of the above commands.
Annotations are preceded by ***.
In all the previous Recovery examples you will note that unless restoring
from a Cold Backup it is never necessary to restore the Control File. This is
almost always the case as it is very unusual to be into a Recovery situation
and find that the physical structure of the Database has changed in any way.
If the physical structure of the Database is being changed it is recommended
that a Backup of the Control File be taken prior to the change being made to
allow for Recovery to that point in time. See Chapter 15 of the DBA Guide.
The situation where all the current Control Files have been lost/damaged
should never arise but if it should there is an undocumented command to
allow for the re-creation of the Control File. This should be used with
care as there have been problems in the past AND it is necessary to know
the location of all the Database and On-line Redo Log Files.
The Database should ALWAYS be shutdown when taking copies of control files.
Oracle versions > 6.0.33.1 where the Database has been opened at least once
will work fine.
Oracle version 6.0.33.0 will mark all Datafiles as being part of the
SYSTEM Tablespace.
It is not recommended that this option is used with any Version < 6.0.33.1
See Appendix B for information on the CREATE CONTROFILE command.
Appendix A
----------
Control File Dump (Database Open)
---------------------------------
DUMP OF CONTROL FILES, Seq # 586 = 24a
- FILE HEADER:
- Software vsn = 100798722 = 0x6021102
- Compatibility Vsn = 100786944 = 0x601e300
- DatabaseID = 1655535898 = 0x62ad791a
- Db Name = "S6A"
- File Seq = 1 = 0x1
- Control Seq = 586 = 0x24a
- File size = 114 = 0x72
- File Number = 0
- Blksiz = 512
- File Type = CONTROL (1)
- DBINFO: (offset = 0xec, size = 220, max = 1, hi = 1)
- DB Version = 100798722 = 0x6021102
- Compat Version = 101822976 = 0x611b200
- Date = 1992 5 8 14 29 46 0 0
- Media rcvry = No
- Cross check = No
- DB Name = "S6A" *** Note the Database Name
- DB Description = "something-constructive-should-come-here"
- SCNHI = ffff.ffffffff
- Man rcvy seq # = 0
- Invalid seq # = 0
- Current log # = 1 *** The File Number of the current Log
- Client generic bytes: *** will vary between 1 and number of Log Files
- 04 00 01 16 00 00 00 00 00 00 00 00 00 00 00 00
- 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
- 00 00 00 00 00 00 00 00
- Cache-layer client info field:
- 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
- REDO THREAD ENTRIES: (offset = 0x200, size = 40, max = 1, hi = 1)
- 1
- INSTANCE = s6a
- STATUS = 1
- CKPT = 0000004b.00000003.ffff *** 4b is the current Sequence Number
- LOG FILE ENTRIES: (offset = 0x228, size = 272, max = 50, hi = 2)
- 1
- Name = /usr/oracle/v6033/dbs/log1s6a.dbf
- Size
- Bytes = 2097152
- Blocks = 4096
- Block Size = 512
- Spooled = No
- Sequence # = 75 *** Log Sequence Number (4B)
- 2
- Name = /usr/oracle/v6033/dbs/log2s6a.dbf
- Size
- Bytes = 2097152
- Blocks = 4096
- Block Size = 512
- Spooled = No
- Sequence # = 74
- DB FILE ENTRIES: (offset = 0x3748, size = 288, max = 50, hi = 5)
- 1
- Name = /usr/oracle/v6033/dbs/dbss6a.dbf
- Creation RBA
- Seq # = 0
- Block # = 0
- Offset = 0
- Size
- Bytes = 20971520
- Blocks = 10240
- Block size = 2048
- Inc # = 1
- Status (5)
- Online = Yes -> NOTE
- Offline Automatically = No
- System Table Space = Yes -> NOTE
- 2
- Name = /usr/oracle/v6033/dbs/ts1dbs.dbf
- Creation RBA
- Seq # = 0
- Block # = 0
- Offset = 0
- Size
- Bytes = 2097152
- Blocks = 1024
- Block size = 2048
- Inc # = 1
- Status (1)
- Online = Yes
- Offline Automatically = No
- System Table Space = No
- 3
- Name = /usr/oracle/v6033/dbs/ts1dbs2.dbf
- Creation RBA
- Seq # = 0
- Block # = 0
- Offset = 0
- Size
- Bytes = 2097152
- Blocks = 1024
- Block size = 2048
- Inc # = 1
- Status (1)
- Online = Yes
- Offline Automatically = No
- System Table Space = No
- 4 (empty)
- 5 (empty)
- DB FILE STOP RBA ENTRIES: (offset = 0x6f88, size = 12, max = 50, hi = 50)
- FILE NUMBER THREAD_NUMBER STOP_RBA
1
1 (ffffffff.ffffffff.ffff)
2
1 (ffffffff.ffffffff.ffff)
3
1 (ffffffff.ffffffff.ffff)
***
Note the first set of HEX digits - if the database was shutdown when we did
this dump it would have been set to - 0000004B.
***
File Header Dump
----------------
Dump of file # 1
- FILE HEADER:
- Software vsn = 100798722 = 0x6021102
- Compatibility Vsn = 101822976 = 0x611b200
- DatabaseID = 1655535898 = 0x62ad791a
- Db Name = "S6A"
- File Seq = 1 = 0x1
- Control Seq = 584 = 0x248
- File size = 10240 = 0x2800
- File Number = 1
- Blksiz = 2048
- File Type = DATA (3)
Status: x0
Start Redo Points Per-Thread:
(4b.3.ffff) *** 4B(75) is Curent On-Line Log Sequence Number
Dump of file # 2
- FILE HEADER:
- Software vsn = 100798722 = 0x6021102
- Compatibility Vsn = 101822976 = 0x611b200
- DatabaseID = 1655535898 = 0x62ad791a
- Db Name = "S6A"
- File Seq = 1 = 0x1
- Control Seq = 584 = 0x248
- File size = 1024 = 0x400
- File Number = 2
- Blksiz = 2048
- File Type = DATA (3)
Status: x0
Start Redo Points Per-Thread:
(4b.3.ffff)
Dump of file # 3
- FILE HEADER:
- Software vsn = 100798722 = 0x6021102
- Compatibility Vsn = 101822976 = 0x611b200
- DatabaseID = 1655535898 = 0x62ad791a
- Db Name = "S6A"
- File Seq = 1 = 0x1
- Control Seq = 584 = 0x248
- File size = 1024 = 0x400
- File Number = 3
- Blksiz = 2048
- File Type = DATA (3)
Status: x0
Start Redo Points Per-Thread:
(4b.3.ffff)
On-Line Redo Log File Headers Dump
----------------------------------
2 logs in database
Log #1 < deleted > size=4096 seq=0x4b blksz=512 spl=0 - FILE HEADER:
- Software vsn = 100798723 = 0x6021103
- Compatibility Vsn = 101823232 = 0x611b300
- DatabaseID = 1655535898 = 0x62ad791a
- Db Name = "S6A"
- File Seq = 75 = 0x4b *** Log File Sequence Number
- Control Seq = 583 = 0x247
- File size = 4096 = 0x1000
- File Number = 1
- Blksiz = 512
- File Type = LOG (2)
Stored Sequence number = ##00000000000000004B
Next Available Block: 1001
Redo Thread Allocation Table Entries:
THRD FCB NAB ECC
------------------------------------- 1 0x00000003 0xffffffff 0x00001000
Log #2 < deleted > size=4096 seq=0x4a blksz=512 spl=0 - FILE HEADER:
- Software vsn = 100798723 = 0x6021103
- Compatibility Vsn = 101823232 = 0x611b300
- DatabaseID = 1655535898 = 0x62ad791a
- Db Name = "S6A"
- File Seq = 74 = 0x4a
- Control Seq = 571 = 0x23b
- File size = 4096 = 0x1000
- File Number = 2
- Blksiz = 512
- File Type = LOG (2)
Stored Sequence number = ##00000000000000004A
Next Available Block: 1001
Redo Thread Allocation Table Entries:
THRD FCB NAB ECC
------------------------------------- 1 0x00000003 0x00000b34 0x00001000
Appendix B
----------
CREATE CONTROLFILE [REUSE]
DATABASE name
[LOGFILE filespec [, filespec] ...]
RESETLOGS | NORESETLOGS
[MAXLOGFILES integer]
[DATAFILE filespec [, filespec] ...]
[MAXDATAFILES integer]
[MAXINSTANCES integer]
[ARCHIVELOG | NOARCHIVELOG]
[SHARED | EXCLUSIVE]
Parameters:
REUSE: If present the control files may already exist. The
new control files will overwrite the existing files. If
this option is missing, the new control files must not
yet exist. As in CREATE DATABASE, the names of the
control files are determined by the init.ora parameter
control_files.
DATABASE: Must match the database names in the data and log
files.
LOGFILE: This clause lists all the online logs that will be
used for this database. If not specified the port
dependant defaults will be assumed. The interpretation
of the filespecs depends on the next parameter.
RESETLOGS: If this flag is present the current contents of
the online logs are ignored. The new control files will
contain flags requiring ALTER DATABASE OPEN RESETLOGS,
which initializes the logs. Media recovery may be
applied as needed before the open. Note that either
RESETLOGS or NORESETLOGS must be specified. It is safest
to choose RESETLOGS and follow it with normal media
recovery.
NORESETLOGS: If specified, the log files must be the current
online logs. They must not be restored backups, and all
log files must be listed. Their headers are read to
construct the control file entries. They are used for
recovery. If archiving is enabled all the online logs
must be archived, even if they were already archived.
The SIZE option in the filespecs, if present, will be
used to validate the size of the file named.
MAXLOGFILES: Same as for CREATE DATABASE. May be different
than the value in the original control file, but it may
not be smaller the maximum number of log files the
database ever contained - including ones that have been
dropped. Set it greater than or equal to the value used
at CREATE DATABASE time.
DATAFILE: To ensure proper behavior, all datafiles for the
database must be listed. It is possible to omit a non
system tablespace file only if media recovery is enabled
and you will not be doing an open reset logs on the first
open after the create controlfile. If the omitted
file(s) contain(s) active rollback segments, the open
will most likely fail, in which case the missing
datafile(s) must be found, and the controlfile recreated.
All datafiles listed must be accessible since they are
assumed to be online. They MAY be backup copies needing
recovery. Their headers are read to construct the
control file records. The SIZE option in the filespecs,
if present, is used to validate the size of the file
named. The reuse option is ignored. The next database
open validates that all the files are specified and that
the sizes match.
MAXDATAFILES: Same as for CREATE DATABASE. May be different
than the value in the original control file, but it may
not be smaller the maximum number of data files the
database ever contained - including ones that have been
dropped.
MAXINSTANCES: Same as for CREATE DATABASE. May be different
than the value in the original control file.
[NO]ARCHIVELOG: Same as for CREATE DATABASE. May be
different than the value in the original control file.
If you wish to archive logs, it is recommended that the
ARCHIVELOG option be used with CREATE CONTROLFILE even
though the option can later be enabled with an ALTER
DATABASE command. NOARCHIVELOG is the default.
SHARED: Same as for CREATE DATABASE.
EXCLUSIVE: Same as for CREATE DATABASE.
Usage:
The CREATE CONTROLFILE command should be executed after a
STARTUP NOMOUNT. If it is successful, a new control file is
created and the database is then mounted. Any required
recovery may then be applied. It is strongly advised that a
complete backup of all available files be taken before using
this command. Since this overwrites the flags indicating
which logs were archived, they all will be archived again.
This is not necessary if the RESETLOGS option is chosen, as
the logs are all cleared. The next database open will go
through the data dictionary / controlfile integrity checker
to ensure a consistent database. After the database is
opened and verified to be consistent, it should be shutdown
cleanly. A complete backup should then be taken. This is
particularly important if the RESET flag was used on open.
.
Configuring Standby Database(Dataguard) on R12 using RMAN Hot Backup
Applies to:
Oracle Applications Technology Stack - Version: 12.0.4 to 12.0.4Linux x86
Purpose
The purpose of this note to provide case study on setting up Dataguard (Standby Database) Configuration on R12 using RMAN Hot BackupCase Study : Configuring Standby Database(Dataguard) on R12 using RMAN Hot Backup
Checked for relevance by ATG-ICM Subject Matter Expert (SME): 28-APR-2009Implementing Dataguard Physical Standby on R12 on 10g Database Using RMAN Hot Backup
=======================================================================
This case study was implemented based on steps from the official Note 452056.1 Business Continuity for Oracle Applications Release 12 on Database Release 10gR2 and should be used as a guide only along with the steps in aforementioned document.
STEPS:
=====
==> Machine 01 has an E-Business Suite Release 12.0.4 (PROD) DB_NAME=PROD01
==> Machine 02 is clean and will be used as the Standby machine DB_NAME=PROD02
==> Machine 03 will be clean and used as the Observer
Prepare the Existing Database as PRIMARY ==> Machine 01
1. Create Database Password Files
cd $ORACLE_HOME/dbs
orapwd file=orapw password= ignorecase="Y"
2. Create an initialization parameter include file (IFILE) and add ifile entry in the pfile
Create IFILE as follows:
[oracle@machine01 dbs]$ vi PROD_machine01_ifile.ora
Add the following Entry at end of pfile
IFILE=$ORACLE_HOME/dbs/PROD__ifile.ora
3. Create directory called " PROD_machine01" and place all network files under this folder
[oracle@machine01 PROD_machine01]$ mkdir PROD_machine01
Add IFILE entry on both TNSNAMES.ORA and LISTENER.ORA to use IFILE at the end of file
In Listener.ora
IFILE=$ORACLE_HOME/network/admin/PROD_machine01/listener_ifile.ora
In Tnsnames.ora
IFILE=$ORACLE_HOME/network/admin/PROD_machine01/PROD_machine01_ifile.ora
Create common IFILE for both Listener and Tnsnames entry
[oracle@machine01 PROD_machine01]$ vi PROD_machine01_ifile.ora
4. Add the following entries to the tnsnames IFILE for standby configuration
PROD01=
(DESCRIPTION=
(ADDRESS_LIST=
(LOAD_BALANCE=YES)
(FAILOVER=YES)
(ADDRESS=(PROTOCOL=tcp)(HOST=machine01.oracle.com)(PORT=1533))
)
(CONNECT_DATA=
(SID=PROD)
)
)
PROD02=
(DESCRIPTION=
(ADDRESS_LIST=
(LOAD_BALANCE=YES)
(FAILOVER=YES)
(ADDRESS=(PROTOCOL=tcp)(HOST=machine02.oracle.com)(PORT=1533))
)
(CONNECT_DATA=
(SID=PROD)
)
)
5. On PRIMARY , set the following parameters in the initialization parameter include file (IFILE)
LOG_ARCHIVE_DEST_1='LOCATION=USE_DB_RECOVERY_FILE_DEST MANDATORY'
LOG_ARCHIVE_FORMAT='%t_%s_%r.dbf'
DB_RECOVERY_FILE_DEST_SIZE = 107374182400
DB_RECOVERY_FILE_DEST= '/oracle/archive'
DB_UNIQUE_NAME=PROD01
LOG_ARCHIVE_CONFIG='dg_config=(PROD01,PROD02)'
LOG_ARCHIVE_DEST_2='service=PROD02 valid_for=(online_logfiles,primary_role) db_unique_name=PROD02 LGWR ASYNC=20480 OPTIONAL REOPEN=15
NET_TIMEOUT=30'
LOG_ARCHIVE_DEST_STATE_2=enable
FAL_SERVER='PROD02'
FAL_CLIENT='PROD01'
#standby_archive_dest='LOCATION=USE_DB_RECOVERY_FILE_DEST'
standby_file_management=AUTO
parallel_execution_message_size=8192
LOG_ARCHIVE_FORMAT='%t_%s_%r.dbf'
DB_RECOVERY_FILE_DEST_SIZE = 107374182400
DB_RECOVERY_FILE_DEST= '/oracle/archive'
DB_UNIQUE_NAME=PROD01
LOG_ARCHIVE_CONFIG='dg_config=(PROD01,PROD02)'
LOG_ARCHIVE_DEST_2='service=PROD02 valid_for=(online_logfiles,primary_role) db_unique_name=PROD02 LGWR ASYNC=20480 OPTIONAL REOPEN=15
NET_TIMEOUT=30'
LOG_ARCHIVE_DEST_STATE_2=enable
FAL_SERVER='PROD02'
FAL_CLIENT='PROD01'
#standby_archive_dest='LOCATION=USE_DB_RECOVERY_FILE_DEST'
standby_file_management=AUTO
parallel_execution_message_size=8192
Refer the following URL (10g Documentation to understand the above parameters)
http://download.oracle.com/docs/cd/B19306_01/server.102/b14239/create_ps.htm#i63561
6. Enable Archivelog mode in PRIMARY and enable Flashback (see Failover section for more information)
SQL>archive log list
>The output for above command will show whether archive is enabled or Not <
>If output shows as follows,then proceed for next step in this section to ENABLE ARCHIVE LOG Mode <
SQL> archive log list
Database log mode No Archive Mode
Automatic archival Disabled
Archive destination /oracle/PROD/10.2.0/db_1/RDBMS/
Oldest online log sequence 386
Current log sequence 387
SQL> shutdown immediate
SQL> startup mount
SQL> alter database force logging;
SQL> alter database archivelog;
SQL> alter database flashback on;
>>
7. Create standby redolog
>>Create standby redo logs on the primary database to support the standby role. The standby redo logs must be the same size as the primary database online redo logs.
It is recommended that the number of standby redo logs is one more than the number of online redo logs. <<
Assume, We have 2 Online logs in PRIMARY , then we need to add 3 standby log files
SQL> alter database add standby logfile thread 1 group 3 ( '/oracle/PROD/db/apps_st/data/stdbylog03a.dbf', '/oracle/PROD/db/apps_st/data/stdbylog03b.dbf') size 1G;
SQL> alter database add standby logfile thread 1 group 4 ( '/oracle/PROD/db/apps_st/data/stdbylog04a.dbf', '/oracle/PROD/db/apps_st/data/stdbylog04b.dbf') size 1G;
SQL> alter database add standby logfile thread 1 group 5 ( '/oracle/PROD/db/apps_st/data/stdbylog05a.dbf', '/oracle/PROD/db/apps_st/data/stdbylog05b.dbf') size 1G;
Clone the Database Software to Standby
-----------------------------------------
8. Prepare the Database Tier for Cloning
As ORACLE user on one of the production database servers, run the adpreclone.pl script.
For Example:
cd $ORACLE_HOME/appsutil/scripts/
perl adpreclone.pl dbTier
In our case
cd $ORACLE_HOME/appsutil/scripts/PROD_machine01
perl adpreclone.pl dbTier
Supply the APPS password when requested
Use the same port pool as Source
9. Copy Database Tier to Standby
Use following command to tar the source file , copy and untar in target ==> The following command will automatically tar,copy and untar in the target system
$ tar czvf - . |ssh -l oracle machine2.oracle.com "cd /oracle/PROD/db/tech_st; tar xvzf -"
>> It is recommended to use the same directory names on the standby site. <<<
10. Configure the Standby Database Tier using Rapid Clone
At Standby Site, Execute the following adcfgclone.pl script for new database Oracle home:
$ cd $ORACLE_HOME/appsutil/clone/bin
perl adcfgclone.pl dbTechStack
Respond to the prompts appropriately:
Target instance is a Real Application Cluster (RAC) instance (y/n):
"n" in the single instance case
Target System database name:
Note, db_name, not db_unique_name
Number of DATA_TOP's on the target system [4]:
Usually only one for ASM.
Target system DATA_TOP 1:
For example, /oracle/PROD
Source The New Environment
$ cd /oracle/PROD/db/tech_st/10.2.0/
$ . . PROD_machine02.env
11. Configure New Database for Communication between Primary and Standby
When adjusting parameters on the production site for Data Guard setup, an include file was created in the earlier steps, holding TNS service definitions. Copy the file to the $TNS_ADMIN directory at the standby site and name it
$ cd $TNS_ADMIN
$ mv PROD_machine01_ifile.ora PROD_machine02_ifile.ora
12. Configure Standby Database Data Guard Parameters
$ vi PROD_machine02_ifile.ora
> Add/change the following parameters <
LOG_ARCHIVE_DEST_1='LOCATION=USE_DB_RECOVERY_FILE_DEST MANDATORY'
LOG_ARCHIVE_FORMAT='%t_%s_%r.dbf'
DB_RECOVERY_FILE_DEST_SIZE = 107374182400
DB_RECOVERY_FILE_DEST= '/oracle/archive'
log_archive_config='dg_config=(PROD_IN01,PROD_IN02)'
LOG_ARCHIVE_DEST_STATE_2=enable
#standby_archive_dest='LOCATION=USE_DB_RECOVERY_FILE_DEST'
standby_file_management=AUTO
parallel_execution_message_size=8192
db_unique_name=PROD_IN02
log_archive_dest_2='service=PROD_IN01 valid_for=(online_logfiles,primary_role) db_unique_name=PROD_IN01 LGWR ASYNC=20480 OPTIONAL REOPEN=15 NET_TIMEOUT=30'
fal_server='PROD_IN01'
fal_client='PROD_IN02'
log_file_name_convert='xx','xx'
Refer the following URL (10g Documentation to understand the above parameters)
http://download.oracle.com/docs/cd/B19306_01/server.102/b14239/create_ps.htm#i63561
Clone Application Tier to Standby
---------------------------------------
# Use the same ORACLE_BASE as Source i.e /oracle/PROD
# Use the same port pool as Source, i.e port pool 12
13. Prepare the Application Tier for Cloning
Log in to the APPLMGR user and run the following commands to prepare the application tier for
&nbs; cloning:
$ cd /admin/scripts
$ perl adpreclone.pl appsTier
14. Copy the Application Tier to Standby
tar czvf - . |ssh -l oracle machine02.oracle.com "cd /oracle/PROD/apps; tar xzvf -"
15. Configure Standby Application Tier using Rapid Clone
Run adcfgclone.pl first to start configuring the new application tier file systems. These steps must be run
on each application tier node:
$ cd /clone/bin
$ perl adcfgclone.pl atTechStack
Answer prompts appropriately:
Target system database SID:
Note: db_name, not db_unique_name
Target system database server node:
Database server hostname, could be any node for RAC node if RAC used
To complete the configuration of environment run AutoConfig using the following commands:
$ cd /ad/12.0.0/bin
$ adconfig.sh contextfile=/appl/admin/.xml run=INSTE8
>>AutoConfig will report errors regarding to database connection, these errors can be ignored as the
database is unavailable. <<
16. Setup cron to periodically synchronise concurrent manager log and out files
machine01.oracle.com is machine A (Primary machine)
machine02.oracle.com is machine B (Standby machine)
On the Standby machine:
mkdir -p /log
mkdir -p /out
mkdir -p /oracle/PROD/inst/apps/PROD_machine01/logs/appl/conc/log
mkdir -p /oracle/PROD/inst/apps/PROD_machine01/logs/appl/conc/out
On the Primary Machine
mkdir -p /log
mkdir -p /out
mkdir -p /oracle/PROD/inst/apps/PROD_machine02/logs/appl/conc/log
mkdir -p /oracle/PROD/inst/apps/PROD_machine02/logs/appl/conc/out
You can set the timings to push files according to your requirement.
In our case, we have set the timing for 30 mintues as follows:
From machine A
===============
The files will be pushing from machine A every 30 minutes, on the hour and half hour, so our entries will be:
$ crontab -e
#
## Push log and out files from this machine to machine02 every 30 minutes, on the hour and half hour
#
00,30 * * * * rsync -av /oracle/PROD/inst/apps/PROD_machine01/logs/appl/conc oracle@machine02: /oracle/PROD/inst/apps/PROD_machine01/logs/appl --rsync-path=/usr/bin/rsync > /tmp/rsync_01_00-30.log
#
As crontab uses “vi” syntax, save changes using :wq!
From machine B
==============
We will also be pushing files from machine B every 30 minutes, on the quarter hour and three quarter hour, so our entries will be:
#
## Push log and out from this machine to machine01 every 30 minutes at quarter past, and quarter to.
#
15,45 * * * * rsync -av /oracle/PROD/inst/apps/PROD_machine02/logs/appl/conc oracle@machine01:/oracle/PROD/inst/apps/PROD_machine02/logs/appl --rsync-path=/usr/bin/rsync > /tmp/rsync_01_15-45.log
#
17. Setup SSH on both Primary and Standby nodes
On Primary Node: (Machine 1)
----------------------------
· Log in as oracle
· Generate the ssh key by issuing the following command:
ssh-keygen -t rsa (then press enter 3 times)
$ ssh-keygen -t rsa
Generating public/private rsa key pair.
· Press the Enter key three times.
Enter file in which to save the key (/home/oracle/.ssh/id_rsa):
Enter passphrase (empty for no passphrase):
Enter same passphrase again:
Your identification has been saved in /home/oracle/.ssh/id_rsa.
Your public key has been saved in /home/oracle/.ssh/id_rsa.pub.
The key fingerprint is:
5a:58:7e:65:ae:71:1a:82:2c:95:98:5b:48:b3:52:ac oracle@machine01.oracle.com
· CD into the .ssh directory, which is located under the home directory. Note that a file called id_rsa.pub is created.
$ ls -lrt $HOME/.ssh/
total 24
-rw-r--r-- 1 oracle dba 948 Mar 3 10:57 known_hosts
-rw-r--r-- 1 oracle dba 240 Mar 4 10:15 id_rsa.pub
-rw------- 1 oracle dba 887 Mar 4 10:15 id_rsa
· Update authorized_keys file to enable ssh ‘loopback’
$ cat $HOME/.ssh/id_rsa.pub > $HOME/.ssh/authorized_keys
· Use SCP to copy id_rsa.pub to the /tmp directory of the Remote Nodes.
$ scp $HOME/.ssh/id_rsa.pub oracle@machine02.oracle.com:/tmp
oracle@machine02.oracle.com's password:
id_rsa.pub 100% 240 0.2KB/s 00:00
On the Remote Node(s):
· Login as the oracle user
· Remove specialized .login, .profile or similar files which cause extra verbiage to be displayed to the screen.
· Create a directory called .ssh in the home directory
$ mkdir $HOME/.ssh
mkdir: cannot create directory `/home/oracle/.ssh': File exists
· Copy the content of /tmp/id_rsa.pub (copied from the Primary Node) into a new file named authorized_keys. (If you already have a file called authorized_keys in this directory, open it in vi, go to the bottom of the file, add one blank line and then copy and paste the contents of the file /tmp/id_rsa.pub into the existing file and save it.)
$ cat /tmp/id_rsa.pub > $HOME/.ssh/authorized_keys
· Verify that the .ssh directory permission is set to 700
$ chmod 700 $HOME/.ssh
· Verify that the authorized_keys file permission is set to 600
$ chmod 600 $HOME/.ssh/authorized_keys
· Verify that the $HOME directory does not have write permissions for group and others.
$ chmod go-w $HOME
· Ensure that the ssh daemon is running
$ ps -ef |grep -i ssh
root 2418 22004 0 10:25 ? 00:00:00 sshd: oracle [priv]
oracle 2420 2418 0 10:25 ? 00:00:00 sshd: oracle@pts/1
oracle 2690 2421 0 10:37 pts/1 00:00:00 grep -i ssh
root 22004 1 0 Feb29 ? 00:00:00 /usr/sbin/sshd
Test the installation:
~~~~~~~~~~~~~~~~~~~~~
· Login to the PrimaryNode as oracle user.
Execute the following command, replacing [user] with the username on the Remote Node, and [SERVER] with the host name of the Remote Node:
ssh -l [user] [SERVER]
$ uname -n
machine01.oracle.com
$ ssh -l oracle machine01 (connect to same machine)
Last login: Tue Mar 4 10:41:52 2008 from machine01.oracle.com
$ uname -n
machine01.oracle.com
· When prompted to confirm the identity, respond "Yes".
· Disconnect from the server.
$ exit
Connection to machine02 closed
$ ssh -l oracle machine02 (connect to machine 2)
Last login: Tue Mar 4 10:41:52 2008 from machine01.oracle.com
$ uname -n
machine02.oracle.com
· When prompted to confirm the identity, respond "Yes".
· Disconnect from the server.
$ exit
Connection to machine02 closed
· Execute the following commands:
$ uname -n
machine01.oracle.com
$ ssh oracle@machine02 uname -n
machine02.oracle.com
The remote hostname should appear, followed by the prompt, and you should not be asked to enter and ID or password. If you are prompted for a password, verify the following:
§ The content of the authorized_keys file contains the content of id_rsa.pub of the client
§ The permissions of the authorized_keys file are set to 600.
§ The permissions of the .ssh directory are set to 700.
The permissions of the $HOME directory do not include execute for group and other.
Now repeat the steps again as follows (to enable SSH in the opposite direction)
On Standby Node: (machine 2)
· Log in as oracle
· Generate the ssh key by issuing the following command:
ssh-keygen -t rsa (then press enter 3 times)
$ ssh-keygen -t rsa
Generating public/private rsa key pair.
· Press the Enter key three times.
Enter file in which to save the key (/home/oracle/.ssh/id_rsa):
Enter passphrase (empty for no passphrase):
Enter same passphrase again:
Your identification has been saved in /home/oracle/.ssh/id_rsa.
Your public key has been saved in /home/oracle/.ssh/id_rsa.pub.
The key fingerprint is:
6c:7d:4c:5c:21:9d:d6:8e:1f:6d:9c:52:2f:88:1c:3d oracle@machine02.oracle.com
· CD into the .ssh directory, which is located under the home directory. Note that a file called id_rsa.pub is created.
$ ls -lrt $HOME/.ssh/
-rw-r--r-- 1 oracle dba 703 Feb 18 09:54 known_hosts
-rw-r--r-- 1 oracle dba 240 Mar 4 10:32 authorized_keys
-rw-r--r-- 1 oracle dba 240 Mar 4 10:49 id_rsa.pub
-rw------- 1 oracle dba 887 Mar 4 10:49 id_rsa
· Update authorized_keys file to enable ssh ‘loopback’
$ cat $HOME/.ssh/id_rsa.pub > $HOME/.ssh/authorized_keys
· Use SCP to copy id_rsa.pub to the /tmp directory of the Remote Nodes.
$ scp $HOME/.ssh/id_rsa.pub oracle@machine01.oracle.com:/tmp
oracle@machine01.oracle.com's password:
id_rsa.pub 100% 240 0.2KB/s 00:00
On the Primary Node: (Machine 1)
· Login as the oracle user
· Copy the content of /tmp/id_rsa.pub (copied from the Primary Node) into file named authorized_keys
$ cat /tmp/id_rsa.pub > $HOME/.ssh/authorized_keys
· Verify that the .ssh directory permission is set to 700
$ chmod 700 $HOME/.ssh
· Verify that the authorized_keys file permission is set to 600
$ chmod 600 $HOME/.ssh/authorized_keys
· Verify that the $HOME directory does not have write permissions for group and others.
$ chmod go-w $HOME
· Ensure that the ssh daemon is running
$ ps -ef |grep -i ssh
root 2418 22004 0 10:25 ? 00:00:00 sshd: oracle [priv]
oracle 2420 2418 0 10:25 ? 00:00:00 sshd: oracle@pts/1
oracle 2690 2421 0 10:37 pts/1 00:00:00 grep -i ssh
root 22004 1 0 Feb29 ? 00:00:00 /usr/sbin/sshd
Test the installation at both Node(s):
--------------------------------------
· Login to the Remote Node as oracle user (Machine 2).
· Execute the following command, replacing [user] with the username on the Remote Node, and [SERVER] with the host name of the Remote Node:
ssh -l [user] [SERVER]
$ uname -n
machine02.oracle.com
$ ssh -l oracle machine02 (connect to same machine)
Last login: Tue Mar 4 10:41:52 2008 from machine02.oracle.com
$ uname -n
machine02.oracle.com
$ exit
Connection to machine02 closed
$ ssh -l oracle machine01 (connect to machine 1)
Last login: Tue Mar 4 10:41:52 2008 from machine02.oracle.com
$ uname -n
machine01.oracle.com
· When prompted to confirm the identity, respond "Yes".
· Disconnect from the server.
$ exit
Connection to machine01 closed
· Execute the following commands:
$ uname -n
machine02.oracle.com
$ ssh oracle@machine01 uname -n
machine01.oracle.com
The remote hostname should appear, followed by the prompt, and you should not be asked to enter and ID or password. If you are prompted for a password, verify the following:
§ The content of the authorized_keys file contains the content of id_rsa.pub of the client
§ The permissions of the authorized_keys file are set to 600.
§ The permissions of the .ssh directory are set to 700.
§ The permissions of the $HOME directory do not include execute for group and other.
18. Establish the Standby Database
Create a hot backup using Recovery Manager (RMAN)
Take Backup of Primary Database and Copy the backup to Standby(Machine02) using RMAN HOT BACKUP
a)set RDBMS_ORACLE_HOME env file
b) $ rman target /
RMAN> run
{
allocate channel c1 type disk;
allocate channel c2 type disk;
allocate channel c3 type disk;
backup database plus archivelog;
}
>>For RMAN: Monitoring Recovery Manager Jobs ==> Ref Note 144640.1
To monitor the Rman Backup job, Please execute the following in SQLPLUS as sysdba
SQL> SELECT sid, spid, client_info FROM v$process p, v$session s
WHERE p.addr = s.paddr
AND client_info LIKE '%id=rman%';
SQL> SELECT sid, serial#, context, sofar, totalwork,round(sofar/totalwork*100,2) "% Complete"
FROM v$session_longops
WHERE opname LIKE 'RMAN%'
AND opname NOT LIKE '%aggregate%'
AND totalwork != 0
AND sofar <> totalwork
/
SQL> SELECT sid, seconds_in_wait AS sec_wait, event FROM v$session_wait
WHERE wait_time = 0
ORDER BY sid;
Take backup of current controlfile at primary for standby site in RMAN
For Backup as Backupset:
RMAN> run
{
allocate channel c1 type disk;
backup current controlfile for standby;
}
For Backup as COPY :
RMAN> run
{
allocate channel c1 type disk;
backup as copy current controlfile for standby;
}
Once backup is done, copy the backup with archivelogs & Standby controlfile to remote location(standby)
rsync -av /oracle/archive oracle@machine02.oracle.com:/oracle/archive
19. At Standby (Machine02), Startup mount the Standby database
The following command will automatically duplicate the database using backup taken at primary and
mount the database
$ rman target sys/oracle@prod_in01 auxiliary sys/oracle@prod_in02
RMAN> DUPLICATE TARGET DATABASE FOR STANDBY
DORECOVER NOFILENAMECHECK;
Run the following command to check the standby database details
SQL> select database_role,switchover_status,checkpoint_change#,switchover#,dataguard_broker,guard_status,current_scn,flashback_on from v$database
The output should be similar to the following:
DATABASE_ROLE SWITCHOVER_STATUS CHECKPOINT_CHANGE# SWITCHOVER# DATAGUAR GUARD_S CURRENT_SCN FLASHBACK_ON
--------------- ------------------ ---------------------- ----------- --------------- ------------------- ------------------
PHYSICAL STANDBY NOT ALLOWED 5965111847227 83208404 ENABLED NONE 5965112465873 YES
20. On the primary database enable the previously deferred remote destination by executing this command
from SQL*Plus connected as sysdba:
SQL> alter system set log_archive_dest_state_2=enable SID='*';
21. Place the standby database in managed recovery by executing this command from SQL*Plus
connected as sysdba:
SQL> recover managed standby database using current logfile disconnect;
22. Verify whether the standby is correctly applying redo from the primary.
On the primary database, archive the current log using the following SQL statement:
Find the current Sequence and last archived log sequence:
SQL> archive log list;
>Archive the current redolog sequence:
SQL> alter system archive log current;
>
On the standby database, query the v$archived_log view to verify that the logs are received and applied:
SQL> select thread#, sequence#, applied,
to_char(first_time, 'mm/dd/yy hh24:mi:ss') first,
to_char(next_time, 'mm/dd/yy hh24:mi:ss') next,
to_char(completion_time, 'mm/dd/yy hh24:mi:ss') completion
from v$archived_log order by first_time;
You can also execute the following query to find the shipping details on both primary and standby
SQL> select process,status,sequence# from v$managed_standby;
23. If incase the logs are not shipping, Please check the following
a) Check alert.log file on Primary and see whether log_archive_dest_2 is reachable and check any
TNS error, if the standby destination not reachable, fix the TNS issue
b) Check the status of the log_archive_dest_2
SQL> select status,error from v$archive_dest;
> If any error from above statement, you shall defer it temporarily
SQL> alter system set log_archive_dest_state_2=defer;
c) Once the error is rectified on log_archive_dest_2, you can execute the following query to enable it
SQL> alter system set log_archive_dest_state_2=enable;
d) If logs are not shipping and if you want to apply manually, you shall move/copy the missing archivelog
from primary to standby manually using OS scp command and run the following command to apply
the changes
SQL> alter database register logfile '/oracle/archive/PROD_IN02/archivelog/2008_11_18/o1_mf_1_34_4l5bb7b4_.arc';
SWITCHOVER
============
1. Switchover Primary Database to Remote Standby Database
a) Shutdown Production E-Business Suite -
Shut down E-Business Suite application tier. Ensure the application is completely shutdown.
b) On the PRIMARY database , Issue the following command to commit to switchover to
standby:
SQL> alter database commit to switchover to standby with session shutdown;
c) Shutdown the PRIMARY database
SQL> shutdown immediate
d) Stop the PRIMARY database listener: on all database nodes:
lsnrctl stop
e) On the STANDBY database, verify that it is ready to be converted to the new primary:
SQL> select switchover_status from v$database;
You should see the following value:
SWITCHOVER_STATUS
-----------------
TO PRIMARY
f) On the STANDBY database, execute the following command to convert it to be the new primary:
SQL> alter database commit to switchover to primary;
g) Enable Flashback on the STANDBY database (Optional)
SQL> alter database flashback on;
h) Open the STANDBY Database (New Primary database)
SQL> alter database open;
i) Remove the Old Application Topology
Connect to the new primary database using SQL*Plus as user APPS and execute the following
commands:
SQL> EXEC FND_CONC_CLONE.SETUP_CLEAN;
SQL> commit;
j) Configure the Standby Database Tier
Run AutoConfig on STANDBY database(New Primary) node to configure the Oracle home for use
by the E-Business Suite.
$ cd $ORACLE_HOME/appsutil/scripts/
$ ./adautocfg.sh
k) Start Original PRIMARY as Standby
Start the database listener on database node at the original primary site:
$ lsnrctl start
Start and mount database instance and then start managed recovery:
SQL> startup mount;
SQL> recover managed standby database using current logfile disconnect;
On the New PRIMARY database at the standby site enable remote archiving by executing this
command from SQL*Plus connected as sysdba:
SQL> alter system set log_archive_dest_state_2=enable SID='*';
Verify whether logs are switching from New PRIMARY to this Standby database as described in
Step 20.
l) Perform the Cloning Finishing Tasks as per Note 406982.1
FAILOVER
=========
The filover can be done only if flashback is enabled on both databases. If following Note 452056.1, flashback would only be enabled on one of the databases after following the Switchover section. Flashback should be enabled at the start on Primary when archive log mode was enabled, and before the Standby is built.
1. Failover to Standby Database
On the standby database, execute the following command to convert it to be the new primary:
SQL> recover managed standby database cancel;
SQL> recover managed standby database finish force;
SQL> alter database commit to switchover to primary;
2. Enable Flashback if not enabled already
SQL> alter database flashback on;
3. Open the Standby Database
SQL> alter database open;
4. Remove the Old Application Topology
Connect to New PRIMARY database as APPS User and execute the following commands:
SQL> EXEC FND_CONC_CLONE.SETUP_CLEAN;
SQL> commit;
5. To Configure Database Tier, Run AutoConfig on the New PRIMARY database node to configure the
Oracle home
cd $ORACLE_HOME/appsutil/scripts/
./adautocfg.sh
6. To Configure Application Tiers, Run AutoConfig on New PRIMARY site application tier nodes.
cd $ADMIN_SCRIPTS_HOME
./adautocfg.sh
7. To Establish Original Primary as Standby Using Flashback
On the standby (New PRIMARY)site, note the SCN when the database became primary:
select to_char(standby_became_primary_scn) from v$database;
8. On the Original PRIMARY site, flashback and start managed recovery:
SQL> shutdown immediate;
SQL> startup mount;
SQL> flashback database to scn ;
SQL> alter database convert to physical standby;
SQL> shutdown immediate;
SQL> startup mount;
SQL> alter database recover managed standby database using current logfile disconnect;
Verify whether standby operation on Original Primary and Perform Cloning Finishing Task as per
Note 406982.1
Open the Standby Database for Testing Using Flashback Database
=================================================
1. On the standby site, cancel managed recovery:
SQL> recover managed standby database cancel;
2. On the standby site, enable flashback if it has not been enable before:
SQL> alter database flashback on;
3. On the standby site, create a guaranteed restore point (named “testing _starts” in this example):
SQL> create restore point testing_starts guarantee flashback database;
4. On the Primary Site , switch the current redo log and then defer the archive destination:
SQL> alter system archive log current;
SQL> alter system set log_archive_dest_state_2=defer SID='*';
5. On the standby site, activate and open the database:
SQL> alter database activate standby database;
SQL> alter database set standby database to maximize performance;
SQL> alter database open;
6. As Standby Database is now OPEN, Now You can Perform Testing and any changes made to this
database will be rolled back after Flashback
Note : This standby site will be getting behind on redo application during the testing period and so make
sure that you do not get too far behind.
7. Flashback the Database and Resume Standby Operation
On the standby site , Use flashback and start managed recovery:
SQL> startup mount force;
SQL> flashback database to restore point testing_starts;
SQL> drop restore point testing_starts;
SQL> alter database convert to physical standby;
SQL> startup mount force;
SQL> alter database recover managed standby database using current logfile disconnect;
8. On the Primary site , enable the archive destination:
SQL> alter system set log_archive_dest_state_2=enable SID='*';
Subscribe to:
Posts (Atom)