给11gr2数据库穿上防弹衣-记一次打PSU(Patch Set Update)全过程

SYSTEM 版本:/IBM POWER 7/AIX 6.1 64bit/ 内存120G/ CPU16*4 /

DATABASE 版本:11.2.0.3

GI INFRASTRUCTURE CLUSTER版本: 11.2.0.3

PSU(Patch Set Update)版本:最新的11.2.0.3.4

下面是打PSU(Patch Set Update)全过程

[@more@]

一.说明:

1 下面的操作是在完成了GI INFRASTRUCTURE 的安装、DB DATABASE的安装、ASM的创建、DBCA建库的情况下进行的手动滚动升级(rolling patch)的过程.PSU README说明:GI PSU patches can be installed in an Oracle RAC rolling fashion. 如何进行滚动升级、查看方式也可查看DBARoad的《What is rolling patch》链接:http://www.dbaroad.me/archives/2010/03/rolling_patch.html

2 补丁程序14275572: GRID INFRASTRUCTURE PATCH SET UPDATE 11.2.0.3.4 (INCLUDES DB PSU 11.2.0.3.4).即DB DATABASE PATCH SET UPDATE 11.2.0.3.4的补丁程序14275605包含在补丁程序14275572,当补丁程序14275572解压的时候,会释出两个补丁包:14275572与14275605.我们只需要在metalink上下载补丁程序14275572即可.

3 根据读取psu readme,需要的OPatch程序为11.2.0.3或以上.获取方式通过在metalink"补丁程序和更新程序"右下边的方框输入6880880进入搜索

4.下载的补丁程序以及OPatch程序:

p14275572_112030_AIX64-5L.zip

p6880880_112000_AIX64-5L.zip

需要注意的:强烈推荐在使用PSU之前对该补丁程序进行checksum,保证补丁程序 是正常可以使用的,因为你在拷贝、上传、ftp这些补丁程序的时候,会发生一些不可预见的错误.

5. 11.2.0.3之后,oracle提供了opatch auto自动打补丁的功能(我自己实施过,自动patch也打成功了),但本篇我们使用手动的方式进程升级.

6.详细情况请参阅PSU README 《Patch 14275572 - 11.2.0.3.4 GI Patch Set Update (Includes Database PSU 11.2.0.3.4)》

二、下面我们开始OPATCH PSU MANUAL的旅程

首先在节点1进行:

1.Patch Installation Prerequisites(预安装环境检查)

You must use the OPatch utility version 11.2.0.3.0 or later to apply this patch. opatch的版本最少11.2.0.3

$ jar -xvf p6880880_112000_AIX64-5L.zip

$ /OPatch/opatch version


在每个节点的ORACLE RAC DATABASE HOME和GI HOME进行检查opatch版本是否11.2.0.3以上,如果不是,则在每个节点的ORACLE RAC DATABASE HOME和GI HOME进行下面的动作:

使用11.2.0.3或以上的OPatch覆盖旧的OPatch,在覆盖之前推荐先复制旧的OPatch

2.在apply patch之前在先在 GI home and each database home 检查先前的补丁安装的补丁是否一致.

$ /OPatch/opatch lsinventory -detail -oh

3.Unzipping the Patch

下载的patch 目录为

cd
jar -xvf p14275572_112030_AIX64-5L.zip

chmod -R 777 14275572 (推荐)

chmod -R 777 14275605 (推荐)

chown -R oracle:oinstall 14275572(推荐)

chown -R oracle:oinstall 14275605(推荐)

4. 检测补丁是否存在冲突

$ opatch prereq CheckConflictAgainstOHWithDetail -ph /14275605 –oh $GRID_HOME
$ opatch prereq CheckConflictAgainstOHWithDetail -ph /14275605 –oh $DB_HOME
$ opatch prereq CheckConflictAgainstOHWithDetail -phBaseDir /14275572 –oh $GRID_HOME
$ opatch prereq CheckConflictAgainstOHWithDetail -phBaseDir /14275572/custom/server/14275572 –oh $DB_HOME

确保没有补丁检查到冲突

5. Manual Steps for Apply Patch

在patch 之前,首先要停止OEM

$ emctl stop dbconsole

Oracle Enterprise Manager 11g Database Control Release 11.2.0.3.0
Copyright (c) 1996, 2011 Oracle Corporation. All rights
Stopping Oracle Enterprise Manager 11g Database Control ...

Cannot determine Oracle Enterprise Manager 11g Database Control process. /u01/app/oracle/product/11.2.0/dbhome_1/retc1_retc/emctl.pid does not exist.
$ emctl status dbconsole
Oracle Enterprise Manager 11g Database Control Release 11.2.0.3.0
Copyright (c) 1996, 2011 Oracle Corporation. All rights
Oracle Enterprise Manager 11g is not running.

5.1 停止rac数据库
$ /bin/srvctl stop home -o -s -n

使用oracle用户:
$ sqlplus "/as sysdba"

SQL*Plus: Release 11.2.0.3.0 Production on Mon Dec 17 16:04:29 2012

