On Apr 9, 10:04 am, [EMAIL PROTECTED] (Paula J Capacio) wrote:
> >>On March 28, Fred Vachon said:
> >>I have DBI and DBD::Oracle installed on a Solaris 10 machine.
> >>When I run either of the 2 commands that were posted I error out with:
> >>perl -MDBD::Oracle -le 'print $DBD::Oracle::VERSION;'
> >>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: .
> >> at -e line 0
> >>I'm thinking it might be an issue with PATH or LD_LIBRARY_PATH but I
> >>haven't been able to find it.
>
> I believe you are correct, and that this is another dynamic install.
> Solaris doesn't have the chatr command but you can use ldd to get
> similar information.
> Specifically, issue:
> ldd
> /usr/perl5/site_perl/5.8.4/sun4-solaris-64int/auto/DBD/Oracle/Oracle.so
>
> Although this doesn't show the libraries it shows what parts are
> missing.
> Do a 'find' for these parts and once you locate them, add the location
> to
> your LD_LIBRARY_PATH.
> Example for the following output:
> $ ldd
> /opt/Perl5/lib/perl5/site_perl/5.6.0/sun4-solaris/auto/DBD/Oracle/Oracle
> .so
> libclntsh.so.8.0 => (file not found)
> libwtc8.so => (file not found)
> libnsl.so.1 => /usr/lib/libnsl.so.1
> libsocket.so.1 => /usr/lib/libsocket.so.1
> libdl.so.1 => /usr/lib/libdl.so.1
> libsched.so.1 => /usr/lib/libsched.so.1
> libaio.so.1 => /usr/lib/libaio.so.1
> libposix4.so.1 => /usr/lib/libposix4.so.1
> libkstat.so.1 => /usr/lib/libkstat.so.1
> libm.so.1 => /usr/lib/libm.so.1
> libthread.so.1 => /usr/lib/libthread.so.1
> libc.so.1 => /usr/lib/libc.so.1
> libmp.so.2 => /usr/lib/libmp.so.2
> /usr/platform/SUNW,Ultra-80/lib/libc_psr.so.1
>
> I did a find for the files not found then added the locations to my
> environ vars:
>
> export ORACLE_HOME=/usr/oracle/product/8.1.7
> export TNS_ADMIN=??? (location of your tnsnames.ora)
> export PATH=/usr/oracle/product/8.1.7/bin:$PATH
> export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/usr/lib
>
> I hope this helps.
> Paula

Another approach is to use the ld configuration 'structure' (I'm a DBA
not an SA so I'm not sure of the terminology). In /etc/ld.so.conf:
    include ld.so.conf.d/*.conf

This will search the ld.so.conf.d direcotry for files like *.conf, and
load their contents at startup, or when the ldconfig command is
issued. In ld.si.conf.d/ (for my Fedora 8 system):

-rw-r--r-- 1 root root 15 2007-12-14 02:03 mysql-i386.conf
-rw-r--r-- 1 root root 73 2007-08-22 04:12 opensync-32.conf
-rw-r--r-- 1 root root 29 2008-03-03 13:34 oracle-10203.conf
-rw-r--r-- 1 root root 20 2008-01-24 09:38 qt-i386.conf
-rw-r--r-- 1 root root 15 2006-01-02 03:04 wine-32.conf

(btw - some errors occur complaining about '...empty, not checked' -
don't know what that means...)

In oracle-10203.conf:

   /oracle/product/10.2.0.3/lib

This will obviate the need to use LD_LIBRARY_PATH, which has some
controversy surrounding it's use. I also found a strangeness for the
install of DBD. If I remember correctly, the install document states
that LD_LIBRARY_PATH should be set during the module install, which
will link the value of the LD_LIBRARY_PATH . Indeed the value ends up
in the make file (in the EXTRA_LIBS,  LD_RUN_PATH and OTHERLDFLAGS
entries), and the library seems to be available as per the ldd
command, yet, without either an LD_LIBRARY_PATH environment variable
or the ld.so.conf.d method, DBD does not run.

Any thoughts?
pg


Reply via email to