天天看點

Linux7安裝Oracle 11g 86%報錯:Error in invoking target 'agent nmhs' of makefile

Linux7安裝Oracle 11g 86%報錯:Error in invoking target 'agent nmhs' of makefile

2018-06-08 16:19:54 印沖 閱讀數 4146更多

分類專欄: oralce

版權聲明:本文為部落客原創文章,遵循 CC 4.0 BY-SA 版權協定,轉載請附上原文出處連結和本聲明。

本文連結:https://blog.csdn.net/baidu_39459954/article/details/80624640

報錯環境

OS:Oracle Linux 7、Redhat 7、CentOS7

DB:Oracle 11.2.0.4

報錯标志

安裝到86%時出現報錯 Error in invoking target ‘agent nmhs’ of makefile

Linux7安裝Oracle 11g 86%報錯:Error in invoking target 'agent nmhs' of makefile

安裝日志裡面報錯資訊如下:

usr/bin/ld: /u01/app/oracle/product/11.2.0/dbhome_1/sysman/lib//libnmectl.a(nmectlt.o): undefined reference to symbol ‘B_DestroyKeyObject’

/usr/bin/ld: note: ‘B_DestroyKeyObject’ is defined in DSO /u01/app/oracle/product/11.2.0/dbhome_1/lib/libnnz11.so so try adding it to the linker command line

/u01/app/oracle/product/11.2.0/dbhome_1/lib/libnnz11.so: could not read symbols: Invalid operation

collect2: error: ld returne

INFO: d 1 exit status

官方解釋

Unpublished bug 19692824

During installation of Oracle Database or Oracle RAC on OL7, the following linking error may be encountered:

Error in invoking target 'agent nmhs' of makefile '<ORACLE_HOME>/sysman/lib/ins_emagent.mk'. See '<installation log>' for details.

If this error is encountered, the user should select Continue. Then, after the installation has completed, the user must download Patch 19692824 from My Oracle Support and apply it per the instructions included in the patch README.

官方的解釋說是先繼續安裝,然後在建立資料庫時再打更新檔,再建立資料庫。否則建立資料庫時em dbconsole功能會失敗

打更新檔步驟如下:

切換至oracle使用者

上傳更新檔檔案p19692824_112040_Linux-x86-64.zip

$ unzip p19692824_112040_Linux-x86-64.zip

$ cd 19692824

$ export PATH=$PATH:$ORACLE_HOME/OPatch

$ opatch apply

如果你在安裝資料庫軟體的時候就報錯,也可以使用下面的方法解決:

在makefile中添加連結libnnz11庫的參數

修改$ORACLE_HOME/sysman/lib/ins_emagent.mk,找到下面這行

$(MK_EMAGENT_NMECTL)

修改為:

$(MK_EMAGENT_NMECTL) -lnnz11

建議修改前備份原始檔案

cd $ORACLE_HOME/sysman/lib

cp ins_emagent.mk ins_emagent.mk.bak

vi ins_emagent.mk

進入vi編輯器後 指令模式輸入/NMECTL 進行查找,快速定位要修改的行。

在後面追加參數-lnnz11, 第一個是字母l,後面兩個是數字1。

儲存退出後Retry。

後語

Oracle11g的其他版本可能也會有這個報錯,也可以參照解決,但是不推薦在未經過Oracle認證過的系統上安裝相應版本。

Oracle Database 11.2.0.4.0 已在 Linux x86-64 Red Hat Enterprise Linux 7 上通過認證

Linux7安裝Oracle 11g 86%報錯:Error in invoking target 'agent nmhs' of makefile

Oracle Database 11.2.0.3.0 未在 Linux x86-64 Red Hat Enterprise Linux 7 上通過認證

Linux7安裝Oracle 11g 86%報錯:Error in invoking target 'agent nmhs' of makefile

參考文檔(MOS):

Installation of Oracle 11.2.0.4 Database Software on OL7 fails with “undefined reference to symbol ‘B_DestroyKeyObject’” error (文檔 ID 1965691.1)