Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options

Apache cgi dbi::oracle error

by rampec (Initiate)
on Feb 07, 2008 at 02:53 UTC ( #666719=perlquestion: print w/replies, xml ) Need Help??

rampec has asked for the wisdom of the Perl Monks concerning the following question:

Hi, I have written a simple perl script to connect to the oracle database in sunsolaris unix box. The script is working fine when executed alone as a perl script. But if I move it to the apache server it is showing the below error. Pls help on this one '/usr/local/perl-583-Oracle9/lib/site_perl/5.8.3/sun4-solaris/auto/DBD/Oracle/' for module DBD::Oracle: perl5.8.3: fatal: /oracle/product/9.2.0/lib/ wrong ELF class: ELFCLASS64 at /usr/local/perl-583-Oracle9/lib/5.8.3/sun4-solaris/ line 229.,

Replies are listed 'Best First'.
Re: Apache cgi dbi::oracle error
by kyle (Abbot) on Feb 07, 2008 at 03:14 UTC
      Thanks a lot for your help...
Re: Apache cgi dbi::oracle error
by olus (Curate) on Feb 07, 2008 at 17:32 UTC

    Check your http.conf file and look for PERL5LIB. If it is present, it may be setting your script handler to a different perl. Maybe you have more than one perl installed on your system.

Re: Apache cgi dbi::oracle error
by Errto (Vicar) on Feb 07, 2008 at 17:14 UTC
    When you say "move it to the Apache server" is that a different physical machine? I'm not a Solaris expert but just from the text itself it sounds like it might be an architecture issue, like you're calling 64-bit Oracle libraries from 32-bit Perl or vice versa, but if it were the same machine that wouldn't happen. The only other generic thing I can think of is environment variables: to make DBD::Oracle work you need at least ORACLE_HOME and possibly LD_LIBRARY_PATH set depending on the setup.
      Hi, Thanks for your reply you are right; I have added the env variable in the httpd.conf file to fix this issue and the ld_libraray_path pointing to lib32. Regards, Ram

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://666719]
Approved by ww
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others scrutinizing the Monastery: (11)
As of 2019-10-16 12:46 GMT
Find Nodes?
    Voting Booth?