
Neuron9
Novice
Mar 6, 2013, 11:34 PM
Post #1 of 3
(25103 views)
|
Compiled DBD::Oracle throwing Segmentation Fault (core dumped)
|
Can't Post
|
|
Hello Everyone, Am trying to compile DBD:Oracle particular version and its dependencies so that it works with Oracle 11gR2 client. Here are the steps I did and issue towards end: Downloaded ExtUtils-MakeMaker-6.56, DBI-1.54 and DBD-Oracle-1.24 My Perl Version - v5.8.8 built for sun4-solaris-thread-multi-64int <Setting up environment> # export PERL5LIB=/opt/myperl/lib/ <oracle_home is set to 11gR2 11.2.0.2.0 64-bit client> # export ORACLE_HOME=/oracle11g/app/ora11g/product/11.2.0/client_1/ <LD_LIBRARY_PATH is set to 11gR2 11.2.0.2.0 32-bit client this is because am using 32-bit perl and hence for compilation of Oracle.so this will be required> export LD_LIBRARY_PATH=/ora11gR2/app/ora11gR2/product/11.2.0/client_1/lib/ <Installing ExtUtils-MakeMaker> # cd ExtUtils-MakeMaker-6.56 # perl Makefile.PL # make # make install -----succeeded----- <Installing DBI-1.54> # cd DBI-1.54 # perl Makefile.PL # make gcc -c -D_REENTRANT -fno-strict-aliasing -pipe -Wdeclaration-after-statement -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -O -DVERSION=\"1.54\" -DXS_VERSION=\"1.54\" -fPIC "-I/opt/myperl/lib/5.8.8/sun4-solaris-thread-multi-64int/CORE" -W -Wall -Wpointer-arith -Wbad-function-cast -Wno-comment -Wno-sign-compare -Wno-cast-qual -Wmissing-noreturn -Wno-unused-parameter Perl.c sh: gcc: not found *** Error code 1 make: Fatal error: Command failed for target `Perl.o' <Installed gcc in /usr/local/bin # gcc -v Thread model: posix gcc version 3.4.6 > # export PATH=/usr/local/bin/:$PATH # make # make install -----succeeded----- <Installing DBD-Oracle-1.24> # cd DBD-Oracle-1.24 # perl Makefile.PL Oracle version 11.2.0.1 (11.2) Unable to locate an oracle.mk, proc.mk or other suitable *.mk file in your Oracle installation. (I looked in /oracle11g/app/ora11g/product/11.2.0/client_1/rdbms/demo/demo_rdbms32.mk /oracle11g/app/ora11g/product/11.2.0/client_1/precomp/demo/proc/proc.mk /oracle11g/app/ora11g/product/11.2.0/client_1/precomp/demo/proc/demo_proc.mk /oracle11g/app/ora11g/product/11.2.0/client_1/proc/lib/proc.mk /oracle11g/app/ora11g/product/11.2.0/client_1/proc16/lib/proc16.mk /usr/share/oracle/11.2/client/demo.mk /usr/share/oracle/11.2/client64/demo.mk under /oracle11g/app/ora11g/product/11.2.0/client_1) The oracle.mk (or demo_rdbms.mk) file is part of the Oracle RDBMS product. The proc.mk (or demo_proc.mk) file is part of the Oracle Pro*C product. You need to build DBD::Oracle on a system which has one of these Oracle components installed. (Other *.mk files such as the env_*.mk files will not work.) Alternatively you can use Oracle Instant Client. In the unlikely event that a suitable *.mk file is installed somewhere non-standard you can specify where it is using the -m option: perl Makefile.PL -m /path/to/your.mk See the appropriate README file for your OS for more information and some alternatives. at Makefile.PL line 1095. Followed ReadMe and then used flag -l # perl Makefile.PL -l # make # make install -----succeeded----- Now with all these compiled and installed modules I try to connect to database with a simple perl file and it throws 'Segmentation Fault' error. # perl test.pl Segmentation Fault (core dumped) # pstack core core 'core' of 20119: perl test.pl fef4fdd4 XS_DBD__Oracle__dr_init_oci (137110, 374910, 247b28, 2, 140d4c, 373a08) + ac 00092d80 Perl_pp_entersub (137110, 247b2c, 80, 0, 247b24, 0) + 5c0 0008a4dc Perl_runops_standard (137110, ff400000, 0, 800000, 12c, 1cb0b0) + 2c 0002a458 S_run_body (137110, 1, 137110, 0, ff272a00, 2) + 13c 0002a0a0 perl_run (137110, 1, 2, ffbff9d4, 134c00, 2) + 8c 0002698c main (2, ffbff9d4, ffbff9e0, 1370f8, ff270100, 0) + b8 0002676c _start (0, 0, 0, 0, 0, 0) + 5c What could be the cause of this issue? Compilation was good, so am not sure what might be am missing here? Comments / Suggestions please? Thanks in advance. Regards - Neuron
|