Copyright (c) 1982, 2011, Oracle. All rights reserved.


Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
With the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,
Data Mining and Real Application Testing options

SQL> select open_mode from v$databse;
select open_mode from v$databse
*
ERROR at line 1:
ORA-00942: table or view does not exist


SQL> select open_mode from v$database;

OPEN_MODE
--------------------
READ WRITE

$ srvctl stop home -o /u01/app/oracle/product/11.2.0/dbhome_1 -s /home/oracle/db_satus.txt -n retc1

$ sqlplus "/as sysdba"

SQL*Plus: Release 11.2.0.3.0 Production on Mon Dec 17 16:05:48 2012

Copyright (c) 1982, 2011, Oracle. All rights reserved.

Connected to an idle instance.

SQL> exit
Disconnected
$ pwd
/home/oracle
$ ls
db_satus.txt
$ ls -trl
total 8
-rw-r--r-- 1 oracle oinstall 8 Dec 17 16:05 db_satus.txt
$ cat *.txt
db-retc
$

2.改变grid目录属主

# /crs/install/rootcrs.pl -unlock
使用root用户运行,使用rootcrs.pl -unlock 之前

ls -trl
total 8
drwxr-xr-x 70 root oinstall 4096 Dec 17 14:53 grid

./rootcrs.pl -unlock

Using configuration parameter file: ./crsconfig_params
CRS-2791: Starting shutdown of Oracle High Availability Services-managed resources on 'retc1'
CRS-2673: Attempting to stop 'ora.crsd' on 'retc1'
CRS-2790: Starting shutdown of Cluster Ready Services-managed resources on 'retc1'
CRS-2673: Attempting to stop 'ora.LISTENER_SCAN1.lsnr' on 'retc1'
CRS-2673: Attempting to stop 'ora.LISTENER.lsnr' on 'retc1'
CRS-2673: Attempting to stop 'ora.ARCH.dg' on 'retc1'
CRS-2673: Attempting to stop 'ora.CRS.dg' on 'retc1'
CRS-2673: Attempting to stop 'ora.registry.acfs' on 'retc1'
CRS-2673: Attempting to stop 'ora.DATA.dg' on 'retc1'
CRS-2677: Stop of 'ora.LISTENER.lsnr' on 'retc1' succeeded
CRS-2673: Attempting to stop 'ora.retc1.vip' on 'retc1'
CRS-2677: Stop of 'ora.LISTENER_SCAN1.lsnr' on 'retc1' succeeded
CRS-2673: Attempting to stop 'ora.scan1.vip' on 'retc1'
CRS-2677: Stop of 'ora.scan1.vip' on 'retc1' succeeded
CRS-2672: Attempting to start 'ora.scan1.vip' on 'retc2'
CRS-2677: Stop of 'ora.retc1.vip' on 'retc1' succeeded
CRS-2672: Attempting to start 'ora.retc1.vip' on 'retc2'
CRS-2677: Stop of 'ora.DATA.dg' on 'retc1' succeeded
CRS-2677: Stop of 'ora.ARCH.dg' on 'retc1' succeeded
CRS-2676: Start of 'ora.scan1.vip' on 'retc2' succeeded
CRS-2672: Attempting to start 'ora.LISTENER_SCAN1.lsnr' on 'retc2'
CRS-2676: Start of 'ora.retc1.vip' on 'retc2' succeeded
CRS-2676: Start of 'ora.LISTENER_SCAN1.lsnr' on 'retc2' succeeded
CRS-2677: Stop of 'ora.registry.acfs' on 'retc1' succeeded
CRS-2677: Stop of 'ora.CRS.dg' on 'retc1' succeeded
CRS-2673: Attempting to stop 'ora.asm' on 'retc1'
CRS-2677: Stop of 'ora.asm' on 'retc1' succeeded
CRS-2673: Attempting to stop 'ora.ons' on 'retc1'
CRS-2677: Stop of 'ora.ons' on 'retc1' succeeded
CRS-2673: Attempting to stop 'ora.net1.network' on 'retc1'
CRS-2677: Stop of 'ora.net1.network' on 'retc1' succeeded
CRS-2792: Shutdown of Cluster Ready Services-managed resources on 'retc1' has completed
CRS-2677: Stop of 'ora.crsd' on 'retc1' succeeded
CRS-2673: Attempting to stop 'ora.mdnsd' on 'retc1'
CRS-2673: Attempting to stop 'ora.crf' on 'retc1'
CRS-2673: Attempting to stop 'ora.ctssd' on 'retc1'
CRS-2673: Attempting to stop 'ora.evmd' on 'retc1'
CRS-2673: Attempting to stop 'ora.asm' on 'retc1'
CRS-2673: Attempting to stop 'ora.drivers.acfs' on 'retc1'
CRS-2677: Stop of 'ora.mdnsd' on 'retc1' succeeded
CRS-2677: Stop of 'ora.evmd' on 'retc1' succeeded
CRS-2677: Stop of 'ora.crf' on 'retc1' succeeded
CRS-2677: Stop of 'ora.asm' on 'retc1' succeeded
CRS-2673: Attempting to stop 'ora.cluster_interconnect.haip' on 'retc1'
CRS-2677: Stop of 'ora.cluster_interconnect.haip' on 'retc1' succeeded
CRS-2677: Stop of 'ora.ctssd' on 'retc1' succeeded
CRS-2673: Attempting to stop 'ora.cssd' on 'retc1'
CRS-2677: Stop of 'ora.cssd' on 'retc1' succeeded
CRS-2673: Attempting to stop 'ora.gipcd' on 'retc1'
CRS-2677: Stop of 'ora.gipcd' on 'retc1' succeeded
CRS-2673: Attempting to stop 'ora.gpnpd' on 'retc1'
CRS-2677: Stop of 'ora.drivers.acfs' on 'retc1' succeeded
CRS-2677: Stop of 'ora.gpnpd' on 'retc1' succeeded
CRS-2793: Shutdown of Oracle High Availability Services-managed resources on 'retc1' has completed
CRS-4133: Oracle High Availability Services has been stopped.
Successfully unlock /u01/app/11.2.0/grid

