Patching OEM 13c Release 2 PSU for OMS and Agent

Description:-

In this article we are going to see the patching of OEM Server.

Patching OMS 13c Release 2 (13.2.0.0.181016) System PSU Patch :-

Check OMS server status :

[oracle@oem13c ~]$ cd /u01/app/oracle/middleware/bin
[oracle@oem13c bin]$ ./emctl status oms
Oracle Enterprise Manager Cloud Control 13c Release 2
Copyright (c) 1996, 2016 Oracle Corporation. All rights reserved.
WebTier is Up
Oracle Management Server is Up
JVMD Engine is Up
BI Publisher Server is Down
BI Publisher is disabled, to enable BI Publisher on this host, use the 'emctl config oms -enable_bip' command

Check EM repository database and listener status :

SQL> select name,open_mode from v$database;

NAME      OPEN_MODE
--------- --------------------
EMREPDB   READ WRITE


[oracle@oem13c ~]$ lsnrctl status

LSNRCTL for Linux: Version 12.1.0.2.0 - Production on 12-DEC-2018 23:35:52

Copyright (c) 1991, 2014, Oracle. All rights reserved.

Connecting to (ADDRESS=(PROTOCOL=tcp)(HOST=)(PORT=1521))
STATUS of the LISTENER
------------------------
Alias LISTENER
Version TNSLSNR for Linux: Version 12.1.0.2.0 - Production
Start Date 05-DEC-2018 20:27:14
Uptime 7 days 3 hr. 8 min. 37 sec
Trace Level off
Security ON: Local OS Authentication
SNMP OFF
Listener Parameter File /u01/app/oracle/product/12.1.0.2/db_1/network/admin/listener.ora
Listener Log File /u01/app/oracle/diag/tnslsnr/oem13c/listener/alert/log.xml
Listening Endpoints Summary...
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=oem13c.localdomain.com)(PORT=1521)))
Services Summary...
Service "emrepdb" has 1 instance(s).
Instance "emrepdb", status READY, has 1 handler(s) for this service...
Service "emrepdbXDB" has 1 instance(s).
Instance "emrepdb", status READY, has 1 handler(s) for this service...
The command completed successfully

Check Opatch and OMSPatcher version :

[oracle@oem13c]$ export ORACLE_HOME=/u01/app/oracle/middleware

[oracle@oem13c OPatch]$ cd /u01/app/oracle/middleware/OPatch

[oracle@oem13c OPatch]$ ./opatch version
OPatch Version: 13.8.0.0.0
OPatch succeeded.

[oracle@oem13c]$ /u01/app/oracle/middleware/OMSPatcher/omspatcher version
OMSPatcher Version: 13.8.0.0.0
OPlan Version: 12.1.0.2.2
OsysModel build: Mon Dec 21 18:31:52 PST 2015

OMSPatcher succeeded.

Upgrade to latest Opatch version :

Download Link : OPatch version 13.9.3.3.0 for EMCC 13.x customers Only (not for FMW 12c) (Patch)

[oracle@oem13c ~]$ cd $ORACLE_HOME

[oracle@oem13c middleware]$ mv OPatch/ OPatch_bkp

[oracle@oem13c u01]$ unzip p6880880_139000_Generic.zip
Archive: p6880880_139000_Generic.zip
creating: 6880880/
inflating: 6880880/README.txt
inflating: 6880880/opatch_generic.jar
inflating: 6880880/version.txt

OPatch 13.9 in EM13c required the latest version of JDK. So download the latest JDK and install on my OMS Server.Copy & Paste of an OPatch directory is no more possible anymore.

Install JDK software:

Check Java version,

[oracle@oem13c u01]$ java -version
java version "1.7.0_09-icedtea"
OpenJDK Runtime Environment (rhel-2.3.4.1.0.1.el6_3-x86_64)
OpenJDK 64-Bit Server VM (build 23.2-b09, mixed mode)

Update JDK version,

Download latest  Java(TM) SE Runtime Environment 1.8 

[root@oem13c u01]# rpm -ivh jdk-8u181-linux-x64.rpm
Preparing... ########################################### [100%]
1:jdk1.8 ########################################### [100%]
Unpacking JAR files...
tools.jar...
plugin.jar...
javaws.jar...
deploy.jar...
rt.jar...
jsse.jar...
charsets.jar...
localedata.jar...

[root@oem13c u01]# java -version
java version "1.8.0_181"
Java(TM) SE Runtime Environment (build 1.8.0_181-b13)
Java HotSpot(TM) 64-Bit Server VM (build 25.181-b13, mixed mode)

Install latest Opatch 13.9.3.3.0 :

