1

I have a perl program which connects to oracle database and fetch details,Which is perfectly working from same host(cu394.cloud.net)

my $dbh = DBI->connect( "dbi:Oracle:host=cu394.cloud.net;sid=ora", "ctfuser238", "ctfuser238" , {'RaiseError' => 1});

But I need to run this same program from different host (cu364.cloud.net) to connect to cu394.

I tried make this script as executable binary like this using perlapp

/opt/pdk/bin/perlapp --force --exe rms --perl /opt/ActivePerl-5.12/bin/perl-static update.pl

and tried running that executable from different server but no luck

Kindly throw some light on this

Best Regards Sathish

sathishkumar
  • 337
  • 1
  • 3
  • 10
  • does our Oracle instance allow connections from outside? – sotona Mar 18 '16 at 07:26
  • yes that oracle is accessible from outside – sathishkumar Mar 18 '16 at 07:28
  • BTW, why do you need an exe on other host? In current situation problem may be anywhere. try to connect like: `my $dbh = DBI->connect( "dbi:Oracle:host=cu394.cloud.net;sid=ora", "ctfuser238", "ctfuser238" , {'RaiseError' => 1}) || die "$DBI::errstr";` we need to figure out where the problem indeed is – sotona Mar 18 '16 at 07:33
  • When i try to run simply the program it says oracle.so not found so i wrapped as a executable so that it may include all dependency,To make it simple from the system am connecting from will not have oracle instance – sathishkumar Mar 18 '16 at 07:37
  • so what does it say with modification I suggested? – sotona Mar 18 '16 at 07:40
  • I mean add 'die' and re-compile – sotona Mar 18 '16 at 07:41
  • install_driver(Oracle) failed: Can't load '/opt/ActivePerl-5.12/lib/auto/DBD/Oracle/Oracle.so' for module DBD::Oracle: libclntsh.so.10.1: I have put all the needed DBI perl modules but stiil the same error – sathishkumar Mar 18 '16 at 07:46
  • I believe this is the compilation issue. Just install everything is requires to your remote host – sotona Mar 18 '16 at 07:48

0 Answers0