Steps
1. Download the latest 12.1 version of opatch patch 6880880 and unzip to all 12.1 homes as corresponding owner.
In this example, the downloaded opatch zip is located in /home/grid/tmp/p6880880_121010_Linux-x86-64.zip
As grid user:
$ unzip -d /ocw/c101 /home/grid/tmp/p6880880_121010_Linux-x86-64.zip
As oracle user:
$ unzip -d /home/oracle/app/oracle/product/12.1/c101 /home/grid/tmp/p6880880_121010_Linux-x86-64.zip
Note: since DB home2 is not 12.1.0.1, do not unzip the 12.1 opatch version into that home.
2. Create OCM response file if it does not exist.
OCM Response file has two default locations: <ORACLE_HOME>/OPatch/ocm.rsp or <ORACLE_HOME>/OPatch/ocm/bin/ocm.rsp
In this example, the response file will be created in the second default location.
As grid user:
$ cd /ocw/c101/OPatch/ocm/bin $ ./emocmrsp
Once created, verify with the following command:
$ cd /ocw/c101/OPatch/ocm/bin $ ls -l .. -rwxr—– 1 grid oinstall 9063 Nov 26 2009 emocmrsp -rw-r–r– 1 grid oinstall 621 Oct 21 15:03 ocm.rsp
3. Download the PSU and unzip as grid user.
GI PSU can be big, ensure sufficient space in the patch stage area.
In this example, the downloaded PSU patch is located in /home/grid/tmp/p17272829_121010_Linux-x86-64.zip
Unzip as grid user:
$ cd /home/grid/tmp $ unzip /home/grid/tmp/p17272829_121010_Linux-x86-64.zip
To verify:
$ cd /home/grid/tmp $ ls -ld 17272829 drwxr-xr-x 6 grid oinstall 4096 Oct 14 05:53 17272829 $ ls -l 17272829 total 84 drwxr-xr-x 4 grid oinstall 4096 Oct 14 05:42 17027533 drwxr-xr-x 5 grid oinstall 4096 Oct 14 05:41 17077442 drwxr-xr-x 5 grid oinstall 4096 Oct 14 05:42 17303297 drwxr-xr-x 2 grid oinstall 4096 Oct 14 05:42 automation -rw-rw-r– 1 grid oinstall 4155 Oct 14 06:43 bundle.xml -rw-rw-r– 1 grid oinstall 51472 Oct 15 09:14 README.html -rw-r–r– 1 grid oinstall 21 Oct 14 05:53 README.txt
4. Execute opatchauto command
In this example, opatchauto command will apply to both GI and RAC home
Note:
1. There’s no need to stop GI prior to running the opatchauto command. If GI needs to be stopped prior to running opatchauto command for business reason, refer to note 1597085.1 for non-rolling example.
2. If no database is registered in OCR for a RAC home, the home will not be patched.
As root user:
# cd /home/grid/tmp/17272829 # /ocw/c101/OPatch/opatchauto apply /home/grid/tmp/17272829 OPatch Automation Tool Copyright (c) 2013, Oracle Corporation. All rights reserved.
OPatchauto version : 12.1.0.1.2 OUI version : 12.1.0.1.0 Running from : /ocw/c101
opatchauto log file: /ocw/c101/cfgtoollogs/opatchauto/17272829/opatch_gi_2013-10-21_16-07-22_deploy.log
Parameter Validation: Successful
Grid Infrastructure home: /ocw/c101 RAC home(s): /home/oracle/app/oracle/product/12.1/c101 Following home(s) are not patchable as its version is less than 12.1.0.0.0: /home/oracle/app/oracle/product/11.2/b204
Configuration Validation: Successful
Patch Location: /mnt/OP/C101GIPSU1/17272829 Grid Infrastructure Patch(es): 17027533 17077442 17303297 RAC Patch(es): 17027533 17077442
Patch Validation: Successful
Stopping RAC (/home/oracle/app/oracle/product/12.1/c101) … Successful
Applying patch(es) to “/home/oracle/app/oracle/product/12.1/c101” … Patch “/mnt/OP/C101GIPSU1/17272829/17027533” successfully applied to “/home/oracle/app/oracle/product/12.1/c101”. Patch “/mnt/OP/C101GIPSU1/17272829/17077442” successfully applied to “/home/oracle/app/oracle/product/12.1/c101”.
Stopping CRS … Successful
Applying patch(es) to “/ocw/c101” … Patch “/mnt/OP/C101GIPSU1/17272829/17027533” successfully applied to “/ocw/c101”. Patch “/mnt/OP/C101GIPSU1/17272829/17077442” successfully applied to “/ocw/c101”. Patch “/mnt/OP/C101GIPSU1/17272829/17303297” successfully applied to “/ocw/c101”.
Starting CRS … Successful
Starting RAC (/home/oracle/app/oracle/product/12.1/c101) … Successful
SQL changes, if any, are applied successfully on the following database(s): dc101
Apply Summary: Following patch(es) are successfully installed: GI Home: /ocw/c101: 17027533, 17077442, 17303297 RAC Home: /home/oracle/app/oracle/product/12.1/c101: 17027533, 17077442
opatchauto succeeded.
At this point, for GI Standalone environment, the patching is done. For GI Cluster environment, repeat the same on other nodes.
Above example will apply to both GI and DB home, to apply to either GI or DB home only, use the “-oh” option, i.e.:
# cd /home/grid/tmp/17272829 # /ocw/c101/OPatch/opatchauto apply /home/grid/tmp/17272829 -oh <GI_HOME>
OR
# cd /home/grid/tmp/17272829 # copy OCM response file from <GI_HOME>/OPatch/ocm/bin/ocm.rsp to <DB_HOME>/OPatch/ocm/bin # <DB_HOME>/OPatch/opatchauto apply /home/grid/tmp/17272829 -oh <DB_HOME>
Log file location
Each opatchauto session will create the following 5 files in <GI_HOME>/cfgtoollogs/opatchauto/<patch>/
In this example, the following logs were created:
-rw-r–r– 1 grid oinstall 11083 Oct 21 16:07 opatch_gi_2013-10-21_16-07-22_config.xml -rw-r–r– 1 grid oinstall 224 Oct 21 16:07 opatch_gi_2013-10-21_16-07-22_deploy.cfg.log -rw-r–r– 1 grid oinstall 21289 Oct 21 16:22 opatch_gi_2013-10-21_16-07-22_deploy.debug.log -rw-r–r– 1 grid oinstall 5190 Oct 21 16:22 opatch_gi_2013-10-21_16-07-22_deploy.log -rw-r–r– 1 grid oinstall 1537 Oct 21 16:20 opatch_gi_2013-10-21_16-07-22_deploy.steps.log
Each opatchauto will execute opatch command multiple times and create files in <GI_HOME>/cfgtoollogs/opatch/ and <DB_HOME>/cfgtoollogs/opatch/
Comments