[oracle@oem13c ~]$ java -jar /u01/6880880/opatch_generic.jar -silent oracle_home=$ORACLE_HOME
Launcher log file is /tmp/OraInstall2018-12-13_04-10-52AM/launcher2018-12-13_04-10-52AM.log.
Extracting the installer . . . . Done
Checking if CPU speed is above 300 MHz. Actual 3192.679 MHz Passed
Checking swap space: must be greater than 512 MB. Actual 5999 MB Passed
Checking if this platform requires a 64-bit JVM. Actual 64 Passed (64-bit not required)
Checking temp space: must be greater than 300 MB. Actual 8017 MB Passed
Preparing to launch the Oracle Universal Installer from /tmp/OraInstall2018-12-13_04-10-52AM
Installation Summary

Disk Space : Required 36 MB, Available 14,557 MB
Feature Sets to Install:
Next Generation Install Core 13.9.1.0.3
Next Generation Install Component Stager 13.9.1.0.3
Oracle XDK JRF XMLParser 12.1.3.0.0
OPatch 13.9.3.3.0
OPatch Auto OPlan 13.9.1.0.4
Session log file is /tmp/OraInstall2018-12-13_04-10-52AM/install2018-12-13_04-10-52AM.log

Loading products list. Please wait.
1%
40%

Loading products. Please wait...

Check latest opatch version :

[oracle@oem13c ~]$ export ORACLE_HOME=/u01/app/oracle/middleware/
[oracle@oem13c ~]$ cd /u01/app/oracle/middleware/OPatch
[oracle@oem13c OPatch]$ ./opatch version
OPatch Version: 13.9.3.3.0

OPatch succeeded.

Upgrade to latest OMSPatcher version :

Download Link : OMSPatcher patch of version 13.8.0.0.3 for Enterprise Manager Cloud Control 13.2.0.0.0 (Patch)

[oracle@oem13c ~]$ cd $ORACLE_HOME
[oracle@oem13c middleware]$ mv OMSPatcher/ OMSPatcher_bkp
[oracle@oem13c middleware]$ unzip /u01/p19999993_132000_Generic.zip -d $ORACLE_HOME
Archive: /u01/p19999993_132000_Generic.zip
creating: /u01/app/oracle/middleware/OMSPatcher/
inflating: /u01/app/oracle/middleware/OMSPatcher/omspatcher.bat
creating: /u01/app/oracle/middleware/OMSPatcher/jlib/
inflating: /u01/app/oracle/middleware/OMSPatcher/jlib/omspatcher.jar
inflating: /u01/app/oracle/middleware/OMSPatcher/jlib/oracle.omspatcher.classpath.jar
inflating: /u01/app/oracle/middleware/OMSPatcher/jlib/oracle.omspatcher.classpath.unix.jar
inflating: /u01/app/oracle/middleware/OMSPatcher/jlib/oracle.omspatcher.classpath.windows.jar
creating: /u01/app/oracle/middleware/OMSPatcher/scripts/
creating: /u01/app/oracle/middleware/OMSPatcher/scripts/oms/
creating: /u01/app/oracle/middleware/OMSPatcher/scripts/oms/oms_child_scripts/
inflating: /u01/app/oracle/middleware/OMSPatcher/scripts/oms/oms_child_scripts/omspatcher_jvm_discovery
inflating: /u01/app/oracle/middleware/OMSPatcher/scripts/oms/oms_child_scripts/omspatcher_jvm_discovery.bat
inflating: /u01/app/oracle/middleware/OMSPatcher/scripts/oms/oms_child_scripts/omspatcher_wls
inflating: /u01/app/oracle/middleware/OMSPatcher/scripts/oms/oms_child_scripts/omspatcher_wls.bat
inflating: /u01/app/oracle/middleware/OMSPatcher/scripts/oms/omspatcher
inflating: /u01/app/oracle/middleware/OMSPatcher/scripts/oms/omspatcher.bat
creating: /u01/app/oracle/middleware/OMSPatcher/wlskeys/
inflating: /u01/app/oracle/middleware/OMSPatcher/wlskeys/createkeys.cmd
inflating: /u01/app/oracle/middleware/OMSPatcher/wlskeys/createkeys.sh
creating: /u01/app/oracle/middleware/OMSPatcher/oms/
inflating: /u01/app/oracle/middleware/OMSPatcher/oms/generateMultiOMSPatchingScripts.pl
inflating: /u01/app/oracle/middleware/OMSPatcher/omspatcher
inflating: /u01/app/oracle/middleware/readme.txt
inflating: /u01/app/oracle/middleware/PatchSearch.xml

[oracle@oem13c OMSPatcher]$ /u01/app/oracle/middleware/OMSPatcher/omspatcher version
OMSPatcher Version: 13.8.0.0.3
OPlan Version: 12.1.0.2.2
OsysModel build: Mon Dec 21 18:31:52 PST 2015

