Re: 'make' command explainer

From: Stefan Koehler <contact_at_soocs.de>
Date: Sun, 23 Sep 2018 11:52:17 +0200 (CEST)
Message-ID: <1189943349.55977.1537696338049_at_ox.hosteurope.de>


Hello Ruan,
I think there are some misconceptions here.

At first Oracle does not deliver any source file - it delivers the object files (*.o - binary code which contains the machine code to perform the functions defined in the corresponding source file, and also contains a symbol table describing all objects in the file that have external linkage).

You never recompile anything here - you basically start at the linking phase (as preprocessing, compiling and assembling is already done by Oracle Corp.)

So what is the difference between "make -f ins_rdbms.mk ipc_rds ioracle" and "make -f ins_rdbms.mk ipc_rds"? Just execute make as dry run and have a look :-)

ipc_rds ioracle

------------8<------------------

T122DB [oracle_at_OEL lib]$ make -n -f ins_rdbms.mk ipc_rds ioracle rm -f /oracle/rdbms/12201/lib/libskgxp12.so cp /oracle/rdbms/12201/lib//libskgxpr.so /oracle/rdbms/12201/lib/libskgxp12.so chmod 755 /oracle/rdbms/12201/bin
echo
echo " - Linking Oracle "
rm -f /oracle/rdbms/12201/rdbms/lib/oracle
/oracle/rdbms/12201/bin/orald  -o /oracle/rdbms/12201/rdbms/lib/oracle -m64 -z noexecstack -Wl,--disable-new-dtags -L/oracle/rdbms/12201/rdbms/lib/ -L/oracle/rdbms/12201/lib/ -L/oracle/rdbms/12201/lib/stubs/   -Wl,-E /oracle/rdbms/12201/rdbms/lib/opimai.o /oracle/rdbms/12201/rdbms/lib/ssoraed.o /oracle/rdbms/12201/rdbms/lib/ttcsoi.o -Wl,--whole-archive -lperfsrv12 -Wl,--no-whole-archive /oracle/rdbms/12201/lib/nautab.o /oracle/rdbms/12201/lib/naeet.o /oracle/rdbms/12201/lib/naect.o /oracle/rdbms/12201/lib/naedhs.o /oracle/rdbms/12201/rdbms/lib/config.o  -ldmext -lserver12 -lodm12 -lofs -lcell12 -lnnet12 -lskgxp12 -lsnls12 -lnls12  -lcore12 -lsnls12 -lnls12 -lcore12 -lsnls12 -lnls12 -lxml12 -lcore12 -lunls12 -lsnls12 -lnls12 -lcore12 -lnls12 -lclient12  -lvsn12 -lcommon12 -lgeneric12 -lknlopt `if /usr/bin/ar tv /oracle/rdbms/12201/rdbms/lib/libknlopt.a | grep xsyeolap.o > /dev/null 2>&1 ; then echo "-loraolap12" ; fi` -lskjcx12 -lslax12 -lpls12  -lrt -lplp12 -ldmext -lserver12 -lclient12  -lvsn12 -lcommon12 -lgeneric12 `if [ -f /oracle/rdbms/12201/lib/libavserver12.a ] ; then echo "-lavserver12" ; else echo "-lavstub12"; fi` `if [ -f /oracle/rdbms/12201/lib/libavclient12.a ] ; then echo "-lavclient12" ; fi` -lknlopt -lslax12 -lpls12  -lrt -lplp12 -ljavavm12 -lserver12  -lwwg  `cat /oracle/rdbms/12201/lib/ldflags`    -lncrypt12 -lnsgr12 -lnzjs12 -ln12 -lnl12 -lngsmshd12 -lnro12 `cat /oracle/rdbms/12201/lib/ldflags`    -lncrypt12 -lnsgr12 -lnzjs12 -ln12 -lnl12 -lngsmshd12 -lnnzst12 -lzt12 -lztkg12 -lmm -lsnls12 -lnls12  -lcore12 -lsnls12 -lnls12 -lcore12 -lsnls12 -lnls12 -lxml12 -lcore12 -lunls12 -lsnls12 -lnls12 -lcore12 -lnls12 -lztkg12 `cat /oracle/rdbms/12201/lib/ldflags`    -lncrypt12 -lnsgr12 -lnzjs12 -ln12 -lnl12 -lngsmshd12 -lnro12 `cat /oracle/rdbms/12201/lib/ldflags`    -lncrypt12 -lnsgr12 -lnzjs12 -ln12 -lnl12 -lngsmshd12 -lnnzst12 -lzt12 -lztkg12   -lsnls12 -lnls12  -lcore12 -lsnls12 -lnls12 -lcore12 -lsnls12 -lnls12 -lxml12 -lcore12 -lunls12 -lsnls12 -lnls12 -lcore12 -lnls12 `if /usr/bin/ar tv /oracle/rdbms/12201/rdbms/lib/libknlopt.a | grep "kxmnsd.o" > /dev/null 2>&1 ; then echo " " ; else echo "-lordsdo12 -lserver12"; fi` -L/oracle/rdbms/12201/ctx/lib/ -lctxc12 -lctx12 -lzx12 -lgx12 -lctx12 -lzx12 -lgx12 -lordimt12 -lclsra12 -ldbcfg12 -lhasgen12 -lskgxn2 -lnnzst12 -lzt12 -lxml12 -lgeneric12 -locr12 -locrb12 -locrutl12 -lhasgen12 -lskgxn2 -lnnzst12 -lzt12 -lxml12 -lgeneric12  -lgeneric12 -lorazip -loraz -llzopro5 -lorabz2 -lipp_z -lipp_bz2 -lippdcemerged -lippsemerged -lippdcmerged  -lippsmerged -lippcore  -lippcpemerged -lippcpmerged  -lsnls12 -lnls12  -lcore12 -lsnls12 -lnls12 -lcore12 -lsnls12 -lnls12 -lxml12 -lcore12 -lunls12 -lsnls12 -lnls12 -lcore12 -lnls12 -lsnls12 -lunls12  -lsnls12 -lnls12  -lcore12 -lsnls12 -lnls12 -lcore12 -lsnls12 -lnls12 -lxml12 -lcore12 -lunls12 -lsnls12 -lnls12 -lcore12 -lnls12 -lasmclnt12 -lcommon12 -lcore12  -laio -lons  -lfthread12   `cat /oracle/rdbms/12201/lib/sysliblist` -Wl,-rpath,/oracle/rdbms/12201/lib -lm    `cat /oracle/rdbms/12201/lib/sysliblist` -ldl -lm   -L/oracle/rdbms/12201/lib `test -x /usr/bin/hugeedit -a -r /usr/lib64/libhugetlbfs.so && test -r /oracle/rdbms/12201/rdbms/lib/shugetlbfs.o && echo -Wl,-zcommon-page-size=2097152 -Wl,-zmax-page-size=2097152 -lhugetlbfs`
test ! -f /oracle/rdbms/12201/bin/oracle || (\
	   mv -f /oracle/rdbms/12201/bin/oracle /oracle/rdbms/12201/bin/oracleO &&\
	   chmod 600 /oracle/rdbms/12201/bin/oracleO )
