Oracle 11g update PSU detailed steps
Oracle releases the latest patches every quarter. For production O & M personnel, regular system upgrade and patching are indispensable in daily work.
Compared with the previous versions, Oracle patching has become relatively simple, and the method for processing PSU has also changed. In the 11g environment, we can use the OPatch tool to fix minor bugs. For major version upgrades, Oracle PSU is actually a series of all-new installation files, which can be directly installed after being downloaded from MOS.
1. Shut down the database
Upgrading the Oracle PSU does not update the data dictionary, which is less risky. However, you still need to stop the database for upgrade.
SQL> shutdown immediate
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL> exit
Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.4.0-64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
Stop the listening service.
[Oracle @ bntjftest 20299015] $ lsnrctl stop
Check service process
[Oracle @ bntjftest 20299015] $ ps aux | grep ora _
Oracle 6922 0.0 0.0 5700 796 pts/3 S + grep ora _
[Oracle @ bntjftest 20299015] $ ps aux | grep tns
Oracle 6924 0.0 0.0 5704 796 pts/3 S + grep tns
2. Check the opatch version information and upgrade it if necessary.
[Oracle @ bntjftest OPatch] $./opatch version
OPatch Version: 11.2.0.1.7
OPatch succeeded.
Check that the opatch version is earlier than the default version, so you need to upgrade opatch. The upgrade method is very simple. simply drop the original opatch directory and decompress the latest version of opatch to ORACLE_HOME.
[Oracle @ bntjftest OPatch] $ unzip p6880880_112000_Linux-x86-64-opatch. zip-d $ ORACLE_HOME
Check the version again and find that the upgrade is successful.
[Oracle @ bntjftest OPatch] $./opatch version
OPatch Version: 11.2.0.3.6
OPatch succeeded.
3. Apply the PSU patch
1) Episode 1: installation program error
[Oracle @ bntjftest OPatch] $./opatch apply./20299015/
Oracle Interim Patch Installer version 11.2.0.3.6
Copyright (c) 2013, Oracle Corporation. All rights reserved.
Oracle Home:/app/oracle/product/11.2.0/dbhome_1
Central Inventory:/app/oraInventory
From:/app/oracle/product/11.2.0/dbhome_1/oraInst. loc
OPatch version: 11.2.0.3.6
OUI version: 11.2.0.4.0
Log file location:/app/oracle/product/11.2.0/dbhome_1/export toollogs/opatch/opatch2015-05-14_10-45-03AM_1.log
Verifying environment and padding Ming prerequisite checks...
Prerequisite check "CheckPatchApplicableOnCurrentPlatform" failed.
The details are:
Patch (20299015) is not applicable> UtilSession failed: Prerequisite check "CheckActiveFilesAndExecutables" failed.
Log file location:/app/oracle/product/11.2.0/dbhome_1/export toollogs/opatch/opatch2015-05-14_10-45-03AM_1.log
OPatch failed with error code 73
If you do not use the automatic mode and run it manually, an error is returned:
[Oracle @ bntjftest 20299015] $/app/oracle/product/11.2.0/dbhome_1/OPatch/opatch napply-skip_subset-skip_duplicate
Oracle Interim Patch Installer version 11.2.0.3.6
Copyright (c) 2013, Oracle Corporation. All rights reserved.
Oracle Home:/app/oracle/product/11.2.0/dbhome_1
Central Inventory:/app/oraInventory
From:/app/oracle/product/11.2.0/dbhome_1/oraInst. loc
OPatch version: 11.2.0.3.6
OUI version: 11.2.0.4.0
Log file location:/app/oracle/product/11.2.0/dbhome_1/export toollogs/opatch/opatch2015-05-14_10-45-03AM_1.log
Verifying environment and padding Ming prerequisite checks...
Prerequisite check "CheckPatchApplicableOnCurrentPlatform" failed.
The details are:
Patch (20299015) is not applicable> UtilSession failed: Prerequisite check "CheckActiveFilesAndExecutables" failed.
Log file location:/app/oracle/product/11.2.0/dbhome_1/export toollogs/opatch/opatch2015-05-14_10-45-03AM_1.log
OPatch failed with error code 73
Internet baidu, "UtilSession failed: Prerequisite check" CheckActiveFilesAndExecutables "failed", and soon found the solution. It is clear that a user process occupies the file libclntsh. so.11.
[Oracle @ bntjftest 20299015] $/sbin/fuser/app/oracle/product/11.2.0/dbhome_1/lib/libclntsh. so.11. 1
/App/oracle/product/11.2.0/dbhome_1/lib/libclntsh. so.11.1: 16470 m
[Oracle @ bntjftest 20299015] $ ps-ef | grep 16470
Oracle 16470 5399 0 00:00:00 pts/2 sqlplus as sysdba
Oracle 7780 6617 0 00:00:00 pts/3 grep 16470
[Oracle @ bntjftest 20299015] $ kill-9 16470
[Oracle @ bntjftest 20299015] $/sbin/fuser/app/oracle/product/11.2.0/dbhome_1/lib/libclntsh. so.11.1
3) apply the PSU patch again.
[Oracle @ bntjftest 20299015] $/app/oracle/product/11.2.0/dbhome_1/OPatch/opatch napply-skip_subset-skip_duplicate
Oracle Interim Patch Installer version 11.2.0.3.6
Copyright (c) 2013, Oracle Corporation. All rights reserved.
Oracle Home:/app/oracle/product/11.2.0/dbhome_1
Central Inventory:/app/oraInventory
From:/app/oracle/product/11.2.0/dbhome_1/oraInst. loc
OPatch version: 11.2.0.3.6
OUI version: 11.2.0.4.0
Log file location:/app/oracle/product/11.2.0/dbhome_1/export toollogs/opatch/opatch2015-05-14_10-45-03AM_1.log
Verifying environment and padding Ming prerequisite checks...
OPatch continues with these patches: [17811429 17811438 17811447 18203835 18203837 18203838 19463893 19544839 19584068 19972564 19972566 19972568 19972569 20142975 20299015]
Do you want to proceed? [Y | n]
Y
User Responded with: Y
All checks passed.
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
OPatch Session completed with warnings.
Log file location:/app/oracle/product/11.2.0/dbhome_1/export toollogs/opatch/opatch2015-05-14_10-45-03AM_1.log
OPatch completed with warnings.
4. Check the results after the application
[Oracle @ bntjftest 20299015] $ ../opatch lspatches
20631274;
20506715;
20506699;
20299015;
20142975;
19972569;
19972568;
19972566;
19972564;
19584068;
19544839;
19463893;
18203838;
18203837;
18203835;
17811447;
17811438;
17811429;
[Oracle @ bntjftest 20299015] $ ../opatch lsinventory
Oracle Interim Patch Installer version 11.2.0.3.6
Copyright (c) 2013, Oracle Corporation. All rights reserved.
Oracle Home:/app/oracle/product/11.2.0/dbhome_1
Central Inventory:/app/oraInventory
From:/app/oracle/product/11.2.0/dbhome_1/oraInst. loc
OPatch version: 11.2.0.3.6
OUI version: 11.2.0.4.0
Log file location:/app/oracle/product/11.2.0/dbhome_1/export toollogs/opatch/opatch2015-05-14_11-04-15AM_1.log
Lsinventory Output file location:/app/oracle/product/11.2.0/dbhome_1/export toollogs/opatch/lsinv/lsinventory2015-05-14_11-04-15AM.txt
--------------------------------------------------------------------------------
Installed Top-level Products (1 ):
Oracle Database 11g 11.2.0.4.0
There are 1 product (s) installed in this Oracle Home.
Interim patches (18 ):
Patch 20631274: applied on Wed May 13 17:11:06 CST 2015
Unique Patch ID: 18695736
Created on 13 Mar 2015, 10:25:35 hrs PST8PDT
Bugs fixed:
20296213,176 00719, 19458377,195 54106, 20631274,165 24926, 19466309
Patch 20506715: applied on Wed May 13 17:11:02 CST 2015
Unique Patch ID: 18695736
Created on 13 Mar 2015, 10:23:10 hrs PST8PDT
Bugs fixed:
19049453,199 15271, 16450169,170 06570, 17811456,185 54871, 17786278
18096714,187 44139, 20506715,180 61914
Patch 20506699: applied on Wed May 13 17:10:57 CST 2015
Unique Patch ID: 18695736
Created on 13 Mar 2015, 11:23:48 hrs PST8PDT
Bugs fixed:
20506699,193 58317, 19197175,199 17762296
Patch 20299015: applied on Wed May 13 17:10:54 CST 2015
Unique Patch ID: 18695736
Created on 13 Mar 2015, 10:28:05 hrs PST8PDT
Bugs fixed:
20299015,181 1000090, 18681862,173 43514, 19727057,192 71443, 19854503,175 51709
Patch 20142975: applied on Wed May 13 17:10:53 CST 2015
Unique Patch ID: 18406185
Created on 22 Dec 2014, 00:47:05 hrs PST8PDT
Bugs fixed:
19827973,194 63897, 19289642,201 42975
Patch 19972569: applied on Wed May 13 17:10:51 CST 2015
Unique Patch ID: 18406185
Created on 22 Dec 2014, 00:21:09 hrs PST8PDT
Bugs fixed:
19972569,190 06849
Patch 19972568: applied on Wed May 13 17:10:50 CST 2015
Unique Patch ID: 18406185
Created on 22 Dec 2014, 00:13:36 hrs PST8PDT
Bugs fixed:
19972568,193
Patch 19972566: applied on Wed May 13 17:10:48 CST 2015
Unique Patch ID: 18406185
Created on 22 Dec 2014, 00:03:20 hrs PST8PDT
Bugs fixed:
19972566,186 41461, 18641451
Patch 19972564: applied on Wed May 13 17:10:45 CST 2015
Unique Patch ID: 18406185
Created on 21 Dec 2014, 23:54:58 hrs PST8PDT
Bugs fixed:
19972564,184 12747
Patch 19584068: applied on Wed May 13 17:10:43 CST 2015
Unique Patch ID: 18084194
Created on 24 Sep 2014, 07:43:52 hrs PST8PDT
Bugs fixed:
18262334,195 84068
Patch 19544839: applied on Wed May 13 17:10:40 CST 2015
Unique Patch ID: 18084194
Created on 11 Oct 2014, 01:43:34 hrs PST8PDT
Bugs fixed:
18673325,195 44839, 19211724,186 73304
Patch 19463893: applied on Wed May 13 17:10:26 CST 2015
Unique Patch ID: 18084194
Created on 24 Sep 2014, 06:28:06 hrs PST8PDT
Bugs fixed:
19463893,186 41419
Patch 18203838: applied on Wed May 13 17:10:24 CST 2015
Unique Patch ID: 17351342
Created on 26 Feb 2014, 23:57:58 hrs PST8PDT
Bugs fixed:
17865671,182 03838
Patch 18203837: applied on Wed May 13 17:10:21 CST 2015
Unique Patch ID: 17351342
Created on 26 Feb 2014, 23:48:38 hrs PST8PDT
Bugs fixed:
17716305,182 03837
Patch 18203835: applied on Wed May 13 17:10:19 CST 2015
Unique Patch ID: 17351342
Created on 26 Feb 2014, 23:43:04 hrs PST8PDT
Bugs fixed:
17721717,182 03835
Patch 17811447: applied on Wed May 13 17:10:17 CST 2015
Unique Patch ID: 17066906
Created on 11 Dec 2013, 02:20:51 hrs PST8PDT
Bugs fixed:
17811447,170 88068
Patch 17811438: applied on Wed May 13 17:10:15 CST 2015
Unique Patch ID: 17066906
Created on 11 Dec 2013, 02:37:11 hrs PST8PDT
Bugs fixed:
17811438,167 21594
Patch 17811429: applied on Wed May 13 17:10:13 CST 2015
Unique Patch ID: 17066906
Created on 11 Dec 2013, 02:36:54 hrs PST8PDT
Bugs fixed:
17811429,139 44971
--------------------------------------------------------------------------------
OPatch succeeded.
SQL> select * from dba_registry_history;
ACTION_TIME ACTION NAMESPAC VERSION ID BUNDL COMMENTS
-------------------------------------------------------------------------------------------
05-MAY-15 09.24.08.184589 am apply server 11.2.0.4 0 PSU Patchset 11.2.0.2.0
13-MAY-15 05.17.48.578053 pm apply server 11.2.0.4 6 CPU CPUApr2015
2 rows selected.