使用rootcrs.pl -unlock 之后

ls -trl
total 8
drwxr-xr-x 70 grid oinstall 4096 Dec 17 14:53 grid

3.appy GI patch

/OPatch/opatch napply -oh -local /14275572

使用grid用户

$opatch napply -oh /u01/app/11.2.0/grid -local /tmp/software/14275572

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

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

Please shutdown Oracle instances running out of this ORACLE_HOME on the local system.
(Oracle Home = '/u01/app/11.2.0/grid')

Is the local system ready for patching? [y|n]
y
User Responded with: Y
Backing up files...
Applying interim patch '14275572' to OH '/u01/app/11.2.0/grid'

Patching component oracle.crs, 11.2.0.3.0...

Copy failed from '/tmp/software/14275572/files/lib/libclsra11.so' to '/u01/app/11.2.0/grid/lib/libclsra11.so'...
Please verify all applications associated with the Oracle Home '/u01/app/11.2.0/grid' are shut down. If this is AIX, please perform solution documented in Note 739963.1 on
https://myoraclesupport.oracle.com.

Do you want to retry copying the file? [y|n]
y
User Responded with: Y

Retry copying the file to '/u01/app/11.2.0/grid/lib/libclsra11.so'.

Copy failed from '/tmp/software/14275572/files/lib/libdbcfg11.so' to '/u01/app/11.2.0/grid/lib/libdbcfg11.so'...
Please verify all applications associated with the Oracle Home '/u01/app/11.2.0/grid' are shut down. If this is AIX, please perform solution documented in Note 739963.1 on
https://myoraclesupport.oracle.com.

Do you want to retry copying the file? [y|n]
y
User Responded with: Y

Retry copying the file to '/u01/app/11.2.0/grid/lib/libdbcfg11.so'.

Copy failed from '/tmp/software/14275572/files/lib/libeons.so' to '/u01/app/11.2.0/grid/lib/libeons.so'...
Please verify all applications associated with the Oracle Home '/u01/app/11.2.0/grid' are shut down. If this is AIX, please perform solution documented in Note 739963.1 on
https://myoraclesupport.oracle.com.

Do you want to retry copying the file? [y|n]
y
User Responded with: Y

Retry copying the file to '/u01/app/11.2.0/grid/lib/libeons.so'.

Copy failed from '/tmp/software/14275572/files/lib/libeonsserver.so' to '/u01/app/11.2.0/grid/lib/libeonsserver.so'...
Please verify all applications associated with the Oracle Home '/u01/app/11.2.0/grid' are shut down. If this is AIX, please perform solution documented in Note 739963.1 on
https://myoraclesupport.oracle.com.

Do you want to retry copying the file? [y|n]
y
User Responded with: Y

Retry copying the file to '/u01/app/11.2.0/grid/lib/libeonsserver.so'.

Copy failed from '/tmp/software/14275572/files/lib/libgns11.so' to '/u01/app/11.2.0/grid/lib/libgns11.so'...
Please verify all applications associated with the Oracle Home '/u01/app/11.2.0/grid' are shut down. If this is AIX, please perform solution documented in Note 739963.1 on
https://myoraclesupport.oracle.com.

Do you want to retry copying the file? [y|n]
y
User Responded with: Y

Retry copying the file to '/u01/app/11.2.0/grid/lib/libgns11.so'.

Copy failed from '/tmp/software/14275572/files/lib/libhasgen11.so' to '/u01/app/11.2.0/grid/lib/libhasgen11.so'...
Please verify all applications associated with the Oracle Home '/u01/app/11.2.0/grid' are shut down. If this is AIX, please perform solution documented in Note 739963.1 on
https://myoraclesupport.oracle.com.

Do you want to retry copying the file? [y|n]
y
User Responded with: Y

Retry copying the file to '/u01/app/11.2.0/grid/lib/libhasgen11.so'.

