1、将数据库和监听程序关闭
2、首先检查OPatch版本是否符合要求:
$ORACLE_HOME/OPatch/opatch lsinventory
3、若不符合要求,需先更新opatch:
mv 掉原有的OPatch目录
mv $ORACLE_HOME/OPatch $ORACLE_HOME/OPatchbak
cp p6880880_112000_SOLARIS64-opatch11.2.0.3.12.zip $ORACLE_HOME/
bash-3.2$ unzip p6880880_112000_SOLARIS64-opatch11.2.0.3.12.zip
$ORACLE_HOME/OPatch/opatch lsinventory
Oracle Interim Patch Installer version 11.2.0.3.12
Copyright (c) 2016, Oracle Corporation. All rights reserved.
Oracle Home : /orahome10g/oracle/product/11.2.0
Central Inventory : /orahome/oraInventory
from : /orahome10g/oracle/product/11.2.0/oraInst.loc
OPatch version : 11.2.0.3.12
OUI version : 11.2.0.4.0
Log file location : /orahome10g/oracle/product/11.2.0/cfgtoollogs/opatch/opatch2016-04-22_17-06-13PM_1.log
4、开始安装PSU补丁:
进入安装目录,使用OPatch进行更新
unzip p22502456_112040_
.zip
cd 22502456
$ORACLE_HOME/OPatch/opatch apply
启动数据库,确定更新成功
cd $ORACLE_HOME/rdbms/admin
sqlplus /nolog
SQL> CONNECT / AS SYSDBA
SQL> STARTUP
SQL> @catbundle.sql psu apply
SQL> QUIT
若出现失效对象,可进行编译
cd $ORACLE_HOME/rdbms/admin
sqlplus /nolog
SQL> CONNECT / AS SYSDBA
SQL> @utlrp.sql
通过OPatch的信息库记录,可以看到补丁信息
$ORACLE_HOME/OPatch/opatch lsinventory
在dba_registry_history中,我们也可以看到记录
select version, id, bundle_series, comments from dba_registry_history
SQL> col comments for a40
SQL> r
1 select version, id, bundle_series, comments from dba_registry_history
2*
VERSION ID BUNDLE_SERIES COMMENTS
------------------------------ ---------- ------------------------------ ----------------------------------------
11.2.0.4 0 PSU Patchset 11.2.0.2.0
11.2.0.4 160419 PSU PSU 11.2.0.4.160419
SQL>
阅读(4096) | 评论(0) | 转发(0) |