OMSPatcher succeeded.

Download OMS System patch :

Download Link : Patch 28717501: EMBP Patch Set Update 13.2.0.0.181016

Move the downloaded system PSU patch to OMS server.

[oracle@oem13c hgfs]$ cd /u01/
[oracle@oem13c u01]$ ls -lrt
total 40744
drwxr-xr-x 7 oracle oinstall 4096 Jul 11 2014 database
drwxrwxr-x. 2 oracle oinstall 16384 Jul 13 01:20 lost+found
drwxrwxr-x. 5 oracle oinstall 4096 Aug 29 20:51 app
-rwxrw-rw- 1 oracle oinstall 41694955 Dec 13 00:20 p28717501_132000_Generic.zip
[oracle@oem13c u01]$ unzip p28717501_132000_Generic.zip


[oracle@oem13c u01]$ cd 28717501/
[oracle@oem13c 28717501]$ ls -lrt
total 60
drwxr-x--- 2 oracle oinstall 4096 Oct 1 15:20 automation
drwxr-x--- 4 oracle oinstall 4096 Oct 1 16:02 28717501
-rw-rw-r-- 1 oracle oinstall 1198 Oct 1 17:57 bundle.xml
-rw-rw-r-- 1 oracle oinstall 24 Oct 16 12:01 README.txt
-rw-rw-r-- 1 oracle oinstall 43441 Oct 16 12:01 README.html

Create Property File :

[oracle@oem13c ~]$ /u01/app/oracle/middleware/OMSPatcher/wlskeys/createkeys.sh –oh /u01/app/oracle/middleware/bin -location /u01/
Please enter weblogic admin server username: weblogic
Please enter weblogic admin server password:
Warning: weblogic.Admin is deprecated and will be removed in a future release. WLST should be used instead of weblogic.Admin.
Creating the key file can reduce the security of your system if it is not kept in a secured location after it is created. Creating new key...

Trying to get configuration and key files for the given inputs...
This operation will take some time. Please wait for updates...
User configuration file created: /u01/config
User key file created: /u01/key
'createkeys' succeeded.

[oracle@oem13c ~]$ cd /u01/
[oracle@oem13c u01]$ ls -lrt
total 40780
drwxr-xr-x 7 oracle oinstall 4096 Jul 11 2014 database
drwxrwxr-x. 2 oracle oinstall 16384 Jul 13 01:20 lost+found
drwxrwxr-x. 5 oracle oinstall 4096 Aug 29 20:51 app
drwxr-x--- 4 oracle oinstall 4096 Oct 1 15:20 28717501
-rw-rw-r-- 1 oracle oinstall 23484 Oct 16 15:22 PatchSearch.xml
-rwxrw-rw- 1 oracle oinstall 41694955 Dec 13 00:20 p28717501_132000_Generic.zip
-rw-r--r-- 1 oracle oinstall 64 Dec 13 01:06 key
-rw-r--r-- 1 oracle oinstall 227 Dec 13 01:06 config

[oracle@oem13c u01]$ more config
#WebLogic User Configuration File; 2
#Thu Dec 13 01:06:56 IST 2018
weblogic.management.username={AES}4AV4pbWy6lnveCW0AVBu0vvIsBJl8vuhmLkdufvRHgA\=
weblogic.management.password={AES}/k7I8g7RuDHcSWYz90mJkml8ohQ+fLVrA1ZeV+/3934\=

Get Admin Server URL,

[oracle@oem13c]$ export ORACLE_HOME=/u01/app/oracle/middleware
[oracle@oem13c bi]$ cd /u01/app/oracle/middleware/bin/
[oracle@oem13c bin]$ emctl status oms -details
Oracle Enterprise Manager Cloud Control 13c Release 2
Copyright (c) 1996, 2016 Oracle Corporation. All rights reserved.
Enter Enterprise Manager Root (SYSMAN) Password :
Console Server Host : oem13c.localdomain.com
HTTP Console Port : 7788
HTTPS Console Port : 7802
HTTP Upload Port : 4889
HTTPS Upload Port : 4903
EM Instance Home : /u01/app/oracle/gc_inst/em/EMGC_OMS1
OMS Log Directory Location : /u01/app/oracle/gc_inst/em/EMGC_OMS1/sysman/log
OMS is not configured with SLB or virtual hostname
Agent Upload is locked.
OMS Console is locked.
Active CA ID: 1
Console URL: https://oem13c.localdomain.com:7802/em
Upload URL: https://oem13c.localdomain.com:4903/empbs/upload

WLS Domain Information
Domain Name : GCDomain
Admin Server Host : oem13c.localdomain.com
Admin Server HTTPS Port: 7102
Admin Server is RUNNING

