Re: DBI use failure with DBI/DBD::Oracle on AIX 5.2

2004-11-26 Thread Michael A Chase tech
On 11/26/2004 08:14 AM, Chris Holt said:
Thanks , I needed some one to tell me it was definately permissions.
It made me look harder at the perms on higher level directories. Now
I'll look at my connection problem .
Can't connect to data source exua, no database driver specified and
DBI_DSN env var not set at ./ora.pl line 24
The example you sent earlier does specify a driver in 
dbi:Oracle:$dbname.  You'll have to show what you are actually using 
for anyone to give a better hint.

Please keep this on list.  I am not the sole source of all wisdom.
--
Mac :})
** I usually forward private questions to the appropriate mail list. **
Ask Smarter: http://www.catb.org/~esr/faqs/smart-questions.html
Cthulhu in 2004.  Don't settle for the lesser evil.


DBI use failure with DBI/DBD::Oracle on AIX 5.2

2004-11-25 Thread Chris Holt
After being prepped by experiences of others in the README.aix file. I beleive 
(see below), I have a good installation. But on running my fist test prog I 
appear to have a permissions problem. This litlle ditty does not fail when run 
as root, but anyone else and it aborts on the 'use DBI;'.

$ cat ora.pl
#!/bin/perl -w

use DBI;
use strict;

my ($dbname, $user, $passwd) = ('exua', 'remote', 'remote');

#$dbh = DBI-connect(dbi:Oracle:$dbname, $user, $passwd);

#$dbh-do(SELECT * FROM DUAL);

$
$ ./ora.pl
Can't locate loadable object for module DBI in @INC (@INC contains: 
/usr/opt/perl5/lib/5.8.0/aix-thread-multi /usr/opt/perl5/lib/5.8.0

/usr/opt/perl5/lib/site_perl/5.8.0/aix-thread-multi 
/usr/opt/perl5/lib/site_perl/5.8.0 /usr/opt/perl5/lib/site_perl .) at

/usr/opt/perl5/lib/site_perl/5.8.0/aix-thread-multi/DBI.pm line 254
BEGIN failed--compilation aborted at 
/usr/opt/perl5/lib/site_perl/5.8.0/aix-thread-multi/DBI.pm line 254.
Compilation failed in require at ./ora.pl line 3.
BEGIN failed--compilation aborted at ./ora.pl line 3.
$


permissions on the directories and files under /usr/opt/perl5 appear to be OK, 
at least world readable. Any ideas?



Perl info 

Summary of my perl5 (revision 5.0 version 8 subversion 0) configuration:

  Platform:
osname=aix, osvers=5.2.0.0, archname=aix-thread-multi
uname='aix rocky 2 5 000ad7df4c00 '
config_args=''
hint=recommended, useposix=true, d_sigaction=define
usethreads=define use5005threads=undef useithreads=define 
usemultiplicity=define
useperlio=define d_sfio=undef uselargefiles=define usesocks=undef
use64bitint=undef use64bitall=undef uselongdouble=undef
usemymalloc=n, bincompat5005=undef
  Compiler:
cc='cc_r', ccflags ='-D_ALL_SOURCE -D_ANSI_C_SOURCE -D_POSIX_SOURCE 
-qmaxmem=16384 -qnoansialias -DUSE_NATIVE_DLOPEN -DNEED_PTHREAD_INIT -q32 
-D_LARGE_FILES -qlonglong',
optimize='-O',
cppflags='-D_ALL_SOURCE -D_ANSI_C_SOURCE -D_POSIX_SOURCE -qmaxmem=16384 
-qnoansialias -DUSE_NATIVE_DLOPEN -DNEED_PTHREAD_INIT'
ccversion='', gccversion='', gccosandvers=''
intsize=4, longsize=4, ptrsize=4, doublesize=8, byteorder=4321
d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=8
ivtype='long', ivsize=4, nvtype='double', nvsize=8, Off_t='off_t', 
lseeksize=8
alignbytes=8, prototype=define
  Linker and Libraries:
ld='ld', ldflags =' -brtl -b32'
libpth=/lib /usr/lib /usr/ccs/lib
libs=-lbind -lnsl -ldbm -ldl -lld -lm -lpthreads -lc_r -lcrypt -lbsd -lPW
perllibs=-lbind -lnsl -ldl -lld -lm -lpthreads -lc_r -lcrypt -lbsd -lPW
libc=/lib/libc.a, so=a, useshrplib=true, libperl=libperl.a
gnulibc_version=''
  Dynamic Linking:
dlsrc=dl_aix.xs, dlext=so, d_dlsymun=undef, ccdlflags='  
-bE:/usr/opt/perl5/lib/5.8.0/aix-thread-multi/CORE/perl.exp'
cccdlflags=' ', lddlflags='-bhalt:4 -bM:SRE -bI:$(PERL_INC)/perl.exp 
-bE:$(BASEEXT).exp -bnoentry -lpthreads -lc_r'


