Subject: | Connect with ORA_SYSDBA, system commande return -1 |
Sorry for my poor English.
After connect in SYSDBA to an Oracle 10.2.0.2 Database, all system
command return '-1' (No child processes).
Problem detect on Solaris 10 x86 :
Details :
perl -MDBI -e 'DBI->installed_versions'
Perl : 5.008006 (i86pc-solaris-thread-multi)
OS : solaris (2.10)
DBI : 1.42
DBD::Sponge : 11.10
DBD::Proxy : 0.2004
DBD::Oracle : 1.15
DBD::File : 0.30
DBD::ExampleP : 11.12
DBD::DBM : 0.01
It's a production server, I can't upgrade DBD::Oracle for the moment.
(need to see my admin)
This code will show the problem :
use DBD::Oracle qw(:ora_session_modes);
my $dsn = "dbi:Oracle:"; # no dbname here
print "TWO_TASK not defined\n" if (not defined($ENV{TWO_TASK}));
print "ORACLE_SID : $ENV{ORACLE_SID} \n";
my $dbh = DBI->connect($dsn, "", "", { ora_session_mode =>
ORA_SYSDBA });
$dbh->{RaiseError} = 1;
my $sth = $dbh->prepare( "select sysdate from dual" );
$sth->execute();
my $date=$sth->fetchrow();
print "Date : $date \n";
$sth->finish();
$dbh->disconnect();
my $ret=system("date");
print "retour : $ret";
Result on my machine :
TWO_TASK not defined
ORACLE_SID : KJD00
Date : 30-JUL-08
mercredi, 30 juillet 2008, 14:32:22 MEST
retour : -1