About Me

Database and GIS Consultant.

Tuesday, May 26, 2020

How to Install Oracle Patch - Basic Steps

Purpose: Basic steps involved in installing an Oracle Bundle Patch (Windows OS)

Environment:
Database Software: Oracle 12c Release 2
Operating System: Windows Server 2012 R2 Standard - 64 Bit
Patch to Install: Oracle Database Patch 30446296, which a Bundle Patch (BP) patch BP 12.2.0.1.200114 (latest available as of date), downloaded from Oracle Support.

Prepare:


1. Download the latest Bundle patch and extract it at a staging area.

Read the "README.html" file that comes along with the patch. The "Prerequisites" says that "You must use the OPatch utility version 12.2.0.1.7 or later to apply this patch. Oracle recommends that you usethe latest released OPatch 12.2, which is available for download from My Oracle Support patch 6880880 by selecting the 12.2.0.1.0 release."

Install


2: Check the existing OPatch version that came as part of the 12cR2 base release:-

set ORACLE_HOME=C:\Oracle12cR2_64Bit_DB\product
set Path=C:\Oracle12cR2_64Bit_DB\product\bin;C:\Oracle12cR2_64Bit_DB\product\OPatch;C:\Program Files (x86)\

C:\> opatch version
OPatch Version: 12.2.0.1.6

OPatch succeeded.

3. Download and Copy new OPatch

I have an older version, which means I need to download OPatch 12.2.0.1.7 or later, so I again downloaded OPatch 12.2.0.1.21 (Patch 6880880) from Oracle Support and extracted it at a staging area (E:\Ora_Patch_Stage\OP_p6880880\OPatch).

Backup the existing OPatch, just in case.

xcopy /E /I C:\Oracle12cR2_64Bit_DB\product\OPatch C:\Oracle12cR2_64Bit_DB\product\OPatch_BKP

Delete the old OPatch folder

rmdir /s /q C:\Oracle12cR2_64Bit_DB\product\OPatch

Copy over the downloaded OPatch folder to the Oracle Home.

xcopy /E /I E:\Ora_Patch_Stage\OP_p6880880\OPatch C:\Oracle12cR2_64Bit_DB\product\OPatch
Check the OPatch version again:-

C:\>opatch version
OPatch Version: 12.2.0.1.21

OPatch succeeded.


Which meets the Prerequisites, so let’s proceed with installing the Oracle Bundle Patch.

4: Install the Oracle Bundle Database Bundle Patch
 

Navigate to the location where its extracted and install

E:
cd E:\Ora_Patch_Stage\BP_p30446296\30446296
cd E:\Ora_Patch_Stage\BP_p30446296\30446296\opatch apply

Verify


5. Verify the install status by checking the OPatch logs at 

"C:\Program Files\Oracle\Inventory\logs
"ORACLE_HOME\cfgtoollogs\opatch"

You can also check what patches have been installed by

C:\> opatch lsinventory



No comments: