dhj has asked for the wisdom of the Perl Monks concerning the following question:
Now if I run the script in shell where I have LD_LIBRARY_PATH environment variable defined it works just peachy. However if I don't first define LD_LIBRARY_PATH in the shell I get the following error:---- #!/usr/perl5/5.8.4/bin/perl -w use DBI; $host = "bo.boo.com"; $sid = "AAAA"; $user = 'secret'; $passwd = 'evenmoresecret'; $dbh = DBI->connect("dbi:Oracle:host=$host;sid=$sid", $user, $passwd); $dbh->disconnect; ---
I've tried inserting:--- install_driver(Oracle) failed: Can't load '/usr/perl5/site_perl/5.8.4/ +sun4-solaris-64int/auto/DBD/Oracle/Oracle.so' for module DBD::Oracle: + ld.so.1: perl: fatal: libclntsh.so.10.1: open failed: No such file o +r directory at /usr/perl5/5.8.4/lib/sun4-solaris-64int/DynaLoader.pm +line 230. at (eval 3) line 3 Compilation failed in require at (eval 3) line 3. Perhaps a required shared library or dll isn't installed where expecte +d at ./test2.pl line 12 --
at the beginning of by script but the result is the same error as I see if I have an undefined LD_LIBRARY_PATH. Any suggestions as to what I'm missing here?-- BEGIN { $ENV{'LD_LIBRARY_PATH'}='/local/src/local.perl/oracle/instantclient_10 +_2'; } --
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Environmental Variables and DBD::Oracle
by Tanktalus (Canon) on Sep 24, 2006 at 00:55 UTC | |
by dhj (Novice) on Sep 24, 2006 at 02:26 UTC | |
| |
|
Re: Environmental Variables and DBD::Oracle
by grep (Monsignor) on Sep 24, 2006 at 00:20 UTC | |
by dhj (Novice) on Sep 24, 2006 at 00:48 UTC | |
|
Re: Environmental Variables and DBD::Oracle
by Joost (Canon) on Sep 24, 2006 at 00:14 UTC | |
|
Re: Environmental Variables and DBD::Oracle
by tobeya (Initiate) on Sep 25, 2006 at 17:26 UTC | |
|
Re: Environmental Variables and DBD::Oracle
by lorn (Monk) on Sep 25, 2006 at 13:39 UTC |