Apply 2016 PSU 22191676 to a Grid / Oracle Stand Alone 12.1.0.2 Using opatchauto

Overview

Here is the process I used to apply the Oracle 2016 PSU 22191676 to Grid / Oracle Stand Alone 12.1.0.2 environment using opatchauto.  Effectively bringing the environment to 12.1.0.2.6 (12.1.0.2.160119)
My environment has a 12.1.0.2.0 database ASM based standalone database – installed an administered with the grid infrastructure / ASM / listener owned by the Linux user grid, and the Oracle 12.1.0.2 database owned by the Linux oracle user.
Here is the .bash profile and groups each account belongs to:

grid Linux account info:

[grid@prim12102 Desktop]$ id
uid=54322(grid) gid=54321(oinstall) groups=54321(oinstall),54322(dba),54327(asmdba),54328(asmoper),54329(asmadmin)
[grid@prim12102 ~]$ cat .bash_profile
# .bash_profile
# Get the aliases and functions
if [ -f ~/.bashrc ]; then
. ~/.bashrc
fi
# User specific environment and startup programs
ORACLE_SID=+ASM
export ORACLE_SID
ORACLE_HOME=/u01/app/grid/product/12.1.0/grid
export ORACLE_HOME
PATH=$ORACLE_HOME/bin:$PATH:$HOME/bin
export PATH
# User specific environment and startup programs
ORACLE_SID=+ASM
export ORACLE_SID
ORACLE_HOME=/u01/app/grid/product/12.1.0/grid
export ORACLE_HOME
PATH=$ORACLE_HOME/bin:$PATH:$HOME/bin

oracle Linux account info:

[oracle@prim12102 patches]$ id
uid=54321(oracle) gid=54321(oinstall) groups=54321(oinstall),54322(dba),54323(oper),54327(asmdba)
[oracle@prim12102 ~]$ cat .bash_profile
# .bash_profile
# Get the aliases and functions
if [ -f ~/.bashrc ]; then
. ~/.bashrc
fi
# User specific environment and startup programs
export ORACLE_SID=orcl
export ORACLE_BASE=/u01/app/oracle
export ORACLE_HOME=/u01/app/oracle/product/12.1.0/dbhome_1
PATH=$PATH:$ORACLE_HOME/bin:$HOME/bin
Down load patch p22191676_121020_Linux-x86-64.zip from Oracle Support.

Make sure you have opatch 12.1.0.9 at least via patch 6880880

This you put in place by renaming you existing OPatch directory to something else and unzipping this patch – do this for both the grid home and the oracle home
cp p6880880_121010_Linux-x86-64.zip $ORACLE_HOME
unzip p6880880_121010_Linux-x86-64.zip

Create a patch directory for patch 22191676 and extract the zip to it

mkdir /patches
cd /patches
copy the zip into the dir and unzip
# the unix users root, oracle, and grid need read & write on this directory
chmod -R 777 /patches
 
I change the parent directory – 22191676 – on down to be accessible to every one – as usually oracle owns patches but in this case root runs the patch.

 ls -al
drwxrwxrwx 8 root root 4096 Jan 24 23:48 22191676
-rwxr-x— 1 root root 1289605017 Feb 13 07:59 p22191676_121020_Linux-x86-64.zip

Create an opatchauto response file as follows

From the oracle Linux user (can use either oracle or grid user):

$ORACLE_HOME/OPatch/ocm/bin/emocmrsp -no_banner -output /tmp/file.rsp

[oracle@stby12102 OPatch]$ $ORACLE_HOME/OPatch/ocm/bin/emocmrsp -no_banner -output /tmp/file.rsp
Provide your email address to be informed of security issues, install and
initiate Oracle Configuration Manager. Easier for you if you use your My
Oracle Support Email address/User Name.
Visit http://www.oracle.com/support/policies.html for details.
Email address/User Name:
You have not provided an email address for notification of security issues.
Do you wish to remain uninformed of security issues ([Y]es, [N]o) [N]: Y
The OCM configuration response file (/tmp/file.rsp) was successfully created.
[oracle@stby12102 OPatch]$
 

Run opatchauto

Shut down

from oracle: srvctl stop database -d orcl
from grid: srvctl stop asm -f
from grid: srvctl stop listener
Ensure that you have enough disk space for the Jan 2016 PSU!!
Although the patch is around 12000 MB, when we unzip the patch it occupies over 3 GB of disk space. In addition the patch application requires over 13 GB of free disk space on the Grid Infrastructure home and over 6 GB of free space for the Database home.
The patch will fail if not enough space is available.
Analyze both grid and database environments before applying patch – notice we are running a root
from root
cd  /u01/app/grid/product/12.1.0/grid/OPatch
./opatchauto apply /home/oracle/patches/22191676 -analyze -ocmrf /tmp/file.rsp -oh /u01/app/grid/product/12.1.0/grid
 
./opatchauto apply /home/oracle/patches/22191676 -analyze -ocmrf /tmp/file.rsp -database orcl

Apply the patch

[root@rac1 OPatch]# ./opatchauto apply /home/oracle/patches/22191676 -ocmrf /tmp/file.rsp
 
 

Leave a Comment

Scroll to Top