OPATCH无法在SOLARIS SPARC中工作,并出现错误:opatch: test: unknown operator ==

适用于:
Oracle WebLogic Server - Version 12.2.1.2.0 and later
Oracle Solaris on SPARC (64-bit)

报错:

bash-3.2$ ./opatch lsinventory
./opatch: test: unknown operator ==

原因:
BUG 16393828 - OPATCH.SH FAILS ON SOLARIS

BUG 16393904 - OPATCH-NEXTGEN: OPATCH NOT WORKING IN SOLARIS SPARC 10

解决方法:
修改opatch脚本
1、注释以下3行:
if [ "$PLATFORM" == "Linux" -a "$ARCH" == "x86_64" ]; then
DEFAULT_HEAP="-Xmx3072m"
fi
或者
2、将
if [ "$PLATFORM" == "Linux" -a "$ARCH" == "x86_64" ]; then
替换为
if [ "$PLATFORM" = "Linux" -a "$ARCH" = "x86_64" ]; then

重新执行命令,运行成功。

bash-3.2$ ./opatch lsinventory
Oracle Interim Patch Installer version 13.9.1.0.0
Copyright (c) 2020, Oracle Corporation.  All rights reserved.

Oracle Home       : /export/home/weblogic/Oracle/Middleware/Oracle_Home
Central Inventory : /u01/oraprod/db/oraInventory
   from           : /export/home/weblogic/Oracle/Middleware/Oracle_Home/oraInst.loc
OPatch version    : 13.9.1.0.0
OUI version       : 13.9.1.0.0
Log file location : /export/home/weblogic/Oracle/Middleware/Oracle_Home/cfgtoollogs/opatch/opatch2020-12-02_17-54-40PM_1.log

Related Posts