Copy failed from '/tmp/software/14275572/files/lib/libocr11.so' to '/u01/app/11.2.0/grid/lib/libocr11.so'...
Please verify all applications associated with the Oracle Home '/u01/app/11.2.0/grid' are shut down. If this is AIX, please perform solution documented in Note 739963.1 on
https://myoraclesupport.oracle.com.

Do you want to retry copying the file? [y|n]
y
User Responded with: Y

Retry copying the file to '/u01/app/11.2.0/grid/lib/libocr11.so'.

Copy failed from '/tmp/software/14275572/files/lib/libocrb11.so' to '/u01/app/11.2.0/grid/lib/libocrb11.so'...
Please verify all applications associated with the Oracle Home '/u01/app/11.2.0/grid' are shut down. If this is AIX, please perform solution documented in Note 739963.1 on
https://myoraclesupport.oracle.com.

Do you want to retry copying the file? [y|n]
y
User Responded with: Y

Retry copying the file to '/u01/app/11.2.0/grid/lib/libocrb11.so'.

Copy failed from '/tmp/software/14275572/files/lib/libocrutl11.so' to '/u01/app/11.2.0/grid/lib/libocrutl11.so'...
Please verify all applications associated with the Oracle Home '/u01/app/11.2.0/grid' are shut down. If this is AIX, please perform solution documented in Note 739963.1 on
https://myoraclesupport.oracle.com.

Do you want to retry copying the file? [y|n]
y
User Responded with: Y

Retry copying the file to '/u01/app/11.2.0/grid/lib/libocrutl11.so'.

Patching component oracle.usm, 11.2.0.3.0...

The following actions have failed:
Copy failed from '/tmp/software/14275572/files/lib/libclsra11.so' to '/u01/app/11.2.0/grid/lib/libclsra11.so'...
Copy failed from '/tmp/software/14275572/files/lib/libdbcfg11.so' to '/u01/app/11.2.0/grid/lib/libdbcfg11.so'...
Copy failed from '/tmp/software/14275572/files/lib/libeons.so' to '/u01/app/11.2.0/grid/lib/libeons.so'...
Copy failed from '/tmp/software/14275572/files/lib/libeonsserver.so' to '/u01/app/11.2.0/grid/lib/libeonsserver.so'...
Copy failed from '/tmp/software/14275572/files/lib/libgns11.so' to '/u01/app/11.2.0/grid/lib/libgns11.so'...
Copy failed from '/tmp/software/14275572/files/lib/libhasgen11.so' to '/u01/app/11.2.0/grid/lib/libhasgen11.so'...
Copy failed from '/tmp/software/14275572/files/lib/libocr11.so' to '/u01/app/11.2.0/grid/lib/libocr11.so'...
Copy failed from '/tmp/software/14275572/files/lib/libocrb11.so' to '/u01/app/11.2.0/grid/lib/libocrb11.so'...
Copy failed from '/tmp/software/14275572/files/lib/libocrutl11.so' to '/u01/app/11.2.0/grid/lib/libocrutl11.so'...


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

Verifying the update...
Patch 14275572 successfully applied.
OPatch Session completed with warnings.
Log file location: /u01/app/11.2.0/grid/cfgtoollogs/opatch/opatch2012-12-17_16-18-44PM_1.log

OPatch completed with warnings.

/OPatch/opatch apply -oh -local /14275605


$opatch napply -oh /u01/app/11.2.0/grid -local /tmp/software/14275605

OPatch found the word "warning" in the stderr of the make command.
Please look at this stderr. You can re-run this make command.
Stderr output:
ld: 0711-224 WARNING: Duplicate symbol: .aio_nwait_timeout64
ld: 0711-224 WARNING: Duplicate symbol: aio_nwait_timeout64
ld: 0711-224 WARNING: Duplicate symbol: .aio_nwait64
ld: 0711-224 WARNING: Duplicate symbol: aio_nwait64
ld: 0711-345 Use the -bloadmap or -bnoquiet option to obtain more information.
ld: 0711-773 WARNING: Object /u01/app/11.2.0/grid/lib/libgeneric11.a[sdbgrfu.o], imported symbol timezone
Symbol was expected to be local. Extra instructions
are being generated to reference the symbol.
ld: 0711-783 WARNING: TOC overflow. TOC size: 240960 Maximum size: 65536
Extra instructions are being generated for each reference to a TOC
symbol if the symbol is in the TOC overflow area.

OPatch found the word "warning" in the stderr of the make command.
Please look at this stderr. You can re-run this make command.
Stderr output:
ld: 0711-773 WARNING: Object /u01/app/11.2.0/grid/lib//libgeneric11.a[sdbgrfu.o], imported symbol timezone
Symbol was expected to be local. Extra instructions
are being generated to reference the symbol.


Composite patch 14275605 successfully applied.
OPatch Session completed with warnings.
Log file location: /u01/app/11.2.0/grid/cfgtoollogs/opatch/opatch2012-12-17_16-45-08PM_1.log

OPatch completed with warnings.

4.apply db database home

使用oracle用户

$/14275572/custom/server/14275572/custom/scripts/prepatch.sh -dbhome


