10.2.0.2的库遇到bug,需要打补丁-4639977。之前在2个测试环境(linux5.6)的10.2.0.2数据库上顺利打patch成功,但在生产环境solaris下却失败。
orcl% /oracle/product/10gr2/OPatch/opatch apply
orcl% /oracle/product/10gr2/OPatch/opatch prereq CheckConflictAgainstOHWithDetail -ph ./
Invoking OPatch 10.2.0.2.0
Oracle interim Patch Installer version 10.2.0.2.0
Copyright (c) 2005, Oracle Corporation. All rights reserved..
PREREQ session
Oracle Home : /oracle/product/10gr2
Central Inventory : /oracle/oraInventory
from : /oracle/product/10gr2/oraInst.loc
OPatch version : 10.2.0.2.0
OUI version : 10.2.0.2.0
OUI location : /oracle/product/10gr2/oui
Log file location : /oracle/product/10gr2/cfgtoollogs/opatch/opatch-2014_Jan_01_01-27-10-CST_Wed.log
Invoking prereq "checkconflictagainstohwithdetail"
List of patches on which the prereq runs are :
4639977
Prereq "checkConflictAgainstOHWithDetail" passed.
OPatch succeeded.
Invoking OPatch 10.2.0.2.0
Oracle interim Patch Installer version 10.2.0.2.0
Copyright (c) 2005, Oracle Corporation. All rights reserved..
Oracle Home : /oracle/product/10gr2
Central Inventory : /oracle/oraInventory
from : /oracle/product/10gr2/oraInst.loc
OPatch version : 10.2.0.2.0
OUI version : 10.2.0.2.0
OUI location : /oracle/product/10gr2/oui
Log file location : /oracle/product/10gr2/cfgtoollogs/opatch/opatch-2013_Dec_31_14-21-15-CST_Tue.log
ApplySession applying interim patch '4639977' to OH '/oracle/product/10gr2'
Invoking fuser to check for active processes.
Invoking fuser on "/oracle/product/10gr2/bin/oracle"
OPatch detected non-cluster Oracle Home from the inventory and will patch the local system only.
Please shutdown Oracle instances running out of this ORACLE_HOME on the local system.
(Oracle Home = '/oracle/product/10gr2')
Is the local system ready for patching?
Do you want to proceed? [y|n]
y
User Responded with: Y
Backing up files and inventory (not for auto-rollback) for the Oracle Home
Backing up files affected by the patch '4639977' for restore. This might take a while...
Backing up files affected by the patch '4639977' for rollback. This might take a while...
Patching component oracle.rdbms, 10.2.0.2.0...
Updating archive file "/oracle/product/10gr2/lib/libserver10.a" with "lib/libserver10.a/kkqs.o"
Running make for target ioracle
ApplySession adding interim patch '4639977' to inventory
Verifying the update...
Inventory check OK: Patch ID 4639977 is registered in Oracle Home inventory with proper meta-data.
Archive failed: failed to update "/oracle/product/10gr2/lib/libserver10.a" with updated "/oracle/4639977/files/lib/libserver10.a/kkqs.o"
Files check failed: Some files under ORACLE_HOME are not patched. Please see log file for details.
Apply Session failed: ApplySession failed in system modification phase... 'Verification of patch failed: Files are not updated completely.'
OPatch will attempt to restore the system...
Restoring the Oracle Home...
Checking if OPatch needs to invoke 'make' to restore some binaries...
Make result:
Command: /usr/ccs/bin/make -f ins_rdbms.mk ioracle ORACLE_HOME=/oracle/product/10gr2
Returned code: 0
Stdout output:
chmod 755 /oracle/product/10gr2/bin
- Linking Oracle
rm -f /oracle/product/10gr2/rdbms/lib/oracle
/usr/ccs/bin/ld -o /oracle/product/10gr2/rdbms/lib/oracle -L/oracle/product/10gr2/rdbms/lib/ -L/oracle/product/10gr2/lib/ -dy /oracle/product/10gr2/lib/prod/lib/v9/crti.o /oracle/product/10gr2/lib/prod/lib/v9/crt1.o /oracle/product/10gr2/rdbms/lib/opimai.o /oracle/product/10gr2/rdbms/lib/ssoraed.o /oracle/product/10gr2/rdbms/lib/ttcsoi.o /oracle/product/10gr2/rdbms/lib/defopt.o -z allextract -lperfsrv10 -z defaultextract /oracle/product/10gr2/lib/nautab.o /oracle/product/10gr2/lib/naeet.o /oracle/product/10gr2/lib/naect.o /oracle/product/10gr2/lib/naedhs.o /oracle/product/10gr2/rdbms/lib/config.o -lserver10 -lodm10 -lnnet10 -lskgxp10 -lsnls10 -lnls10 -lcore10 -lsnls10 -lnls10 -lcore10 -lsnls10 -lnls10 -lxml10 -lcore10 -lunls10 -lsnls10 -lnls10 -lcore10 -lnls10 -lhasgen10 -lcore10 -lskgxn2 -locr10 -locrb10 -locrutl10 -lhasgen10 -lcore10 -lskgxn2 -lclient10 -lvsn10 -lcommon10 -lgeneric10 -lknlopt `if /usr/ccs/bin/ar tv /oracle/product/10gr2/rdbms/lib/libknlopt.a | grep xsyeolap.o > /dev/null 2>&1 ; then echo "-loraolap10" ; fi` -lslax10 -lpls10 -lplp10 -lserver10 -lclient10 -lvsn10 -lcommon10 -lgeneric10 -lknlopt -lslax10 -lpls10 -lplp10 -ljox10 -lserver10 -lclsra10 -ldbcfg10 -locijdbcst10 -lwwg `cat /oracle/product/10gr2/lib/ldflags` -lnsslb10 -lncrypt10 -lnsgr10 -lnzjs10 -ln10 -lnnz10 -lnl10 -lnro10 `cat /oracle/product/10gr2/lib/ldflags` -lnsslb10 -lncrypt10 -lnsgr10 -lnzjs10 -ln10 -lnnz10 -lnl10 -lmm -lsnls10 -lnls10 -lcore10 -lsnls10 -lnls10 -lcore10 -lsnls10 -lnls10 -lxml10 -lcore10 -lunls10 -lsnls10 -lnls10 -lcore10 -lnls10 `cat /oracle/product/10gr2/lib/ldflags` -lnsslb10 -lncrypt10 -lnsgr10 -lnzjs10 -ln10 -lnnz10 -lnl10 -lnro10 `cat /oracle/product/10gr2/lib/ldflags` -lnsslb10 -lncrypt10 -lnsgr10 -lnzjs10 -ln10 -lnnz10 -lnl10 -lsnls10 -lnls10 -lcore10 -lsnls10 -lnls10 -lcore10 -lsnls10 -lnls10 -lxml10 -lcore10 -lunls10 -lsnls10 -lnls10 -lcore10 -lnls10 `if /usr/ccs/bin/ar tv /oracle/product/10gr2/rdbms/lib/libknlopt.a | grep "kxmnsd.o" > /dev/null 2>&1 ; then echo " " ; else echo "-lordsdo10"; fi` -lctxc10 -lctx10 -lzx10 -lgx10 -lctx10 -lzx10 -lgx10 -lordimt10 -lsnls10 -lnls10 -lcore10 -lsnls10 -lnls10 -lcore10 -lsnls10 -lnls10 -lxml10 -lcore10 -lunls10 -lsnls10 -lnls10 -lcore10 -lnls10 -lsnls10 -lunls10 -lsnls10 -lnls10 -lcore10 -lsnls10 -lnls10 -lcore10 -lsnls10 -lnls10 -lxml10 -lcore10 -lunls10 -lsnls10 -lnls10 -lcore10 -lnls10 `cat /oracle/product/10gr2/lib/sysliblist` -R /opt/SUNWcluster/lib/sparcv9:/oracle/product/10gr2/lib:/opt/ORCLcluster/lib/ -Y P,:/opt/SUNWcluster/lib/sparcv9:/opt/ORCLcluster/lib/:/usr/ccs/lib/sparcv9:/usr/lib/sparcv9 -Qy -lc -laio -lposix4 -lkstat -lm /oracle/product/10gr2/lib/prod/lib/v9/crtn.o
mv -f /oracle/product/10gr2/bin/oracle /oracle/product/10gr2/bin/oracleO
mv /oracle/product/10gr2/rdbms/lib/oracle /oracle/product/10gr2/bin/oracle
chmod 6751 /oracle/product/10gr2/bin/oracle
Stderr output:
OPatch was able to restore your system. Look at log file and timestamp of each file to make sure your system is in the state prior to applying the patch.
--------------------------------------------------------------------------------
The following warnings have occurred during OPatch execution:
1) OUI-67124:Files check failed: Some files under ORACLE_HOME are not patched. Please see log file for details.
--------------------------------------------------------------------------------
OPatch failed with error code 73
解决方法:
在solaris下:
orcl% ls -l /oracle/product/10gr2/.patch_storage/verify/archive/lib/libserver10.a/kkqs.o
-rw-r--r-- 1 oracle oinstall 260100 Jan 1 01:08 /oracle/product/10gr2/.patch_storage/verify/archive/lib/libserver10.a/kkqs.o
orcl% ls -l /oracle/4639977/files/lib/libserver10.a/kkqs.o
-rw-r--r-- 1 oracle oinstall 260096 Jun 15 2006 /oracle/4639977/files/lib/libserver10.a/kkqs.o
文件大小差4k
而在linux下:
[oracle@LGBDBD01 5143079]$ ls -l /oracle/product/10gr2/.patch_storage/verify/archive/lib/libserver10.a/kkqs.o
-rw-r--r-- 1 oracle oinstall 169688 Dec 31 10:46 /oracle/product/10gr2/.patch_storage/verify/archive/lib/libserver10.a/kkqs.o
[oracle@LGBDBD01 5143079]$ ll files/lib/libserver10.a/kkqs.o
-rw-r--r-- 1 oracle oinstall 169688 May 4 2006 files/lib/libserver10.a/kkqs.o
文件大小无差别。
原因是因为"OPatch Failing Validation Phase When Archiving Really Did Not Fail (文档 ID 353150.1)"
The OS is adding 4 bytes to the size of the objects being archived into libraries.
最后将opatch的版本从10.2.0.2升级到10.2.0.5.最终解决问题。
orcl% /oracle/product/10gr2/OPatch/opatch apply -ocmrf /oracle/product/10gr2/OPatch/ocm/bin/ocm.rsp
Invoking OPatch 10.2.0.5.1
Oracle Interim Patch Installer version 10.2.0.5.1
Copyright (c) 2010, Oracle Corporation. All rights reserved.
Oracle Home : /oracle/product/10gr2
Central Inventory : /oracle/oraInventory
from : /var/opt/oracle/oraInst.loc
OPatch version : 10.2.0.5.1
OUI version : 10.2.0.2.0
OUI location : /oracle/product/10gr2/oui
Log file location : /oracle/product/10gr2/cfgtoollogs/opatch/opatch2014-01-01_02-29-37AM.log
Patch history file: /oracle/product/10gr2/cfgtoollogs/opatch/opatch_history.txt
ApplySession applying interim patch '4639977' to OH '/oracle/product/10gr2'
Running prerequisite checks...
OPatch detected non-cluster Oracle Home from the inventory and will patch the local system only.
Please shutdown Oracle instances running out of this ORACLE_HOME on the local system.
(Oracle Home = '/oracle/product/10gr2')
Is the local system ready for patching? [y|n]
y
User Responded with: Y
Backing up files and inventory (not for auto-rollback) for the Oracle Home
Backing up files affected by the patch '4639977' for restore. This might take a while...
Backing up files affected by the patch '4639977' for rollback. This might take a while...
Patching component oracle.rdbms, 10.2.0.2.0...
Updating archive file "/oracle/product/10gr2/lib/libserver10.a" with "lib/libserver10.a/kkqs.o"
Running make for target ioracle
ApplySession adding interim patch '4639977' to inventory
Verifying the update...
Inventory check OK: Patch ID 4639977 is registered in Oracle Home inventory with proper meta-data.
Files check OK: Files from Patch ID 4639977 are present in Oracle Home.
The local system has been patched and can be restarted.
OPatch succeeded.
orcl% /oracle/product/10gr2/OPatch/opatch lsinventory
Invoking OPatch 10.2.0.5.1
Oracle Interim Patch Installer version 10.2.0.5.1
Copyright (c) 2010, Oracle Corporation. All rights reserved.
Oracle Home : /oracle/product/10gr2
Central Inventory : /oracle/oraInventory
from : /var/opt/oracle/oraInst.loc
OPatch version : 10.2.0.5.1
OUI version : 10.2.0.2.0
OUI location : /oracle/product/10gr2/oui
Log file location : /oracle/product/10gr2/cfgtoollogs/opatch/opatch2014-01-01_02-32-42AM.log
Patch history file: /oracle/product/10gr2/cfgtoollogs/opatch/opatch_history.txt
Lsinventory Output file location : /oracle/product/10gr2/cfgtoollogs/opatch/lsinv/lsinventory2014-01-01_02-32-42AM.txt
--------------------------------------------------------------------------------
Installed Top-level Products (2):
Oracle Database 10g 10.2.0.1.0
Oracle Database 10g Release 2 Patch Set 1 10.2.0.2.0
There are 2 products installed in this Oracle Home.
Interim patches (1) :
Patch 4639977 : applied on Wed Jan 01 02:31:08 CST 2014
Created on 15 Jun 2006, 06:02:03 hrs US/Pacific
Bugs fixed:
4639977
--------------------------------------------------------------------------------
OPatch succeeded.
来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/24500180/viewspace-1066273/,如需转载,请注明出处,否则将追究法律责任。
转载于:http://blog.itpub.net/24500180/viewspace-1066273/