Oracle Management Server Information
Managed Server Instance Name: EMGC_OMS1
Oracle Management Server Instance Host: oem13c.localdomain.com
WebTier is Up
Oracle Management Server is Up
JVMD Engine is Up

BI Publisher Server Information
BI Publisher Managed Server Name: BIP
BI Publisher Server is Down
BI Publisher is disabled, to enable BI Publisher on this host, use the 'emctl config oms -enable_bip' command

Create the property file with the following entries:

Syntax :

AdminServerURL=t3s://<host address from where admin server is running>:<port of the admin server>
AdminConfigFile=<'config' file location>
AdminKeyFile=<'key' file location>

Example :

[oracle@oem13c u01]$ vi propertyfile
AdminServerURL=t3s://oem13c.localdomain.com:7102
AdminConfigFile=/u01/config
AdminKeyFile=/u01/key

Analyze OMS System patch :

[oracle@oem13c 28717501]$ /u01/app/oracle/middleware/OMSPatcher/omspatcher apply -analyze -property_file /u01/propertyfile

OMSPatcher Automation Tool
Copyright (c) 2017, Oracle Corporation. All rights reserved.

OMSPatcher version : 13.8.0.0.3
OUI version : 13.9.1.0.0
Running from : /u01/app/oracle/middleware
Log file location : /u01/app/oracle/middleware/cfgtoollogs/omspatcher/opatch2018-12-13_04-58-11AM_1.log

OMSPatcher log file: /u01/app/oracle/middleware/cfgtoollogs/omspatcher/28717501/omspatcher_2018-12-13_04-58-24AM_analyze.log

Configuration Validation: Success

Running apply prerequisite checks for sub-patch(es) "28717501" and Oracle Home "/u01/app/oracle/middleware"...
Sub-patch(es) "28717501" are successfully analyzed for Oracle Home "/u01/app/oracle/middleware"

Complete Summary
================

All log file names referenced below can be accessed from the directory "/u01/app/oracle/middleware/cfgtoollogs/omspatcher/2018-12-13_04-58-11AM_SystemPatch_28717501_1"

Prerequisites analysis summary:
-------------------------------

The following sub-patch(es) are applicable:

Featureset Sub-patches Log file
---------- ----------- --------
oracle.sysman.top.oms 28717501 28717501_opatch2018-12-13_04-58-23AM_1.log

Log file location: /u01/app/oracle/middleware/cfgtoollogs/omspatcher/28717501/omspatcher_2018-12-13_04-58-24AM_analyze.log

OMSPatcher succeeded.

Take backup of your OEM environment before you begin OMS patching.

Shut down OMS services :

[oracle@oem13c ~]$ cd /u01/app/oracle/middleware/bin/
[oracle@oem13c bin]$ ./emctl stop oms
Oracle Enterprise Manager Cloud Control 13c Release 2
Copyright (c) 1996, 2016 Oracle Corporation. All rights reserved.
Stopping Oracle Management Server...
Oracle Management Server Successfully Stopped
Oracle Management Server is Down
JVMD Engine is Down

Apply OMS System Patch to OMS 13cR2 :

[oracle@oem13c 28717501]$ /u01/app/oracle/middleware/OMSPatcher/omspatcher apply -property_file /u01/propertyfile 

OMSPatcher Automation Tool
Copyright (c) 2017, Oracle Corporation. All rights reserved.

OMSPatcher version : 13.8.0.0.3
OUI version : 13.9.1.0.0
Running from : /u01/app/oracle/middleware
Log file location : /u01/app/oracle/middleware/cfgtoollogs/omspatcher/opatch2018-12-13_05-11-14AM_1.log

OMSPatcher log file: /u01/app/oracle/middleware/cfgtoollogs/omspatcher/28717501/omspatcher_2018-12-13_05-11-26AM_deploy.log

Configuration Validation: Success

Running apply prerequisite checks for sub-patch(es) "28717501" and Oracle Home "/u01/app/oracle/middleware"...
Sub-patch(es) "28717501" are successfully analyzed for Oracle Home "/u01/app/oracle/middleware"

To continue, OMSPatcher will do the following:
[Patch and deploy artifacts] : Apply sub-patch(es) [ 28717501 ]
Apply RCU artifact with patch "/u01/app/oracle/middleware/.omspatcher_storage/28717501_Oct_1_2018_02_47_12/original_patch";
Register MRS artifact "targetType";
Register MRS artifact "storeTargetType";
Register MRS artifact "default_collection";
Register MRS artifact "swlib";
Register MRS artifact "jobTypes"

Do you want to proceed? [y|n]
y
User Responded with: Y

Applying sub-patch(es) "28717501"
.
.
.

Complete Summary
================

