php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #47506 ocilogon returns error very rarely.
Submitted: 2009-02-26 06:10 UTC Modified: 2009-02-27 01:27 UTC
From: yoshida at zend dot co dot jp Assigned: sixd (profile)
Status: Not a bug Package: OCI8 related
PHP Version: 5.2.8 OS: Solaris Sparc 9
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: yoshida at zend dot co dot jp
New email:
PHP Version: OS:

 

 [2009-02-26 06:10 UTC] yoshida at zend dot co dot jp
Description:
------------
I find warnings that occurres each about 1 or 3 days.
The warning says,
PHP warning:  ocilogon() function.ocilogon OCIEnvNlsCreate() failed. There is something wrong with your system - please check that LD_LIBRARY_PATH includes the directory with Oracle Instant Client libraries.... 

But the LD_LIBRARY_PATH, the arguments to ocilogon() are all correct.

The warning continues 5 or 15 minutes, but no all ocilogon() fails.
Some ocilogon() fails, Others not fail in the same period.
I change ocilogon() to oci_connect(), but the warning also returns.

I could not find the warning when I use the Oracle Instant Client 9.2.0.5 and php 4.3.8, but I find now the message.
I use now the Oracle Instant Client 10.2.0.3 and php 5.2.8 pair.

I doubt OCI_G(errcode) may return error rarely in spite of correct arguments.
The OCI_G(errcode) is at 1237 line in /ext/oci8/oci8.c .

OCI_G(errcode) seems to use Oracle API at 446 line in /ext/oci8/php_oci8_int.h .

Reproduce code:
---------------
$ID = "userid";
$PW = "userpass";
$DB = "(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=userhost)(PORT=1521)))(CONNECT_DATA=(SERVICE_NAME=usersrvname)))";
return OCILogon($ID, $PW, $DB);


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2009-02-26 21:04 UTC] sixd@php.net
Check there is no resource starvation (memory, disk) at times it occurs.

Make sure Oracle environment variables are set prior to Apache starting.

Please follow up in a Support forum such as http://www.oracle.com/technology/forums/php.html or the php-db@lists.php.net mail list.
 [2009-02-27 01:27 UTC] yoshida at zend dot co dot jp
Hi, sixd,

I find no resource starvation and overload.

I believe the oracle environment variables are set prior to Apache
starting because they are written in apache2/bin/envvars
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Fri May 09 15:01:27 2025 UTC