$ /tmp/software/14275572/custom/server/14275572/custom/scripts/prepatch.sh -dbhome /u01/app/oracle/product/11.2.0/dbhome_1

/tmp/software/14275572/custom/server/14275572/custom/scripts/prepatch.sh completed successfully.


$ /OPatch/opatch napply -oh -local /14275572/custom/server/14275572


$opatch napply -oh /u01/app/oracle/product/11.2.0/dbhome_1 -local /tmp/software/14275572/custom/server/14275572

Oracle Interim Patch Installer version 11.2.0.3.0
Copyright (c) 2012, Oracle Corporation. All rights reserved.


Oracle Home : /u01/app/oracle/product/11.2.0/dbhome_1
Central Inventory : /u01/app/oraInventory
from : /u01/app/oracle/product/11.2.0/dbhome_1/oraInst.loc
OPatch version : 11.2.0.3.0
OUI version : 11.2.0.3.0
Log file location : /u01/app/oracle/product/11.2.0/dbhome_1/cfgtoollogs/opatch/opatch2012-12-17_16-54-29PM_1.log

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

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

Please shutdown Oracle instances running out of this ORACLE_HOME on the local system.
(Oracle Home = '/u01/app/oracle/product/11.2.0/dbhome_1')


Is the local system ready for patching? [y|n]
y
User Responded with: Y
Backing up files...
Applying interim patch '14275572' to OH '/u01/app/oracle/product/11.2.0/dbhome_1'

Patching component oracle.rdbms, 11.2.0.3.0...

Verifying the update...
Patch 14275572 successfully applied.
Log file location: /u01/app/oracle/product/11.2.0/dbhome_1/cfgtoollogs/opatch/opatch2012-12-17_16-54-29PM_1.log

OPatch succeeded.

$ /OPatch/opatch apply -oh -local /14275605

$opatch apply -oh /u01/app/oracle/product/11.2.0/dbhome_1 -local /tmp/software/14275605

Oracle Interim Patch Installer version 11.2.0.3.0
Copyright (c) 2012, Oracle Corporation. All rights reserved.


Oracle Home : /u01/app/oracle/product/11.2.0/dbhome_1
Central Inventory : /u01/app/oraInventory
from : /u01/app/oracle/product/11.2.0/dbhome_1/oraInst.loc
OPatch version : 11.2.0.3.0
OUI version : 11.2.0.3.0
Log file location : /u01/app/oracle/product/11.2.0/dbhome_1/cfgtoollogs/opatch/opatch2012-12-17_16-58-08PM_1.log

Verifying environment and performing prerequisite checks...
OPatch continues with these patches: 13343438 13696216 13923374 14275605

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

Please shutdown Oracle instances running out of this ORACLE_HOME on the local system.
(Oracle Home = '/u01/app/oracle/product/11.2.0/dbhome_1')


Is the local system ready for patching? [y|n]
y
User Responded with: Y
Backing up files...
Applying sub-patch '13343438' to OH '/u01/app/oracle/product/11.2.0/dbhome_1'

Patching component oracle.rdbms.rsf, 11.2.0.3.0...

Patching component oracle.rdbms, 11.2.0.3.0...

Patching component oracle.rdbms.dbscripts, 11.2.0.3.0...

Verifying the update...
Applying sub-patch '13696216' to OH '/u01/app/oracle/product/11.2.0/dbhome_1'

Patching component oracle.rdbms.rsf, 11.2.0.3.0...

Patching component oracle.rdbms, 11.2.0.3.0...

Patching component oracle.sdo.locator, 11.2.0.3.0...

Patching component oracle.sysman.console.db, 11.2.0.3.0...

Patching component oracle.sysman.oms.core, 10.2.0.4.4...

Verifying the update...
Applying sub-patch '13923374' to OH '/u01/app/oracle/product/11.2.0/dbhome_1'
ApplySession: Optional component(s) [ oracle.network.cman, 11.2.0.3.0 ] not present in the Oracle Home or a higher version is found.

Patching component oracle.rdbms.rsf, 11.2.0.3.0...

Patching component oracle.rdbms, 11.2.0.3.0...

Patching component oracle.rdbms.dbscripts, 11.2.0.3.0...

Patching component oracle.network.rsf, 11.2.0.3.0...

Patching component oracle.network.listener, 11.2.0.3.0...

Patching component oracle.sysman.console.db, 11.2.0.3.0...