All log file names referenced below can be accessed from the directory "/u01/app/oracle/middleware/cfgtoollogs/omspatcher/2018-12-13_05-11-14AM_SystemPatch_28717501_1"

Patching summary:
-----------------

Binaries of the following sub-patch(es) have been applied successfully:

                        Featureset   Sub-patches                                     Log file
                        ----------   -----------                                     --------
  oracle.sysman.top.oms_13.2.0.0.0      28717501   28717501_opatch2018-12-13_05-11-25AM_1.log

Deployment summary:
-------------------

The following artifact(s) have been successfully deployed:

               Artifacts                                                      Log file
               ---------                                                      --------
                     SQL       rcu_applypatch_original_patch_2018-12-13_05-18-16AM.log
          MRS-targetType           emctl_register_targetType_2018-12-13_05-21-13AM.log
          MRS-targetType           emctl_register_targetType_2018-12-13_05-21-29AM.log
     MRS-storeTargetType      emctl_register_storeTargetType_2018-12-13_05-21-39AM.log
     MRS-storeTargetType      emctl_register_storeTargetType_2018-12-13_05-21-51AM.log
  MRS-default_collection   emctl_register_default_collection_2018-12-13_05-22-02AM.log
  MRS-default_collection   emctl_register_default_collection_2018-12-13_05-22-10AM.log
               MRS-swlib                emctl_register_swlib_2018-12-13_05-22-17AM.log
               MRS-swlib                emctl_register_swlib_2018-12-13_05-22-31AM.log
               MRS-swlib                emctl_register_swlib_2018-12-13_05-22-41AM.log
            MRS-jobTypes             emctl_register_jobTypes_2018-12-13_05-23-01AM.log
            MRS-jobTypes             emctl_register_jobTypes_2018-12-13_05-23-09AM.log
            MRS-jobTypes             emctl_register_jobTypes_2018-12-13_05-23-17AM.log
            MRS-jobTypes             emctl_register_jobTypes_2018-12-13_05-23-30AM.log


Log file location: /u01/app/oracle/middleware/cfgtoollogs/omspatcher/28717501/omspatcher_2018-12-13_05-11-26AM_deploy.log

OMSPatcher succeeded.

Start OMS services :

[oracle@oem13c bin]$ ./emctl start oms
Oracle Enterprise Manager Cloud Control 13c Release 2
Copyright (c) 1996, 2016 Oracle Corporation. All rights reserved.
Starting Oracle Management Server...
WebTier Successfully Started
Oracle Management Server Successfully Started
Oracle Management Server is Up
JVMD Engine is Up

 

Apply Oracle® Management Agent 13c Release 2 (13.2.0.0.0)  Patch :-

Download Agent patch from oracle support :

Oracle® Management Agent 13c Release 2 patch 28947175 

Check latest opatch version :

[oracle@oem13c ~]$ cd /u01/app/oracle/agent/agent_13.2.0.0.0/OPatch
[oracle@oem13c OPatch]$ ./opatch version
OPatch Version: 13.9.3.3.0

OPatch succeeded.

Verify the Oracle Inventory :

[oracle@oem13c ~]$ cd /u01/app/oracle/agent/agent_13.2.0.0.0/OPatch
[oracle@oem13c OPatch]$ ./opatch lsinventory
Oracle Interim Patch Installer version 13.9.3.3.0
Copyright (c) 2018, Oracle Corporation.  All rights reserved.

Oracle Home       : /u01/app/oracle/agent/agent_13.2.0.0.0
Central Inventory : /u01/app/oraInventory
   from           : /u01/app/oracle/agent/agent_13.2.0.0.0/oraInst.loc
OPatch version    : 13.9.3.3.0
OUI version       : 13.8.0.0.0
Log file location : /u01/app/oracle/agent/agent_13.2.0.0.0/cfgtoollogs/opatch/opatch2018-12-19_01-04-23AM_1.log

OPatch detects the Middleware Home as "/u01/app/oracle/agent"

Lsinventory Output file location : /u01/app/oracle/agent/agent_13.2.0.0.0/cfgtoollogs/opatch/lsinv/lsinventory2018-12-19_01-04-23AM.txt
--------------------------------------------------------------------------------
Local Machine Information::
Hostname: oem13c.localdomain.com
ARU platform id: 226
ARU platform description:: Linux_AMD64Interim patches (1) :

Patch  24470104     : applied on Wed Aug 29 23:42:54 IST 2018
Unique Patch ID:  -1471524899
   Created on 18 Aug 2016, 05:54:59 hrs PST8PDT
   Bugs fixed:
     24011099, 19030178
-----------------------------------------------------------
OPatch succeeded.

Stop the EM agent :-