Characteristics of this binary (from libperl):
  Compile-time options: MULTIPLICITY USE_ITHREADS USE_LARGE_FILES 
PERL_IMPLICIT_CONTEXT
  Built under aix
  Compiled at Jul 26 2002 13:48:15
  @INC:
/usr/opt/perl5/lib/5.8.0/aix-thread-multi
/usr/opt/perl5/lib/5.8.0
/usr/opt/perl5/lib/site_perl/5.8.0/aix-thread-multi
/usr/opt/perl5/lib/site_perl/5.8.0
/usr/opt/perl5/lib/site_perl
.




***

The BUILD

using

ORACENV=xlc_r
ORACLE_APPS=/data/exua/usr
ORACLE_HOME=/applications/ora92/app/oracle/product/9.2.0
ORACLE_PATH=/data/exua/usr/oraexe:/applications/mgua/release/bin:/applications/ora92/app/oracle/product/9.2.0/bin
ORACLE_SID=exua
ORACLE_USERID=remote/remote


lonamappu1 (root) /applications/home/holtcc/ext/perlmod/DBI-1.46: perl 
Makefile.PL

*** You are using a perl configured with threading enabled.
*** You should be aware that using multiple threads is
*** not recommended for production environments.

Creating DBI::PurePerltest variant: t/zvpp_01basics.t
Creating DBI::PurePerltest variant: t/zvpp_02dbidrv.t
Creating DBI::PurePerltest variant: t/zvpp_03handle.t
Creating DBI::PurePerltest variant: t/zvpp_04mods.t
Creating DBI::PurePerltest variant: t/zvpp_05thrclone.t (use threads)
Creating DBI::PurePerltest variant: t/zvpp_06attrs.t
Creating DBI::PurePerltest variant: t/zvpp_07kids.t
Creating DBI::PurePerltest variant: t/zvpp_08keeperr.t
Creating DBI::PurePerltest variant: t/zvpp_09trace.t
Creating DBI::PurePerltest variant: t/zvpp_10examp.t
Creating DBI::PurePerltest variant: t/zvpp_14utf8.t
Creating DBI::PurePerltest variant: t/zvpp_15array.t
Creating DBI::PurePerltest variant: t/zvpp_20meta.t
Creating DBI::PurePerltest variant: t/zvpp_30subclass.t
Creating DBI::PurePerltest variant: t/zvpp_40profile.t
Creating DBI::PurePerltest variant: t/zvpp_41prof_dump.t
Creating DBI::PurePerltest variant: 

Re: DBI use failure with DBI/DBD::Oracle on AIX 5.2

2004-11-25 Thread Michael A Chase tech
On 11/25/2004 08:03 AM, Chris Holt said:
After being prepped by experiences of others in the README.aix
 file. I beleive (see below), I have a good installation. But
 on running my fist test prog I appear to have a permissions
 problem. This litlle ditty does not fail when run as root,
 but anyone else and it aborts on the 'use DBI;'.
That is certainly an indication that you don't have permission for 
something.  Especially since root succeeds.

$ cat ora.pl
#!/bin/perl -w
use DBI;
use strict;
my ($dbname, $user, $passwd) = ('exua', 'remote', 'remote');
#$dbh = DBI-connect(dbi:Oracle:$dbname, $user, $passwd);
#$dbh-do(SELECT * FROM DUAL);
$
$ ./ora.pl
Can't locate loadable object for module DBI in @INC
 (@INC contains: /usr/opt/perl5/lib/5.8.0/aix-thread-multi
 /usr/opt/perl5/lib/5.8.0
 /usr/opt/perl5/lib/site_perl/5.8.0/aix-thread-multi
 /usr/opt/perl5/lib/site_perl/5.8.0
 /usr/opt/perl5/lib/site_perl .) at
/usr/opt/perl5/lib/site_perl/5.8.0/aix-thread-multi/DBI.pm line 254
BEGIN failed--compilation aborted at
 /usr/opt/perl5/lib/site_perl/5.8.0/aix-thread-multi/DBI.pm line 254.
Compilation failed in require at ./ora.pl line 3.
BEGIN failed--compilation aborted at ./ora.pl line 3.
...
permissions on the directories and files under /usr/opt/perl5 appear
 to be OK, at least world readable. Any ideas?
DBI.so is executable which was my first guess at the problem, make sure 
the directories have executable permisson for you too.

...
364664  260 -r-xr-xr-x  1 root exua   264738 Nov 25 10:14
/usr/opt/perl5/lib/site_perl/5.8.0/aix-thread-multi/auto/DBI/DBI.so
--
Mac :})
** I usually forward private questions to the appropriate mail list. **
Ask Smarter: http://www.catb.org/~esr/faqs/smart-questions.html
Cthulhu in 2004.  Don't settle for the lesser evil.