php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #13030 Periodic inability to connect to database, ORA-24327
Submitted: 2001-08-29 09:44 UTC Modified: 2004-03-25 09:15 UTC
Votes:4
Avg. Score:4.5 ± 0.9
Reproduced:4 of 4 (100.0%)
Same Version:2 (50.0%)
Same OS:1 (25.0%)
From: james dot mcininch at cereon dot com Assigned:
Status: Closed Package: OCI8 related
PHP Version: 4.0.6 OS: Solaris 7
Private report: No CVE-ID: None
 [2001-08-29 09:44 UTC] james dot mcininch at cereon dot com
Scripts that access oracle frequently fail to connect,
generating the error "OCISessionBegin: ORA-24327: need 
explicit attach before authenticating a user" when 
attempting OCIPLogon or OCINLogon. Accordin to the Oracle 
documentation, this message indicates that PHP attempted 
to open a connection on an invalid database handle.

Script:

<!-- keep reloading the page, it eventually dies -->
<?php
   $connection = OCIPLogon("user", "password", "database");
   if ($connection)
   {
      $sth = OCIParse($connection, "select table_name from 
all_tables");
      OCIExecute($sth);
      while (OCIFetchInto($sth, $result))
         echo "$result[0]<br>\n";
   }
?>

Modules:

'./configure' '--prefix=/usr/local' 
'--with-apxs=/usr/local/apache/bin/apxs' 
'--with-config-file-path=/usr/local/apache/conf' 
'--disable-xml' '--enable-bcmath' '--enable-calendar' 
'--enable-ftp' '--enable-shared' '--enable-sigchild' 
'--enable-sysvshm' '--enable-sysvsem' '--enable-shmop' 
'--enable-trans-sid' '--enable-yp' '--disable-xslt' 
'--enable-discard-path' '--enable-gd-native-ttf' 
'--enable-ucd-snmp-hack' '--enable-magic-quotes' 
'--with-bz2=/home/jjmcin' 
'--with-db3=/home/jjmcin/tmp/php' 
'--with-dom=/home/jjmcin/tmp/php' 
'--with-gd=/home/jjmcin/tmp/php' 
'--with-png-dir=/home/jjmcin/tmp/php' 
'--with-jpeg-dir=/home/jjmcin/tmp/php' 
'--with-t1lib=/home/jjmcin/tmp/php' 
'--with-tiff-dir=/home/jjmcin/tmp/php' 
'--with-ttf=/home/jjmcin/tmp/php' 
'--with-freetype-dir=/home/jjmcin/tmp/php' 
'--with-xpm-dir=/home/jjmcin/tmp/php' 
'--with-iconv=/home/jjmcin/tmp/php' 
'--with-ldap=/home/jjmcin/tmp/php' 
'--with-mysql=/home/jjmcin' '--with-oci8' 
'--with-openssl=/home/jjmcin/tmp/php' 
'--with-pgsql=/home/jjmcin/tmp/php' 
'--with-snmp=/home/jjmcin/tmp/php/snmp' 
'--with-zlib-dir=/home/jjmcin/tmp/php' 
'--with-zlib=/home/jjmcin/tmp/php' 
'--with-sablot=/home/jjmcin/tmp/php' 
'--with-xslt-sablot=/home/jjmcin/tmp/php' 
'--with-expat-dir=/home/jjmcin/tmp/php' 
'--with-pdflib=/home/jjmcin/tmp/php' 
'--with-mcrypt=/home/jjmcin/tmp/php' 
'--with-mhash=/home/jjmcin/tmp/php' 
'--with-curl=/home/jjmcin/tmp/php' 
'--with-java=/opt/share/java1.2/jdk1.2.2'

All extensions are statically linked except Oracle.

Oracle version is 8.1.6, load on the oracle server is
fairly low and server is setup with default settings for
Solaris. Apache version is 1.3.14 running as user "nobody"
There is no observed connectivity problems using sqlplus
or other oracle utilities.

Environment variables are set properly. and queries work 
properly at least 40% of the time (just click the reload 
button in the browser).



Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2002-04-13 08:51 UTC] thies@php.net
This bug has been fixed in CVS.


 [2004-03-25 08:51 UTC] gioppo at csi dot it
This bug represent itself on:
Apache Version  Apache/1.3.29  
Apache Release  10329100  
Apache API Version  19990320  
SERVER_SOFTWARE  Apache/1.3.29 (Unix) PHP/4.3.2  
Revision  $Revision: 1.183.2.5 $  
Oracle Version  8.1  
Please check it out.
Luca
 [2004-03-25 09:15 UTC] tony2001@php.net
Please, upgrade to the latest release of PHP.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Apr 25 20:01:45 2024 UTC