[oracle@oem13c ~]$ cd /u01/app/oracle/agent/agent_inst/bin/
[oracle@oem13c bin]$ emctl stop agent
Oracle Enterprise Manager Cloud Control 13c Release 2
Copyright (c) 1996, 2016 Oracle Corporation. All rights reserved.
Stopping agent ... stopped.

Unzip the patch zip file :-

[oracle@oem13c u01]$ unzip p28947175_132200_Generic.zip
Archive: p28947175_132200_Generic.zip
creating: 28947175/
creating: 28947175/files/
creating: 28947175/files/oracle.sysman.db.agent.plugin/
.
.

Apply agent patch :

[oracle@oem13c 28947175]$ /u01/app/oracle/agent/agent_13.2.0.0.0/OPatch/opatch napply
Oracle Interim Patch Installer version 13.9.3.3.0
Copyright (c) 2018, Oracle Corporation. All rights reserved.

Oracle Home : /u01/app/oracle/agent/agent_13.2.0.0.0
Central Inventory : /u01/app/oraInventory
from : /u01/app/oracle/agent/agent_13.2.0.0.0/oraInst.loc
OPatch version : 13.9.3.3.0
OUI version : 13.8.0.0.0
Log file location : /u01/app/oracle/agent/agent_13.2.0.0.0/cfgtoollogs/opatch/opatch2018-12-19_02-08-29AM_1.log

OPatch detects the Middleware Home as "/u01/app/oracle/agent"

Verifying environment and performing prerequisite checks...
OPatch continues with these patches: 28947175 28831903

Do you want to proceed? [y|n]
y
User Responded with: Y
All checks passed.
Backing up files...
Applying interim patch '28947175' to OH '/u01/app/oracle/agent/agent_13.2.0.0.0'

Patching component oracle.sysman.agent.ic, 13.2.0.0.0...
Applying interim patch '28947175' to OH '/u01/app/oracle/agent/agent_13.2.0.0.0'

Patching component oracle.sysman.top.agent, 13.2.0.0.0...
Applying interim patch '27160866' to OH '/u01/app/oracle/agent/agent_13.2.0.0.0'

Patching component oracle.sysman.top.agent, 13.2.0.0.0...
Patches 25610702,27160866 successfully applied.
Log file location: /u01/app/oracle/agent/agent_13.2.0.0.0/cfgtoollogs/opatch/opatch2018-12-19_12-35-50PM_1.log

OPatch succeeded.

Start the agent :

[oracle@oem13c bin]$ emctl start agent
Oracle Enterprise Manager Cloud Control 13c Release 2
Copyright (c) 1996, 2016 Oracle Corporation. All rights reserved.
Starting agent ............................................. started.

[oracle@oem13c bin]$ emctl status agent
Oracle Enterprise Manager Cloud Control 13c Release 2
Copyright (c) 1996, 2016 Oracle Corporation. All rights reserved.
---------------------------------------------------------------
Agent Version : 13.2.0.0.0
OMS Version : 13.2.0.0.0
Protocol Version : 12.1.0.1.0
Agent Home : /u01/app/oracle/agent/agent_inst
Agent Log Directory : /u01/app/oracle/agent/agent_inst/sysman/log
Agent Binaries : /u01/app/oracle/agent/agent_13.2.0.0.0
Core JAR Location : /u01/app/oracle/agent/agent_13.2.0.0.0/jlib
Agent Process ID : 49584
Parent Process ID : 49202
Agent URL : https://oem13c.localdomain.com:3872/emd/main/
Local Agent URL in NAT : https://oem13c.localdomain.com:3872/emd/main/
Repository URL : https://oem13c.localdomain.com:4903/empbs/upload
Started at : 2018-12-19 18:48:51
Started by user : oracle
Operating System : Linux version 2.6.39-400.17.1.el6uek.x86_64 (amd64)
Number of Targets : 28
Last Reload : (none)
Last successful upload : 2018-12-19 18:49:46
Last attempted upload : 2018-12-19 18:49:46
Total Megabytes of XML files uploaded so far : 0.02
Number of XML files pending upload : 0
Size of XML files pending upload(MB) : 0
Available disk space on upload filesystem : 27.24%
Collection Status : Collections enabled
Heartbeat Status : Ok
Last attempted heartbeat to OMS : 2018-12-19 18:49:16
Last successful heartbeat to OMS : 2018-12-19 18:49:16
Next scheduled heartbeat to OMS : 2018-12-19 18:50:20

Verify the patch installation :

[oracle@oem13c 28831903]$ opatch lspatches
28947175;EM-AGENT Patch 13.2.0.0.181016
28831903

 