.....
.....
Patch found the word "warning" in the stderr of the make command.
Please look at this stderr. You can re-run this make command.
Stderr output:
ld: 0711-415 WARNING: Symbol ldxdts is already exported.
ld: 0711-415 WARNING: Symbol ldxsto is already exported.
ld: 0711-415 WARNING: Symbol lnxadd is already exported.
ld: 0711-415 WARNING: Symbol lnxcopy is already exported.
ld: 0711-415 WARNING: Symbol lnxmin is already exported.
ld: 0711-415 WARNING: Symbol lnxmul is already exported.
ld: 0711-415 WARNING: Symbol lnxnur is already exported.
ld: 0711-415 WARNING: Symbol lnxren is already exported.
ld: 0711-415 WARNING: Symbol lnxsca is already exported.
ld: 0711-415 WARNING: Symbol lnxshift is already exported.
ld: 0711-415 WARNING: Symbol lnxsni is already exported.
ld: 0711-415 WARNING: Symbol lxgu2t is already exported.
ld: 0711-415 WARNING: Symbol sldxgd is already exported.
ld: 0711-773 WARNING: Object /u01/app/oracle/product/11.2.0/dbhome_1/lib//liboraolap11.a[sxstime.o], imported symbol timezone
Symbol was expected to be local. Extra instructions
are being generated to reference the symbol.
ld: 0711-773 WARNING: Object /u01/app/oracle/product/11.2.0/dbhome_1/lib//libgeneric11.a[sdbgrfu.o], imported symbol timezone
Symbol was expected to be local. Extra instructions
are being generated to reference the symbol.
ld: 0711-773 WARNING: Object /u01/app/oracle/product/11.2.0/dbhome_1/lib//libordsdo11.a[mdowd.o], imported symbol ksudbrmseccnt_
Symbol was expected to be local. Extra instructions
are being generated to reference the symbol.
ld: 0711-773 WARNING: Object /u01/app/oracle/product/11.2.0/dbhome_1/lib//libordsdo11.a[mdrt.o], imported symbol ksudbrmseccnt_
Symbol was expected to be local. Extra instructions
are being generated to reference the symbol.
ld: 0711-773 WARNING: Object /u01/app/oracle/product/11.2.0/dbhome_1/lib//libordsdo11.a[mdidx.o], imported symbol ksudbrmseccnt_
Symbol was expected to be local. Extra instructions
are being generated to reference the symbol.
ld: 0711-773 WARNING: Object /u01/app/oracle/product/11.2.0/dbhome_1/lib//libordsdo11.a[mdrcr.o], imported symbol kcbstdbz_
Symbol was expected to be local. Extra instructions
are being generated to reference the symbol.
ld: 0711-773 WARNING: Object /u01/app/oracle/product/11.2.0/dbhome_1/lib//libordsdo11.a[mdrt.o], imported symbol kcbstdbz_
Symbol was expected to be local. Extra instructions
are being generated to reference the symbol.
ld: 0711-773 WARNING: Object /u01/app/oracle/product/11.2.0/dbhome_1/lib//libordsdo11.a[mdrcnc.o], imported symbol mdrcnccmt_
Symbol was expected to be local. Extra instructions
are being generated to reference the symbol.
ld: 0711-783 WARNING: TOC overflow. TOC size: 227576 Maximum size: 65536
Extra instructions are being generated for each reference to a TOC
symbol if the symbol is in the TOC overflow area.
....
.....
OPatch found the word "warning" in the stderr of the make command.
Please look at this stderr. You can re-run this make command.
Stderr output:
ld: 0711-773 WARNING: Object /u01/app/oracle/product/11.2.0/dbhome_1/lib//libgeneric11.a[sdbgrfu.o], imported symbol timezone
Symbol was expected to be local. Extra instructions
are being generated to reference the symbol.
Composite patch 14275605 successfully applied.
OPatch Session completed with warnings.

$/14275572/custom/server/14275572/custom/scripts/postpatch.sh -dbhome

/tmp/software/14275572/custom/server/14275572/custom/scripts/postpatch.sh -dbhome /u01/app/oracle/product/11.2.0/dbhome_1

/tmp/software/14275572/custom/server/14275572/custom/scripts/postpatch.sh -dbhome /u01/app/oracle/product/11.2.0/dbhome_1$
Reading /u01/app/oracle/product/11.2.0/dbhome_1/install/params.ora..
Reading /u01/app/oracle/product/11.2.0/dbhome_1/install/params.ora..
Parsing file /u01/app/oracle/product/11.2.0/dbhome_1/bin/racgwrap
Parsing file /u01/app/oracle/product/11.2.0/dbhome_1/bin/srvctl
Parsing file /u01/app/oracle/product/11.2.0/dbhome_1/bin/srvconfig
Parsing file /u01/app/oracle/product/11.2.0/dbhome_1/bin/cluvfy
Verifying file /u01/app/oracle/product/11.2.0/dbhome_1/bin/racgwrap
Verifying file /u01/app/oracle/product/11.2.0/dbhome_1/bin/srvctl
Verifying file /u01/app/oracle/product/11.2.0/dbhome_1/bin/srvconfig
Verifying file /u01/app/oracle/product/11.2.0/dbhome_1/bin/cluvfy
Reapplying file permissions on /u01/app/oracle/product/11.2.0/dbhome_1/bin/racgwrap
Reapplying file permissions on /u01/app/oracle/product/11.2.0/dbhome_1/bin/srvctl
Reapplying file permissions on /u01/app/oracle/product/11.2.0/dbhome_1/bin/srvconfig
Reapplying file permissions on /u01/app/oracle/product/11.2.0/dbhome_1/bin/cluvfy
Reapplying file permissions on /u01/app/oracle/product/11.2.0/dbhome_1/bin/diskmon.bin
Reapplying file permissions on /u01/app/oracle/product/11.2.0/dbhome_1/bin/lsnodes
Reapplying file permissions on /u01/app/oracle/product/11.2.0/dbhome_1/bin/osdbagrp
Reapplying file permissions on /u01/app/oracle/product/11.2.0/dbhome_1/bin/rawutl
Reapplying file permissions on /u01/app/oracle/product/11.2.0/dbhome_1/srvm/admin/ractrans
Reapplying file permissions on /u01/app/oracle/product/11.2.0/dbhome_1/srvm/admin/getcrshome
Reapplying file permissions on /u01/app/oracle/product/11.2.0/dbhome_1/bin/gnsd
Reapplying file permissions on /u01/app/oracle/product/11.2.0/dbhome_1/bin/crsdiag.pl
Reapplying file permissions on /u01/app/oracle/product/11.2.0/dbhome_1/lib/libhasgen11.a
Reapplying file permissions on /u01/app/oracle/product/11.2.0/dbhome_1/lib/libclsra11.a

