|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2002-04-13 08:51 UTC] thies@php.net
[2004-03-25 08:51 UTC] gioppo at csi dot it
[2004-03-25 09:15 UTC] tony2001@php.net
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Thu Nov 06 07:00:01 2025 UTC |
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).