Oracle 11g R2 Installation Ubuntu-like Solving Errors 'install' & 'Agent nmhs' of Makefile

  1. Open a New Terminal Window
  2. Library Sim-Linking Needed at least for Ubuntu 12.10+ Based:
    sudo ln -fs /u01/app/oracle/product/11.2.0/dbhome_1/lib/stubs/ /lib64/

    Thanks to HannHha

  3. The Login as oracle User:
    su oracle
  4. Execute Step-by-Step (Copy & Paste into Terminal):
    sed -i 's/^(s*$(MK_EMAGENT_NMECTL))s*$/ -lnnz11/g' $ORACLE_HOME/sysman/lib/
    sed -i 's/^($LD $LD_RUNTIME) ($LD_OPT)/ -Wl,--no-as-needed /g' $ORACLE_HOME/bin/genorasdksh
    sed -i 's/^(s*)($(OCRLIBS_DEFAULT))/ -Wl,--no-as-needed /g' $ORACLE_HOME/srvm/lib/
    sed -i 's/^(TNSLSNR_LINKLINE.*$(TNSLSNR_OFILES)) ($(LINKTTLIBS))/ -Wl,--no-as-needed /g' $ORACLE_HOME/network/lib/
    sed -i 's/^(ORACLE_LINKLINE.*$(ORACLE_LINKER)) ($(PL_FLAGS))/ -Wl,--no-as-needed /g' $ORACLE_HOME/rdbms/lib/

    Then Verify the Changes Made!
    For the $ORACLE_HOME/sysman/lib/ File:

    nano $ORACLE_HOME/sysman/lib/

    Use Ctrl+w for Searching on nano.
    Here Search for: “$(MK_EMAGENT_NMECTL)”
    Eventually append the Needed -lnnz11

    $(MK_EMAGENT_NMECTL) -lnnz11

    Ctrl+x to Save & Exit.
    Then Follow to Check/Amend the Files for the “-Wl,–no-as-needed” chunk insertion…
    For the $ORACLE_HOME/bin/genorasdksh File:

    nano $ORACLE_HOME/bin/genorasdksh

    Search for: “$LD $LD_RUNTIME”

    $LD $LD_RUNTIME -Wl,--no-as-needed $LD_OPT

    For $ORACLE_HOME/srvm/lib/ File
    If you Not Find the OCRLIBS_DEFAULT there then Instead Modify the $ORACLE_HOME/srvm/lib/ (It depends from the Oracle 11g R2 DB Update Release!)

    nano $ORACLE_HOME/srvm/lib/


     -Wl,--no-as-needed $(OCRLIBS_DEFAULT) $(LLIBCLNTSH) $(LINKLDLIBS)

    For the $ORACLE_HOME/network/lib/ File:

    nano $ORACLE_HOME/network/lib/



    And Finally for the $ORACLE_HOME/rdbms/lib/ File:

    nano $ORACLE_HOME/rdbms/lib/

    Search for: “ORACLE_LINKER”

  5. Click on Retry on Error Message
  6. Eventually to Solve Issue ‘all_no_orcl’ Look:
    Troubleshooting Error in Invoking Target all_no_orcl of Makefile
  7. Warning: on Ubuntu 14.04/14.10/15.04 If Do Not Works Check Logs and If You Find a Notice About ‘ undefined memcpy@GLIBC_2.14’ then Ignore and then Click on Continue to Follow Up and Achieve the Installation!