Catch Me On:- Hariprasath Rajaram Telegram:https://t.me/joinchat/I_f4DhGF_Zifr9YZvvMkRg LinkedIn:https://www.linkedin.com/in/hari-prasath-aa65bb19/ Facebook:https://www.facebook.com/HariPrasathdba FB Group:https://www.facebook.com/groups/894402327369506/ FB Page: https://www.facebook.com/dbahariprasath/? Twitter: https://twitter.com/hariprasathdba

Step by Step Apply Rolling PSU Patch In Oracle Database 12c RAC Environment

Rolling upgrade patch :-

  • The rolling upgrade refers to upgrading different databases or different instances of the same database (in a Real Application Clusters environment) one at a time, without stopping the database.
  • The advantage of a RAC rolling upgrade is that it enables at least some instances of the RAC installation to be available during the scheduled outage required for patch upgrades. Only the RAC instance that is currently being patched needs to be brought down. The other instances can continue to remain available. This means that the impact on the application downtime required for such scheduled outages is further minimized. Oracle’s opatch utility enables the user to apply the patch successively to the different instances of the RAC installation.
  • Rolling upgrade of patches is currently available for one-off patches and PSU patches.
  • Rolling patch upgrades are not available for deployments where the Oracle Database software is shared across the different nodes.
  • Before Opatchauto utility, we need to manually down the instance and cluster related services(prepatch.sh) before applying rolling patch.
  • The GI System patch includes updates for both the Clusterware home and Database home that can be applied in a rolling fashion.
  • This patch is Oracle RAC Rolling Installable has to be mentioned in README.html.

Step by step apply Rolling PSU Patch in Oracle Database 12c RAC environment :-

Description:- 

In this article we are going to see Step by step Apply Rolling PSU Patch in Oracle Database 12c RAC environment

Let start the Demo:-

Download the latest the PSU patch for GRID and ORACLE_HOME :-

Patch 28349311 –  GRID INFRASTRUCTURE PATCH SET UPDATE 12.1.0.2.181016

The patch 28349311 was the super seeded patch of database PSU patch.

The above PSU patch is rolling applicable and so involves minimal downtime.

Database Env :-

For Node 1,

prod()
{
ORACLE_HOME=/u01/app/oracle/product/12.1.0.2/db_1
export ORACLE_HOME
ORACLE_BASE=/oracle/app/oracle
export ORACLE_BASE
ORACLE_SID=prod1
export ORACLE_SID
LD_LIBRARY_PATH=$ORACLE_HOME/lib:/usr/lib:.
export LD_LIBRARY_PATH
LIBPATH=$ORACLE_HOME/lib32:$ORACLE_HOME/lib:/usr/lib:/lib
export LIBPATH
TNS_ADMIN=${ORACLE_HOME}/network/admin
export TNS_ADMIN
PATH=$ORACLE_HOME/bin:$PATH:.
export PATH
}

For Node 2,

prod()
{
ORACLE_HOME=/u01/app/oracle/product/12.1.0.2/db_1
export ORACLE_HOME
ORACLE_BASE=/oracle/app/oracle
export ORACLE_BASE
ORACLE_SID=prod2
export ORACLE_SID
LD_LIBRARY_PATH=$ORACLE_HOME/lib:/usr/lib:.
export LD_LIBRARY_PATH
LIBPATH=$ORACLE_HOME/lib32:$ORACLE_HOME/lib:/usr/lib:/lib
export LIBPATH
TNS_ADMIN=${ORACLE_HOME}/network/admin
export TNS_ADMIN
PATH=$ORACLE_HOME/bin:$PATH:.
export PATH
}

Grid Env :-

For Node 1,

grid()
{
ORACLE_BASE=/u01/app/oracle; export ORACLE_BASE
ORACLE_HOME=/u01/app/12.1.0.2/grid; export ORACLE_HOME
export ORACLE_SID=+ASM1
ORACLE_TERM=xterm; export ORACLE_TERM
BASE_PATH=/usr/sbin:$PATH; export BASE_PATH
SQLPATH=/u01/app/oracle/scripts/sql:/u01/app/12.1.0.2/grid/rdbms/admin:/u01/app/oracle/product/12.1.0.2/db_1/rdbms/admin; export SQLPATH
PATH=$ORACLE_HOME/bin:$BASE_PATH; export PATH
LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib; export LD_LIBRARY_PATH
CLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib; export CLASSPATH
}

For Node 2,

grid()
{
ORACLE_BASE=/u01/app/oracle; export ORACLE_BASE
ORACLE_HOME=/u01/app/12.1.0.2/grid; export ORACLE_HOME
export ORACLE_SID=+ASM2
ORACLE_TERM=xterm; export ORACLE_TERM
BASE_PATH=/usr/sbin:$PATH; export BASE_PATH
SQLPATH=/u01/app/oracle/scripts/sql:/u01/app/12.1.0.2/grid/rdbms/admin:/u01/app/oracle/product/12.1.0.2/db_1/rdbms/admin; export SQLPATH
PATH=$ORACLE_HOME/bin:$BASE_PATH; export PATH
LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib; export LD_LIBRARY_PATH
CLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib; export CLASSPATH
}