5.GI HOME and DB HOME的patch已经全部打上了,现在启动集群

使用root用户

# /rdbms/install/rootadd_rdbms.sh
# /crs/install/rootcrs.pl -patch

./rootcrs.pl -patchUsing configuration parameter file: ./crsconfig_params
CRS-4123: Oracle High Availability Services has been started.

6.启动RAC数据库

$ /bin/srvctl start home -o -s -n

$srvctl start home -o /u01/app/oracle/product/11.2.0/dbhome_1 -s /home/oracle/db_satus.txt -n retc1

再在节点2打patch,需要完成以上同样的操作.

(注:节点2打patch的过程就不执行了,和节点1的步骤一样)

7.Patch Post-Installation Instructions(两个节点的软件patch打成功之后进行的操作)

If applying a PSU, load modified SQL files into the database.

The following steps load modified SQL files into the database. For an Oracle RAC environment, perform these steps on only one node.因此需要在RAC数据库打patch,如下:

cd /$ORACLE_HOME/rdbms/admin
sqlplus /nolog
SQL>conn /as sysdba
SQL>@catbundle.sql psu apply

### BEGIN LOG - DATE: 121218, TIME: 163506 ###

PL/SQL procedure successfully completed.


PL/SQL procedure successfully completed.


PL/SQL procedure successfully completed.


Generating apply and rollback scripts...
Check the following file for errors:
/u01/app/oracle/cfgtoollogs/catbundle/catbundle_PSU_RETC_GENERATE_2012Dec18_16_53_00.log
Apply script: /u01/app/oracle/product/11.2.0/dbhome_1/rdbms/admin/catbundle_PSU_RETC_APPLY.sql
Rollback script: /u01/app/oracle/product/11.2.0/dbhome_1/rdbms/admin/catbundle_PSU_RETC_ROLLBACK.sql

PL/SQL procedure successfully completed.

Executing script file...
...

.....

SQL> PROMPT Updating registry...
Updating registry...
SQL> INSERT INTO registry$history
2 (action_time, action,
3 namespace, version, id,
4 bundle_series, comments)
5 VALUES
6 (SYSTIMESTAMP, 'APPLY',
7 SYS_CONTEXT('REGISTRY$CTX','NAMESPACE'),
8 '11.2.0.3',
9 4,
10 'PSU',
11 'PSU 11.2.0.3.4');

1 row created.

SQL> COMMIT;

Commit complete.

SQL> SPOOL off
SQL> SET echo off
Check the following log file for errors:
/u01/app/oracle/cfgtoollogs/catbundle/catbundle_PSU_RETC_APPLY_2012Dec18_16_53_01.log
SQL> select action,comments from registry$history;

SQL> col action for a20
SQL> col comments for a20
SQL> /

ACTION COMMENTS
-------------------- --------------------
APPLY Patchset 11.2.0.2.0
APPLY PSU 11.2.0.3.4

2 rows selected.

8.验证PSU

在每个节点的GI HOME and ORACLE RAC DATABASE HOME进行验证

$opatch lsinventory |more

Oracle Interim Patch Installer version 11.2.0.3.3
Copyright (c) 2012, Oracle Corporation. All rights reserved.


Oracle Home : /u01/app/11.2.0/grid
Central Inventory : /u01/app/oraInventory
from : /u01/app/11.2.0/grid/oraInst.loc
OPatch version : 11.2.0.3.3
OUI version : 11.2.0.3.0
Log file location : /u01/app/11.2.0/grid/cfgtoollogs/opatch/opatch2012-12-18_16-21-25PM_1.log

Lsinventory Output file location : /u01/app/11.2.0/grid/cfgtoollogs/opatch/lsinv/lsinventory2012-12-18_16-21-25PM.txt

--------------------------------------------------------------------------------
Installed Top-level Products (1):