mv /oracle/rdbms/12201/rdbms/lib/oracle /oracle/rdbms/12201/bin/oracle chmod 6751 /oracle/rdbms/12201/bin/oracle
------------8<------------------


ins_rdbms.mk ipc_rds

------------8<------------------

T122DB [oracle_at_OEL lib]$ make -n -f ins_rdbms.mk ipc_rds rm -f /oracle/rdbms/12201/lib/libskgxp12.so cp /oracle/rdbms/12201/lib//libskgxpr.so /oracle/rdbms/12201/lib/libskgxp12.so
------------8<------------------


T122DB [oracle_at_OEL lib]$ ldd $ORACLE_HOME/bin/oracle | grep libskgxp12
	libskgxp12.so => /oracle/rdbms/12201/lib/libskgxp12.so (0x00007f20f1de5000)
T122DB [oracle_at_OEL lib]$ ldd $ORACLE_HOME/bin/oracle | grep libskgxp
	libskgxp12.so => /oracle/rdbms/12201/lib/libskgxp12.so (0x00007fb5d8260000)

... and both libraries are dynamically linked in anyway :-)

Best Regards
Stefan Koehler

Independent Oracle performance consultant and researcher Website: http://www.soocs.de
Twitter: _at_OracleSK

> Ruan Linehan <ruandav_at_gmail.com> hat am 23. September 2018 um 01:59 geschrieben:
>
> Hi all,
>  
> Earlier today, we were patching a 12C ODA appliance and ran into a complaint surrounding a requirement to relink the Grid software from UDP to use RDS instead for the Infiniband before being able to progress further. So we attempted to follow the ODA documentation instruction to do this, but ran into some pretty immediate issues.
> The problem we faced appeared to surround our steps for relinking the home binaries (Which subsequently saw +ASM crash).  
>  
> The error/symptoms we observed appeared to match the below titled MOS document, and inferred that our relinking was incomplete.  
> "SKGXP IPC libraries must be the same version [local:RDS,remote:UDP] on Exadata"
>  
> My question though is around the linux make command. This instruction appeared to be required as part of the steps for relinking once we've stopped all resources and unlocked the Grid Infra home. I understand that make is used to do the recompile from source file, and enable, or specify the option for 'ipc_rds' as per below.  
>  
> $ cd $GRID_HOME/rdbms/lib 
> $ make -f [ins_rdbms.mk](http://ins_rdbms.mk) ipc_rds ioracle
>  
> But......The ODA documentation we referenced (Apologies but I don't have the direct link as not posting this from work) did not include the make command targets clause of "ioracle" however. 
>  
> So my question(s)...
> Can anyone outline the implications of the inclusion of the lib file "ioracle" clause here as part of the command please?
> Will the compile from source, react drastically differently, or not touch upon all linked library files if the ioracle clause is omitted?
> Does the ioracle stipulation restrict the recompilation to a subset or specific file group?
>  
> What we are really looking to determine here is whether we have the correct command in the ODA documentation for this step.
>  
> When we omit the "ioracle" clause, the make command seems to specify, one solitary lib output file which it first removes and then copies into place. 
> When we include the "ioracle" clause, as is shown across many many documentation examples on MOS, it appears to do additional linking steps and permissions setting which is shown on stdout. 
>  
> Any and all help is greatly appreciated.
> Ruan

--
http://www.freelists.org/webpage/oracle-l
Received on Sun Sep 23 2018 - 11:52:17 CEST

Original text of this message