Steps to Upgrade the OPATCH UTILITY:-

Step 1:- Check the opatch version and inventory for ORACLE_HOME on both nodes

For Node 1,

opatch version

opatch lsinventory

For Node 2,

opatch version

opatch lsinventory

Step 2:-Check the opatch version and inventory for GRID HOME on both nodes

For Node 1,

opatch version

opatch lsinventory

For Node 2,

opatch version

opatch lsinventory

Step 3:- Update the opatch utility

Take the backup of OPatch directory from GRID and ORACLE_HOME on both nodes

Unzip the OPatch downloaded zip into GRID and ORACLE_HOME directory

For Grid home:

For Database home:

For Node 1,

Copy patch p6880880_122010_Linux-x86-64.zip to the node 2(racpb2) or Copy the unzipped OPatch folder to the node 2(racpb2).

For Node 2,

After copying to Node 2,check the new OPatch version in both GRID and ORACLE_HOME,

After upgrade the OPatch utility on both nodes apply the GRID and ORACLE_HOME PSU patches.

Step 4:- Validation of Oracle Inventory 

To check the GRID HOME inventory :-

opatch lsinventory -detail -oh /u01/app/12.1.0.2/grid

Before beginning patch application, check the consistency of inventory information for GI home and each database home to be patched

To check the ORACLE_HOME inventory :-

opatch lsinventory -detail -oh $ORACLE_HOME

Step 5:- Download and Unzip the Oct 18 PSU Rolling Patch

Step 6:- Check Patch Conflict Detection and Resolution 

For GRID HOME,

When using OPatch 12.2.0.1.5 or later, the following Opatch Option -ocmrf <ocm response file> does not need to be provided.

Now our current OPatch version for GRID and ORACLE_HOME  is 12.2.0.1.16.

As root user,

/u01/app/12.1.0.2/grid/OPatch/opatchauto apply /mnt/hgfs/E/roll_patch/28349311 -analyze -oh /u01/app/12.1.0.2/grid

For ORACLE HOME,

Step 7:- Apply the patch using Opatchauto

OPatchauto automatically patch the typical Grid Infrastructure (GI) and RAC home directories with minimal intervention.

In general, when we invoke opatchauto will patch both the GI stack and the database software stack. Since we have mentioned the -oh it will apply the PSU to the specified home.

The main advantage of opatchauto utility was automatically down the CRS and database services and restart the services after apply patching.

To apply a patch using opatchauto,we need to run as a root user.

To patch the GI home and all Oracle RAC database homes of the same version:

# opatchauto apply /u01/28349311

Here,we are going to apply a patch separately for both GRID and ORACLE_HOME in both nodes.

opatchauto for GRID HOME on Node1 :-

/u01/app/12.1.0.2/grid/OPatch/opatchauto apply /mnt/hgfs/E/roll_patch/28349311 -oh /u01/app/12.1.0.2/grid

opatchauto for ORACLE_HOME on Node 1 :-

/u01/app/oracle/product/12.1.0.2/db_1/OPatch/opatchauto apply /mnt/hgfs/E/roll_patch/27468957 -oh/u01/app/oracle/product/12.1.0.2/db_1

Follow the same Step 7 for applying patch using opatchauto for GRID HOME and ORACLE_HOME  in Node 2.

Rolling PSU patch (Oct 2018)  is applied on both GRID and ORACLE_HOME successfully.

DATAPATCH :-

  •  Datapatch is the new tool that enables automation of post-patch SQL actions for RDBMS patches. So, In 12c you don’t use carbundle psu apply now this is all done using datapatch.
  • OPatchAuto calls datapatch to complete post patch actions upon installation of the binary patch and restart of the database.

Step 8:- To check the Oct PSU 2018 applied to your database using the following SQL statement,

Check the DBA_REGISTRY_SQLPATCH :-

select BUNDLE_SERIES,PATCH_UID,PATCH_ID,
VERSION,ACTION,STATUS,ACTION_TIME ,DESCRIPTION
from dba_registry_sqlpatch;

 

Catch Me On:- Hariprasath Rajaram

LinkedIn:https://www.linkedin.com/in/hari-prasath-aa65bb19/
Facebook:https://www.facebook.com/HariPrasathdba
FB Group:https://www.facebook.com/groups/894402327369506/
FB Page: https://www.facebook.com/dbahariprasath/?
Twitter:  https://twitter.com/hariprasathdba