Oracle Grid Infrastructure 11.2.0.3.0
There are 1 products installed in this Oracle Home.


Interim patches (2) :

Patch 14275605 : applied on Tue Dec 18 11:32:05 CST 2012

Unique Patch ID: 15390008
Patch description: "Database Patch Set Update : 11.2.0.3.4 (14275605)"

Created on 3 Oct 2012, 23:27:54 hrs PST8PDT
Sub-patch 13923374; "Database Patch Set Update : 11.2.0.3.3 (13923374)"
Sub-patch 13696216; "Database Patch Set Update : 11.2.0.3.2 (13696216)"
Sub-patch 13343438; "Database Patch Set Update : 11.2.0.3.1 (13343438)"
Bugs fixed:
12880299, 12960925, 14038787, 13059165, 12834027, 13502183, 12612118
12764337, 13397104, 13916709, 13772618, 14390252, 10133521, 9761357
13588248, 12894807, 13773133, 13742435, 12829021, 13657605, 13742434
12585543, 13742433, 13742438, 13742437, 13742436, 12905058, 13503598
9873405, 12535346, 12582664, 13632717, 12861463, 13343438, 12971775
13080778, 12849688, 13696216, 13103913, 13737746, 13457582, 13742464
13099577, 12917230, 13036331, 12938841, 12693626, 14548763, 12656535
13499128, 13624984, 12678920, 11708510, 12401111, 13377816, 13699124
13338048, 12913474, 13705338, 12662040, 12658411, 11877623, 11063191
13250244, 12847466, 12718090, 12797765, 14613900, 12919564, 12780983
12617123, 12950644, 12923168, 13035360, 13903046, 13923374, 13572659
13420224, 12646784, 13370330, 14275605, 13340388, 12583611, 14409183
12794305, 13464002, 10350832, 14480674, 14480675, 14480676, 12998795
13467683, 12588744, 13528551, 12594032, 13612575, 13001379, 14076523
12797420, 12620823, 13257247, 13358781, 13041324, 13649031, 13366202
13385346, 13527323, 13804294, 13326736, 13492735, 14664355, 13981051
13466801, 13332439, 13718279, 13035804, 14063281, 14063280, 13362079
13419660, 13384182, 9703627, 12845115, 12976376, 13070939, 11840910
9858539, 13566938, 13430938, 12748240, 12780098, 13354082, 14062797
12879027, 14062796, 14062795, 14062794, 14062793, 14062792, 13476583
13484963, 13550185, 13554409

Patch 14275572 : applied on Tue Dec 18 11:27:19 CST 2012

Unique Patch ID: 15390008
Patch description: "Grid Infrastructure Patch Set Update : 11.2.0.3.4 (14275572)"

Created on 14 Oct 2012, 22:58:58 hrs PST8PDT
Bugs fixed:
14275572, 13919095, 13696251, 13348650, 12659561, 13039908, 13825231
13036424, 12794268, 13011520, 13569812, 12758736, 13000491, 13498267
13077654, 13001901, 13550689, 13430715, 13806545, 11675721, 14082976
12771830, 12538907, 13947200, 13066371, 13483672, 12594616, 13540563
12897651, 12897902, 13241779, 12896850, 12726222, 12829429, 12728585
13079948, 12876314, 13090686, 12925041, 12995950, 13251796, 12650672
12398492, 12848480, 13582411, 13652088, 12990582, 13857364, 12975811
12917897, 13082238, 12947871, 13037709, 13371153, 12878750, 10114953
11772838, 13058611, 13001955, 11836951, 12965049, 13440962, 12765467
13727853, 13425727, 12885323, 13965075, 13339443, 12784559, 13332363
13074261, 12971251, 13811209, 12709476, 13460353, 13523527, 12857064
13719731, 13396284, 12899169, 13111013, 13323698, 12867511, 12639013
12959140, 13085732, 12829917, 10317921, 13843080, 12934171, 12849377
12349553, 13924431, 13869978, 12680491, 12914824, 13789135, 12730342
13334158, 12950823, 10418841, 13355963, 13531373, 13776758, 12720728
13620816, 13002015, 13023609, 13024624, 12791719, 13886023, 13255295
13821454, 12782756, 14625969, 14152875, 14186070, 12873909, 14214257
12914722, 13243172, 12842804, 13045518, 12765868, 12772345, 12663376
13345868, 14059576, 13683090, 12932852, 13889047, 12695029, 13146560
13038806, 14251904, 14070200, 13820621, 14304758, 13396356, 13697828
13258062, 12834777, 12996572, 13941934, 13657366, 13019958, 12810890
13888719, 13502441, 13726162, 13880925, 14153867, 13506114, 12820045
13604057, 12823838, 13877508, 12823042, 14494305, 13582706, 13617861
12825835, 13263435, 13025879, 13853089, 14009845, 13410987, 13570879
13637590, 12827493, 13247273, 13068077

Rac system comprising of multiple nodes
Local node = retc1
Remote node = retc2

--------------------------------------------------------------------------------

OPatch succeeded.

请使用浏览器的分享功能分享到微信等