Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re^3: DBI, DBD::Oracle and LD_LIBRARY_PATH

by Anonymous Monk
on Nov 30, 2008 at 23:25 UTC ( [id://726948]=note: print w/replies, xml ) Need Help??


in reply to RE: Re: DBI, DBD::Oracle and LD_LIBRARY_PATH
in thread DBI, DBD::Oracle and LD_LIBRARY_PATH

I ran into this problem recently on Linux. (I think it was triggered by an update of the Oracle InstantClient package; it used to run okay with caring about LD_LIBRARY_PATH. I'm not certain of that, though.)

I ended up using the solution above, but changing the first condition from

  unless ($ENV{BEGIN_BLOCK}) {

to

  unless (($ENV{BEGIN_BLOCK}) or $^C) {

so that my habitual "perl -c script.pl" reflexes would work. Without that change, the BEGIN block will re-execute the script in fully-operational mode, which is almost certainly not what you want.

(Of course, in versions of Perl that have it - certainly 5.6.0 onward, maybe later revisions of 5.005 - you should just use an INIT block instead. But that wasn't an option when the question was originally asked.)

Replies are listed 'Best First'.
Re^4: DBI, DBD::Oracle and LD_LIBRARY_PATH
by Anonymous Monk on Feb 24, 2009 at 16:11 UTC
    or simply give perl the library in the location where it looks for it. Silly but easy (if you are root). ln -s $ORACLE_HOME/libnnz10.so /usr/lib/libnnz10.so
      Yes, it's an old thread, but the problem still occurs.

      Under Solaris 10, one can add the default search-path using crle:

      root> crle -u -l /youroracledir/lib/instantclient_11_2
      There are a lot of options available (32/64bit, etc.), so it's worth to study the docs before copy/pasting any example given here ;-)

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://726948]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others examining the Monastery: (6)
As of 2024-04-19 11:22 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found