OCIEnvNlsCreate failed

I have an asp.net application talking to an Oracle 9.2 Database. It works fine on my local machine but when I copy it to our Windows 2003 webserver I get the "OCIEnvNlsCreate failed with return code -1" error. I have checked that the asp.net user has read and write permissions to the entire Oracle Home directory on the server. any other suggestions would be appreciated.

I am also facing the Same issue when I am tring to connect to Oracle 9i Database from Asp.net 2.0 web application below is error log if any can help me it will really good.
OCIEnvNlsCreate failed with return code -1 but error message text was not available.
Exception: OCIEnvNlsCreate failed with return code -1 but error message text was not available.]
System.Data.OracleClient.OciHandle..ctor(OciHandle parentHandle, HTYPE handleType, MODE ocimode, HANDLEFLAG handleflags) +262
System.Data.OracleClient.OCI.DetermineClientVersion() +247
System.Data.OracleClient.OracleInternalConnection.OpenOnLocalTransaction(String userName, String password, String serverName, Boolean integratedSecurity, Boolean unicode, Boolean omitOracleConnectionName) +30
System.Data.OracleClient.OracleInternalConnection..ctor(OracleConnectionString connectionOptions) +135
System.Data.OracleClient.OracleConnectionFactory.CreateConnection(DbConnectionOptions options, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningObject) +37
System.Data.ProviderBase.DbConnectionFactory.CreatePooledConnection(DbConnection owningConnection, DbConnectionPool pool, DbConnectionOptions options) +28
System.Data.ProviderBase.DbConnectionPool.CreateObject(DbConnection owningObject) +429
System.Data.ProviderBase.DbConnectionPool.UserCreateRequest(DbConnection owningObject) +70
System.Data.ProviderBase.DbConnectionPool.GetConnection(DbConnection owningObject) +510
System.Data.ProviderBase.DbConnectionFactory.GetConnection(DbConnection owningConnection) +85
System.Data.ProviderBase.DbConnectionClosed.OpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory) +102
System.Data.OracleClient.OracleConnection.Open() +34
Rbc.Gpb.Cap.Cees.Dal.UtilityDao.GetChsPmtUserDetails(Int64 p_ChsProfileId) in D:\SourceControl\DEV\Cees\Rbc.Gpb.Cap.Cees.Dal\UtilityDao.cs:216
Rbc.Gpb.PlanManagement.BusinessLogic.PMTUtilManager.GetChsUserDetails(Int64 lngChsProfileID) in D:\SourceControl\DEV\Rbc.Gpb.PlanManagement\BusinessLogic\PMTUtilManager.cs:53
Rbc.Gpb.PlanManagement.Web.Util.PMTUtility.GetChsUserInfo(Int64 p_ChsProfileId) in D:\SourceControl\DEV\Rbc.Gpb.Cap.GpbOnline.Web\PlanManagement\Util\PMTUtility.cs:50
Rbc.Gpb.PlanManagement.Web.Util.PMTUtility.SetUserInfo(String p_UserId) in D:\SourceControl\DEV\Rbc.Gpb.Cap.GpbOnline.Web\PlanManagement\Util\PMTUtility.cs:91
Rbc.Gpb.PlanManagement.Web.Default.SetPlanManagementBaseValues(String userID) in D:\SourceControl\DEV\Rbc.Gpb.Cap.GpbOnline.Web\PlanManagement\Default.aspx.cs:223
Rbc.Gpb.PlanManagement.Web.Default.Page_Load(Object sender, EventArgs e) in D:\SourceControl\DEV\Rbc.Gpb.Cap.GpbOnline.Web\PlanManagement\Default.aspx.cs:60
System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) +15
System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +34
System.EventHandler.Invoke(Object sender, EventArgs e) +0
System.Web.UI.Control.OnLoad(EventArgs e) +99
System.Web.UI.Control.LoadRecursive() +47
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1061

Similar Messages

  • OCIEnvNlsCreate() failed: OCI8+PHP+Linux+Oracle 11g

    Hi All,
    I've been struggling with this since 3 days. I'm getting the following error while using oci_connect:
    Warning: oci_connect(): OCIEnvNlsCreate() failed. There is something wrong with your system - please check that LD_LIBRARY_PATH includes the directory with Oracle Instant Client libraries
    My system configuration:
    PHP : 5.3.3
    OS: Red Hat Enterprise Linux Server release 6.1
    Oracle: 11g
    OCI8: 1.4.9
    My phpInfo() shows that OCI8 is configured with PHP. I did set the LD_LIBRARY_PATH to Instantclient in httpd conf file itself and gave permission 777 just to make sure it's not permission issue. I did not set any ORACLE_HOME because my Oracle database is on a different server.
    Please help!!

    Your post doesn't contain enough detail to identify a cause.
    See Unable load  library '/usr/lib64/php/modules/oci8.so' - libclntsh.so.11.1 It is an example of a post that has good detail.

  • OCIEnvNlsCreate failed with return code -1

    Hi, we're getting this error when running SQL Server 2005 Reporting Services to connect to an Oracle 9i database. The report works fine locally but breaks on the web. Another user has posted about this same exact issue to Microsoft's SSRS forum, but with no answer: http://tinyurl.com/ynqv7o
    Your help is much appreciated. Thank you.

    Check Re: OCIEnvNlsCreate failed with return code -1

  • Warning: ocilogon() [function.ocilogon]: OCIEnvNlsCreate() failed.

    Right now I am getting the following error when I try to connect to any of my Oracle databases:
    Warning: ocilogon() [function.ocilogon]: OCIEnvNlsCreate() failed. There is something wrong with your system - please check that ORACLE_HOME is set and points to the right directory in /var/apache2/htdocs/test2.php on line 17
    I tried connecting to three separate databases with the same result, 10.2.0.2 [Windows Sever 2003], 9.2.0.7 [Solaris 10], 10.2.0.3 [Redhat].
    On my app server [Sun V20z] which is a x86-64 Bit server has the following installed: Solaris 10, Oracle 10.2 Client [Admin option] and PHP 5.2 using Apache2 that installed with Solaris.
    I done quite a bit of reading and can't quite figure out what I'm doing wrong. So if anyone can help me out I would greatly appreciate it.
    Below is how I setup Apache and PHP and how some of my setting are showing up.
    # uname -a
    SunOS sesapp 5.10 Generic_118855-36 i86pc i386 i86pc
    Install libiconv.
    # gunzip -c libiconv-1.9.2.tar | tar -xvf -
    # cd libiconv-1.9.2
    # ./configure
    # make
    # make install
    Install libxml2.
    # gunzip -c libxml2-2.6.26.tar.gz | tar -xvf -
    # cd libxml2-2.6.26
    # ./configure
    # make
    Copy the sample Apache2 configuration file.
    # cp /etc/apache2/httpd.conf-example /etc/apache2/httpd.conf
    # make install
    Install PHP 5.2
    # gunzip -c cd php-5.2.0.tar.gz | tar -xvf -
    # cd php-5.2.0
    # ./configure with-apxs2=/usr/apache2/bin/apxs with-libxml-dir=/usr/local with-config-file-path=/etc/apache2 with-zlib with-oracle=/apps/oracle/product/10.2.0/client with-oci8=/apps/oracle/product/10.2.0/client
    # make
    # make install
    Setup the PHP configuration file.
    # cp php.ini-dist /etc/apache2/php.ini
    Add the following lines to the PHP /etc/apache2/httpd.conf configuration file.
    AddType application/x-httpd-php .php
    Created file /usr/apache2/bin/oraenv [This is for environment paths when apache starts]
    ORACLE_BASE=/apps/oracle
    export ORACLE_BASE
    ORACLE_HOME=/apps/oracle/product/10.2.0/client
    export ORACLE_HOME
    LD_LIBARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib:$ORACLE_HOME
    export LD_LIBARY_PATH
    LD_LIBRARY_PATH=/usr/apache2/lib:$ORACLE_HOME/lib:$ORACLE_HOME
    export LD_LIBRARY_PATH
    TNS_ADMIN=/apps/oracle/product/10.2.0/client/network/admin
    export TNS_ADMIN
    NLS_LANG=AMERICAN_AMERICA.WE8MSWIN1252
    export NLS_LANG
    I then modified /usr/apache2/bin/apachectl and in the "CONFIGURATION SECTION" added:
    if [ -f /usr/apache2/bin/oraenv ] ;
    then
    . /usr/apache2/bin/oraenv
    fi
    Enable Apache2 using the Solaris Management Facility (SMF).
    # svcadm enable apache2
    When I do phpinfo() I get the following bits:
    oci8
    OCI8 Support enabled
    Version 1.2.2
    Revision $Revision: 1.269.2.16.2.25 $
    Active Persistent Connections 0
    Active Connections 0
    Oracle Version 10.1
    Compile-time ORACLE_HOME /apps/oracle/product/10.2.0/client
    Libraries Used no value
    Temporary Lob support enabled
    Collections support enabled
    Directive Local Value Master Value
    oci8.default_prefetch 10 10
    oci8.max_persistent -1 -1
    oci8.old_oci_close_semantics 0 0
    oci8.persistent_timeout -1 -1
    oci8.ping_interval 60 60
    oci8.privileged_connect Off Off
    oci8.statement_cache_size 20 20
    Environment
    Variable Value
    LANG C
    LD_LIBARY_PATH /apps/oracle/product/10.2.0/client/lib:/lib:/usr/lib:/apps/oracle/product/10.2.0/client
    LD_LIBRARY_PATH /usr/apache2/lib:/apps/oracle/product/10.2.0/client/lib:/apps/oracle/product/10.2.0/client
    NLS_LANG AMERICAN_AMERICA.WE8MSWIN1252
    ORACLE_BASE /apps/oracle
    ORACLE_HOME /apps/oracle/product/10.2.0/client
    PATH /usr/sbin:/usr/bin
    SMF_FMRI svc:/network/http:apache2
    SMF_METHOD /lib/svc/method/http-apache2 start
    SMF_RESTARTER svc:/system/svc/restarter:default
    TNS_ADMIN /apps/oracle/product/10.2.0/client/network/admin
    TZ Canada/Mountain
    If there is anything that you can think of that I should try or see something that I screwed up in my conf, please let me know as I am stumped.
    Clayton

    I can confirm that this is an Oracle Client permissions problem. I got frustrated and chmod -R 777 /apps/oracle and sure enough I could connect to all the databases. I know that this isn't a solution so I'll undo this and try and figure out which directories PHP is having a hard time accessing. If I am able to narrow it down I'll post it here. And if someone has done this already can you please post your finding's here.
    Cheers,
    Clayton

  • Oracle oci8 problem: OCIEnvNlsCreate() failed

    Hi to all,
    I have installed Apache 2.4.3, PHP 5.3.21 and Oracle Database 10gR2 on a Windows 2003 server. Please that is installed the complete Oracle DB* and not the only Oracle Client.
    When I run phpinfo This is the result:
    OCI8 Support      enabled
    Version      1.4.9
    Revision      $Id: 44bfa713983a99b3e59477f6532e5fb51b6dee94 $
    Active Persistent Connections      0
    Active Connections      0
    Oracle Run-time Client Library Version      0.0.0.0.0
    Oracle Instant Client Version      10.2
    Temporary Lob support      enabled
    Collections support      enabled
    Directive     Local Value     Master Value
    oci8.connection_class     no value     no value
    oci8.default_prefetch     100     100
    oci8.events     Off     Off
    oci8.max_persistent     -1     -1
    oci8.old_oci_close_semantics     Off     Off
    oci8.persistent_timeout     -1     -1
    oci8.ping_interval     60     60
    oci8.privileged_connect     Off     Off
    oci8.statement_cache_size     20     20I have create a file connect.php in order to test my connection:
    <?php
    $dbHost = "win2003vm";
    $dbHostPort="1521";
    $dbServiceName = "myservice";
    $usr = "myuser";
    $pswd = "mypwd";
    $dbConnStr = "(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)
                (HOST=".$dbHost.")(PORT=".$dbHostPort."))
                (CONNECT_DATA=(SERVICE_NAME=".$dbServiceName.")))";
    if(!$dbConn = oci_connect($usr,$pswd,$dbConnStr)){
    $err = oci_error();
    trigger_error('connection failed: ' . $err['message'], E_USER_ERROR);
    $strSQL = "SELECT SYSDATE FROM DUAL";
    $stmt = oci_parse($dbConn,$strSQL);
    if ( ! oci_execute($stmt) ){
    $err = oci_error($stmt);
    trigger_error('Query failed: ' . $err['message'], E_USER_ERROR);
    while(oci_fetch($stmt)){
        $rslt = oci_result($stmt, 1); print "<h3>Query result: ".$rslt."</h3>";
    ?>But when I run the php file, this error is displayed:
    Warning: oci_connect(): OCIEnvNlsCreate() failed. There is something wrong with your system - please check that PATH includes the directory with Oracle Instant Client libraries in C:\www\win2003vm\connect.php on line 13 Fatal errorCan someone help me ?
    Thank You and best regards
    Gaetano

    The reason the error mentions Instant Client is because this text was
    compiled into the DLL when it was built using Instant Client. You can
    ignore this message phrasing quirk and focus on why OCIEnvNlsCreate()
    failed. Seeing the C code might help explain why the 'wrong' text is
    shown:
         errstatus = OCIEnvNlsCreate(&OCI_G(env), PHP_OCI_INIT_MODE, 0, NULL, NULL, NULL, 0, NULL, 0, 0);
         if (errstatus == OCI_ERROR) {
    #ifdef HAVE_OCI_INSTANT_CLIENT
              php_error_docref(NULL TSRMLS_CC, E_WARNING, "OCIEnvNlsCreate() failed. There is something wrong with your system - please check that " PHP_OCI8_LIB_PATH_MSG " includes the directory with Oracle Instant Client libraries");
    #else
              php_error_docref(NULL TSRMLS_CC, E_WARNING, "OCIEnvNlsCreate() failed. There is something wrong with your system - please check that ORACLE_HOME and " PHP_OCI8_LIB_PATH_MSG " are set and point to the right directories");
    #endifDo you have other Oracle libraries that are causing a library clash?
    Did you reboot after installing? Is there some permission issue with
    the web server environment? Are you using Apache or ISS. Does this
    help:
    https://blogs.oracle.com/opal/entry/how_to_use_iis_php_and_oracle
    Also see "Commonly Seen Connection and Environment Errors" on p 107 of
    http://www.oracle.com/technetwork/topics/php/underground-php-oracle-manual-098250.html
    You may be interested that your $dbConnStr can be simplified. See
    "Easy Connect String" on p 104 of the above book. The variable can be:
    $dbConnStr = "${dbHost}:${dbHostPort}/${dbServiceName}";In fact, since you are using the default port, it could even be just:
    $dbConnStr = "${dbHost}/${dbServiceName}";

  • Oracle Environment Variable Problem - OCIEnvNlsCreate() failed

    We are using PHP 5.2.3 with oci8 version 1.2.3 in CentOS 5.0.
    We have installed Oracle 10g in the same machine where Apache (2.2.3) is running.
    First we tried to set the Oracle environment variable in httpd.conf as
    SetEnv ORACLE_HOME u01/app/..../db_1
    SetEnv ORACLE_SID oratest.
    But we were unable to connect and got the message 'OCIEnvNlsCreate() failed'.
    Then we tried to set the environment variables in root's bash profile.
    Then it did work in PHP command line interface. But it didn't work in browser. Interestingly, getenv function shows the environment variables correctly (even in the browser).
    We also given the read and execute permissions for all users in all directories of oracle. But still it gives the same error.
    Please help.

    While trying to get new oci8 php extension to work I remember trying to set parameters using SetEnv inside apache httpd.conf or inside .htaccess file. However this is not recommended and I remember seeing some suggestions as not to use SetEnv for Oracle environment variables. I also had issues with that before. I went and added bash
    export ORACLE_HOME=... to the Apache startup script in /etc/init.d and this has resolved the problem for me.
    I hope this helps.
    Gena01

  • OCIEnvNlsCreate():Oracle Instant Client libraries

    Pls help solve this error:
    [Mon Feb 18 13:45:14 2008] [error] [client 0.0.0.0] PHP Warning: oci_connect() [function.oci-connect]: OCIEnvNlsCreate() failed. There is something wrong with your system - please check that PATH includes the directory with Oracle Instant Client libraries in C:\\EID_Web\\test.php on line 3
    [Mon Feb 18 13:45:14 2008] [error] [client 0.0.0.0] PHP Warning: oci_close() expects parameter 1 to be resource, boolean given in C:\\EID_Web\\test.php on line 14
    [Mon Feb 18 13:45:18 2008] [error] [client 0.0.0.0] PHP Warning: oci_connect() [function.oci-connect]: OCIEnvNlsCreate() failed. There is something wrong with your system - please check that PATH includes the directory with Oracle Instant Client libraries in C:\\EID_Web\\test.php on line 3
    [Mon Feb 18 13:45:18 2008] [error] [client 0.0.0.0] PHP Warning: oci_close() expects parameter 1 to be resource, boolean given in C:\\EID_Web\\test.php on line 14.
    tried to change the path but still no changes.
    this is what i use:
    apache 2.2,oracle server 10g ,instant client 10g, windows 2000,php 5.2
    Message was edited by:
    tamse

    Make sure that you have only one Oracle Client on the client machine.
    Delete/uninstall all others. Best uninstall all Oracle Software on that machine and reinstall one client.
    Before you try to connect from a PHP script, try to connect with sqlplus. If that works, proceed.
    The PHP you use must compiled and linked against the Oracle client version you use, else it won't work.
    Now try again. If you still get the same errors, post the error messages and relevant parts of the PHP script.
    Be aware that this forum is for Instant Client, so there might be better forums for PHP questions.
    Yours,
    Laurenz Albe

  • Oracle Database 10.2.0.1 + Apache 2.0.59 + PHP 5.2.0

    Hi all.
    Where can i find the changePerm.sh script for Oracle Database 10.2.0.1?
    I get the error:
    Warning: ocilogon() [function.ocilogon]: OCIEnvNlsCreate() failed. There is something wrong with your system - please check that ORACLE_HOME is set and points to the right directory in /usr/local/apache/htdocs/oci8test.php on line 3
    Help me, please!
    Giovanni D'Ascola

    in Apache dir write short file: something.php
    <? phpinfo() ?>
    and access it via browser to see if there is oci defined.
    BTW. when you start apache you should se oracle (oci) variables to get access :-)

  • Oracle OCI CLIENT 11g is not connecting with PHP & Apache on Fedora

    Dear all... we are facing following issue... similar to other but not able to resolve ...
    Warning: oci_connect() [function.oci-connect]: OCIEnvNlsCreate() failed. There is something wrong with your system - please check that LD_LIBRARY_PATH includes the directory with Oracle Instant Client libraries in /var/www/html/waseem2.php on line 2
    our PHPinfo(); is showing following the OCI8 Extenstion Enabled
    PHP Version 5.2.9
    System      Linux localhost.localdomain 2.6.27.5-117.fc10.i686 #1 SMP Tue Nov 18 12:19:59 EST 2008 i686
    Build Date      Apr 17 2009 03:29:46
    Configure Command      './configure' '--build=i386-redhat-linux-gnu' '--host=i386-redhat-linux-gnu' '--target=i386-redhat-linux-gnu' '--program-prefix=' '--prefix=/usr' '--exec-prefix=/usr' '--bindir=/usr/bin' '--sbindir=/usr/sbin' '--sysconfdir=/etc' '--datadir=/usr/share' '--includedir=/usr/include' '--libdir=/usr/lib' '--libexecdir=/usr/libexec' '--localstatedir=/var' '--sharedstatedir=/var/lib' '--mandir=/usr/share/man' '--infodir=/usr/share/info' '--cache-file=../config.cache' '--with-libdir=lib' '--with-config-file-path=/etc' '--with-config-file-scan-dir=/etc/php.d' '--disable-debug' '--with-pic' '--disable-rpath' '--without-pear' '--with-bz2' '--with-curl' '--with-exec-dir=/usr/bin' '--with-freetype-dir=/usr' '--with-png-dir=/usr' '--with-xpm-dir=/usr' '--enable-gd-native-ttf' '--with-t1lib=/usr' '--without-gdbm' '--with-gettext' '--with-gmp' '--with-iconv' '--with-jpeg-dir=/usr' '--with-openssl' '--with-pcre-regex=/usr' '--with-zlib' '--with-layout=GNU' '--enable-exif' '--enable-ftp' '--enable-magic-quotes' '--enable-sockets' '--enable-sysvsem' '--enable-sysvshm' '--enable-sysvmsg' '--enable-wddx' '--with-kerberos' '--enable-ucd-snmp-hack' '--enable-shmop' '--enable-calendar' '--without-mime-magic' '--without-sqlite' '--with-libxml-dir=/usr' '--enable-xml' '--with-system-tzdata' '--with-apxs2=/usr/sbin/apxs' '--without-mysql' '--without-gd' '--disable-dom' '--disable-dba' '--without-unixODBC' '--disable-pdo' '--disable-xmlreader' '--disable-xmlwriter' '--disable-json' '--without-pspell'
    Server API      Apache 2.0 Handler
    Virtual Directory Support      disabled
    Configuration File (php.ini) Path      /etc
    Loaded Configuration File      /etc/php.ini
    Scan this dir for additional .ini files      /etc/php.d
    additional .ini files parsed      /etc/php.d/dbase.ini, /etc/php.d/json.ini, /etc/php.d/ldap.ini, /etc/php.d/mbstring.ini, /etc/php.d/mysql.ini, /etc/php.d/mysqli.ini, /etc/php.d/pdo.ini, /etc/php.d/pdo_mysql.ini, /etc/php.d/pdo_sqlite.ini, /etc/php.d/zip.ini
    PHP API      20041225
    PHP Extension      20060613
    Zend Extension      220060519
    Debug Build      no
    Thread Safety      disabled
    Zend Memory Manager      enabled
    IPv6 Support      enabled
    Registered PHP Streams      php, file, data, http, ftp, compress.bzip2, compress.zlib, https, ftps, zip
    Registered Stream Socket Transports      tcp, udp, unix, udg, ssl, sslv3, sslv2, tls
    Registered Stream Filters      string.rot13, string.toupper, string.tolower, string.strip_tags, convert.*, consumed, convert.iconv.*, bzip2.*, zlib.*
    Zend logo This program makes use of the Zend Scripting Language Engine:
    Zend Engine v2.2.0, Copyright (c) 1998-2009 Zend Technologies
    PHP Credits
    Configuration
    PHP Core
    Directive     Local Value     Master Value
    allow_call_time_pass_reference     Off     Off
    allow_url_fopen     On     On
    allow_url_include     Off     Off
    always_populate_raw_post_data     Off     Off
    arg_separator.input     &     &
    arg_separator.output     &     &
    asp_tags     Off     Off
    auto_append_file     no value     no value
    auto_globals_jit     On     On
    auto_prepend_file     no value     no value
    browscap     no value     no value
    default_charset     no value     no value
    default_mimetype     text/html     text/html
    define_syslog_variables     Off     Off
    disable_classes     no value     no value
    disable_functions     no value     no value
    display_errors     On     On
    display_startup_errors     Off     Off
    doc_root     no value     no value
    docref_ext     no value     no value
    docref_root     no value     no value
    enable_dl     On     On
    error_append_string     no value     no value
    error_log     no value     no value
    error_prepend_string     no value     no value
    error_reporting     6143     6143
    expose_php     On     On
    extension_dir     /usr/lib/php/modules     /usr/lib/php/modules
    file_uploads     On     On
    highlight.bg     #FFFFFF     #FFFFFF
    highlight.comment     #FF8000     #FF8000
    highlight.default     #0000BB     #0000BB
    highlight.html     #000000     #000000
    highlight.keyword     #007700     #007700
    highlight.string     #DD0000     #DD0000
    html_errors     On     On
    ignore_repeated_errors     Off     Off
    ignore_repeated_source     Off     Off
    ignore_user_abort     Off     Off
    implicit_flush     Off     Off
    include_path     .:/usr/share/pear:/usr/share/php     .:/usr/share/pear:/usr/share/php
    log_errors     On     On
    log_errors_max_len     1024     1024
    magic_quotes_gpc     Off     Off
    magic_quotes_runtime     Off     Off
    magic_quotes_sybase     Off     Off
    mail.force_extra_parameters     no value     no value
    max_execution_time     30     30
    max_input_nesting_level     64     64
    max_input_time     60     60
    memory_limit     32M     32M
    open_basedir     no value     no value
    output_buffering     4096     4096
    output_handler     no value     no value
    post_max_size     8M     8M
    precision     14     14
    realpath_cache_size     16K     16K
    realpath_cache_ttl     120     120
    register_argc_argv     Off     Off
    register_globals     Off     Off
    register_long_arrays     Off     Off
    report_memleaks     On     On
    report_zend_debug     On     On
    safe_mode     Off     Off
    safe_mode_exec_dir     no value     no value
    safe_mode_gid     Off     Off
    safe_mode_include_dir     no value     no value
    sendmail_from     no value     no value
    sendmail_path     /usr/sbin/sendmail -t -i     /usr/sbin/sendmail -t -i
    serialize_precision     100     100
    short_open_tag     On     On
    SMTP     localhost     localhost
    smtp_port     25     25
    sql.safe_mode     Off     Off
    track_errors     Off     Off
    unserialize_callback_func     no value     no value
    upload_max_filesize     2M     2M
    upload_tmp_dir     no value     no value
    user_dir     no value     no value
    variables_order     EGPCS     EGPCS
    xmlrpc_error_number     0     0
    xmlrpc_errors     Off     Off
    y2k_compliance     On     On
    zend.ze1_compatibility_mode     Off     Off
    apache2handler
    Apache Version      Apache/2.2.11 (Fedora)
    Apache API Version      20051115
    Server Administrator      root@localhost
    Hostname:Port      localhost.localdomain:0
    User/Group      apache(48)/48
    Max Requests      Per Child: 4000 - Keep Alive: off - Max Per Connection: 100
    Timeouts      Connection: 120 - Keep-Alive: 15
    Virtual Server      No
    Server Root      /etc/httpd
    Loaded Modules      core prefork http_core mod_so mod_auth_basic mod_auth_digest mod_authn_file mod_authn_alias mod_authn_anon mod_authn_dbm mod_authn_default mod_authz_host mod_authz_user mod_authz_owner mod_authz_groupfile mod_authz_dbm mod_authz_default util_ldap mod_authnz_ldap mod_include mod_log_config mod_logio mod_env mod_ext_filter mod_mime_magic mod_expires mod_deflate mod_headers mod_usertrack mod_setenvif mod_mime mod_dav mod_status mod_autoindex mod_info mod_dav_fs mod_vhost_alias mod_negotiation mod_dir mod_actions mod_speling mod_userdir mod_alias mod_rewrite mod_proxy mod_proxy_balancer mod_proxy_ftp mod_proxy_http mod_proxy_connect mod_cache mod_suexec mod_disk_cache mod_file_cache mod_mem_cache mod_cgi mod_perl mod_php5 mod_proxy_ajp mod_python mod_ssl
    Directive     Local Value     Master Value
    engine     1     1
    last_modified     0     0
    xbithack     0     0
    Apache Environment
    Variable     Value
    LD_LIBRARY_PATH      /home/zubair/instantclient_11_1_
    HTTP_HOST      localhost
    HTTP_USER_AGENT      Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.0.4) Gecko/2008111217 Fedora/3.0.4-1.fc10 Firefox/3.0.4
    HTTP_ACCEPT      text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
    HTTP_ACCEPT_LANGUAGE      en-us,en;q=0.5
    HTTP_ACCEPT_ENCODING      gzip,deflate
    HTTP_ACCEPT_CHARSET      ISO-8859-1,utf-8;q=0.7,*;q=0.7
    HTTP_KEEP_ALIVE      300
    HTTP_CONNECTION      keep-alive
    HTTP_COOKIE      PHPSESSID=he50pdhvtihu74lhmjnvggfr42
    PATH      /sbin:/usr/sbin:/bin:/usr/bin
    SERVER_SIGNATURE      <address>Apache/2.2.11 (Fedora) Server at localhost Port 80</address>
    SERVER_SOFTWARE      Apache/2.2.11 (Fedora)
    SERVER_NAME      localhost
    SERVER_ADDR      127.0.0.1
    SERVER_PORT      80
    REMOTE_ADDR      127.0.0.1
    DOCUMENT_ROOT      /var/www/html
    SERVER_ADMIN      root@localhost
    SCRIPT_FILENAME      /var/www/html/waseem.php
    REMOTE_PORT      39529
    GATEWAY_INTERFACE      CGI/1.1
    SERVER_PROTOCOL      HTTP/1.1
    REQUEST_METHOD      GET
    QUERY_STRING      no value
    REQUEST_URI      /waseem.php
    SCRIPT_NAME      /waseem.php
    HTTP Headers Information
    HTTP Request Headers
    HTTP Request      GET /waseem.php HTTP/1.1
    Host      localhost
    User-Agent      Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.0.4) Gecko/2008111217 Fedora/3.0.4-1.fc10 Firefox/3.0.4
    Accept      text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
    Accept-Language      en-us,en;q=0.5
    Accept-Encoding      gzip,deflate
    Accept-Charset      ISO-8859-1,utf-8;q=0.7,*;q=0.7
    Keep-Alive      300
    Connection      keep-alive
    Cookie      PHPSESSID=he50pdhvtihu74lhmjnvggfr42
    HTTP Response Headers
    X-Powered-By      PHP/5.2.9
    Connection      close
    Transfer-Encoding      chunked
    Content-Type      text/html; charset=UTF-8
    bz2
    BZip2 Support      Enabled
    Stream Wrapper support      compress.bz2://
    Stream Filter support      bzip2.decompress, bzip2.compress
    BZip2 Version      1.0.5, 10-Dec-2007
    calendar
    Calendar support      enabled
    ctype
    ctype functions      enabled
    curl
    cURL support      enabled
    cURL Information      libcurl/7.18.2 NSS/3.12.1.1 zlib/1.2.3 libidn/0.6.14 libssh2/0.18
    date
    date/time support      enabled
    "Olson" Timezone Database Version      0.system
    Timezone Database      internal
    Default timezone      Asia/Karachi
    Directive     Local Value     Master Value
    date.default_latitude     31.7667     31.7667
    date.default_longitude     35.2333     35.2333
    date.sunrise_zenith     90.583333     90.583333
    date.sunset_zenith     90.583333     90.583333
    date.timezone     no value     no value
    exif
    EXIF Support      enabled
    EXIF Version      1.4 $Id: exif.c,v 1.173.2.5.2.27 2008/12/31 11:17:37 sebastian Exp $
    Supported EXIF Version      0220
    Supported filetypes      JPEG,TIFF
    filter
    Input Validation and Filtering      enabled
    Revision      $Revision: 1.52.2.45 $
    Directive     Local Value     Master Value
    filter.default     unsafe_raw     unsafe_raw
    filter.default_flags     no value     no value
    ftp
    FTP support      enabled
    gettext
    GetText Support      enabled
    gmp
    gmp support      enabled
    GMP version      4.2.2
    hash
    hash support      enabled
    Hashing Engines      md2 md4 md5 sha1 sha256 sha384 sha512 ripemd128 ripemd160 ripemd256 ripemd320 whirlpool tiger128,3 tiger160,3 tiger192,3 tiger128,4 tiger160,4 tiger192,4 snefru gost adler32 crc32 crc32b haval128,3 haval160,3 haval192,3 haval224,3 haval256,3 haval128,4 haval160,4 haval192,4 haval224,4 haval256,4 haval128,5 haval160,5 haval192,5 haval224,5 haval256,5
    iconv
    iconv support      enabled
    iconv implementation      glibc
    iconv library version      2.9
    Directive     Local Value     Master Value
    iconv.input_encoding     ISO-8859-1     ISO-8859-1
    iconv.internal_encoding     ISO-8859-1     ISO-8859-1
    iconv.output_encoding     ISO-8859-1     ISO-8859-1
    json
    json support      enabled
    json version      1.2.1
    ldap
    LDAP Support      enabled
    RCS Version      $Id: ldap.c,v 1.161.2.3.2.14 2008/12/31 11:17:39 sebastian Exp $
    Total Links      0/unlimited
    API Version      3001
    Vendor Name      OpenLDAP
    Vendor Version      20412
    SASL Support      Enabled
    libxml
    libXML support      active
    libXML Version      2.7.3
    libXML streams      enabled
    mbstring
    Multibyte Support      enabled
    Multibyte string engine      libmbfl
    Multibyte (japanese) regex support      enabled
    Multibyte regex (oniguruma) version      4.4.4
    Multibyte regex (oniguruma) backtrack check      On
    mbstring extension makes use of "streamable kanji code filter and converter", which is distributed under the GNU Lesser General Public License version 2.1.
    Directive     Local Value     Master Value
    mbstring.detect_order     no value     no value
    mbstring.encoding_translation     Off     Off
    mbstring.func_overload     0     0
    mbstring.http_input     pass     pass
    mbstring.http_output     pass     pass
    mbstring.internal_encoding     no value     no value
    mbstring.language     neutral     neutral
    mbstring.strict_detection     Off     Off
    mbstring.substitute_character     no value     no value
    mysql
    MySQL Support     enabled
    Active Persistent Links      0
    Active Links      0
    Client API version      5.0.84
    MYSQL_MODULE_TYPE      external
    MYSQL_SOCKET      /var/lib/mysql/mysql.sock
    MYSQL_INCLUDE      -I/usr/include/mysql
    MYSQL_LIBS      -L/usr/lib/mysql -lmysqlclient
    Directive     Local Value     Master Value
    mysql.allow_persistent     On     On
    mysql.connect_timeout     60     60
    mysql.default_host     no value     no value
    mysql.default_password     no value     no value
    mysql.default_port     no value     no value
    mysql.default_socket     no value     no value
    mysql.default_user     no value     no value
    mysql.max_links     Unlimited     Unlimited
    mysql.max_persistent     Unlimited     Unlimited
    mysql.trace_mode     Off     Off
    mysqli
    MysqlI Support     enabled
    Client API library version      5.0.84
    Client API header version      5.0.77
    MYSQLI_SOCKET      /var/lib/mysql/mysql.sock
    Directive     Local Value     Master Value
    mysqli.default_host     no value     no value
    mysqli.default_port     3306     3306
    mysqli.default_pw     no value     no value
    mysqli.default_socket     no value     no value
    mysqli.default_user     no value     no value
    mysqli.max_links     Unlimited     Unlimited
    mysqli.reconnect     Off     Off
    oci8
    OCI8 Support      enabled
    Version      1.3.5
    Revision      $Revision: 1.269.2.16.2.38.2.32 $
    Active Persistent Connections      0
    Active Connections      0
    Oracle Instant Client Version      11.1
    Temporary Lob support      enabled
    Collections support      enabled
    Directive     Local Value     Master Value
    oci8.connection_class     no value     no value
    oci8.default_prefetch     100     100
    oci8.events     Off     Off
    oci8.max_persistent     -1     -1
    oci8.old_oci_close_semantics     Off     Off
    oci8.persistent_timeout     -1     -1
    oci8.ping_interval     60     60
    oci8.privileged_connect     Off     Off
    oci8.statement_cache_size     20     20
    openssl
    OpenSSL support      enabled
    OpenSSL Version      OpenSSL 0.9.8g 19 Oct 2007
    pcre
    PCRE (Perl Compatible Regular Expressions) Support      enabled
    PCRE Library Version      7.8 2008-09-05
    Directive     Local Value     Master Value
    pcre.backtrack_limit     100000     100000
    pcre.recursion_limit     100000     100000
    PDO
    PDO support     enabled
    PDO drivers      mysql, sqlite
    pdo_mysql
    PDO Driver for MySQL, client library version     5.0.84
    pdo_sqlite
    PDO Driver for SQLite 3.x     enabled
    PECL Module version      1.0.1 $Id: pdo_sqlite.c,v 1.10.2.6.2.4 2008/12/31 11:17:42 sebastian Exp $
    SQLite Library      3.5.9
    posix
    Revision      $Revision: 1.70.2.3.2.22 $
    Reflection
    Reflection     enabled
    Version      $Id: php_reflection.c,v 1.164.2.33.2.55 2008/12/31 11:17:42 sebastian Exp $
    session
    Session Support      enabled
    Registered save handlers      files user
    Registered serializer handlers      php php_binary wddx
    Directive     Local Value     Master Value
    session.auto_start     Off     Off
    session.bug_compat_42     Off     Off
    session.bug_compat_warn     On     On
    session.cache_expire     180     180
    session.cache_limiter     nocache     nocache
    session.cookie_domain     no value     no value
    session.cookie_httponly     Off     Off
    session.cookie_lifetime     0     0
    session.cookie_path     /     /
    session.cookie_secure     Off     Off
    session.entropy_file     no value     no value
    session.entropy_length     0     0
    session.gc_divisor     1000     1000
    session.gc_maxlifetime     1440     1440
    session.gc_probability     1     1
    session.hash_bits_per_character     5     5
    session.hash_function     0     0
    session.name     PHPSESSID     PHPSESSID
    session.referer_check     no value     no value
    session.save_handler     files     files
    session.save_path     /var/lib/php/session     /var/lib/php/session
    session.serialize_handler     php     php
    session.use_cookies     On     On
    session.use_only_cookies     Off     Off
    session.use_trans_sid     0     0
    shmop
    shmop support      enabled
    SimpleXML
    Simplexml support     enabled
    Revision      $Revision: 1.151.2.22.2.46 $
    Schema support      enabled
    sockets
    Sockets Support      enabled
    SPL
    SPL support     enabled
    Interfaces      Countable, OuterIterator, RecursiveIterator, SeekableIterator, SplObserver, SplSubject
    Classes      AppendIterator, ArrayIterator, ArrayObject, BadFunctionCallException, BadMethodCallException, CachingIterator, DirectoryIterator, DomainException, EmptyIterator, FilterIterator, InfiniteIterator, InvalidArgumentException, IteratorIterator, LengthException, LimitIterator, LogicException, NoRewindIterator, OutOfBoundsException, OutOfRangeException, OverflowException, ParentIterator, RangeException, RecursiveArrayIterator, RecursiveCachingIterator, RecursiveDirectoryIterator, RecursiveFilterIterator, RecursiveIteratorIterator, RecursiveRegexIterator, RegexIterator, RuntimeException, SimpleXMLIterator, SplFileInfo, SplFileObject, SplObjectStorage, SplTempFileObject, UnderflowException, UnexpectedValueException
    standard
    Regex Library      Bundled library enabled
    Dynamic Library Support      enabled
    Path to sendmail      /usr/sbin/sendmail -t -i
    Directive     Local Value     Master Value
    assert.active     1     1
    assert.bail     0     0
    assert.callback     no value     no value
    assert.quiet_eval     0     0
    assert.warning     1     1
    auto_detect_line_endings     0     0
    default_socket_timeout     60     60
    safe_mode_allowed_env_vars     PHP_     PHP_
    safe_mode_protected_env_vars     LD_LIBRARY_PATH     LD_LIBRARY_PATH
    url_rewriter.tags     a=href,area=href,frame=src,input=src,form=fakeentry     a=href,area=href,frame=src,input=src,form=fakeentry
    user_agent     no value     no value
    sysvmsg
    sysvmsg support      enabled
    Revision      $Revision: 1.20.2.3.2.8 $
    tokenizer
    Tokenizer Support      enabled
    wddx
    WDDX Support     enabled
    WDDX Session Serializer      enabled
    xml
    XML Support      active
    XML Namespace Support      active
    libxml2 Version      2.7.3
    zip
    Zip      enabled
    Extension Version      $Id: php_zip.c,v 1.1.2.49 2009/02/05 19:53:22 pajoye Exp $
    Zip version      1.8.11
    Libzip version      0.9.0
    zlib
    ZLib Support      enabled
    Stream Wrapper support      compress.zlib://
    Stream Filter support      zlib.inflate, zlib.deflate
    Compiled Version      1.2.3
    Linked Version      1.2.3
    Directive     Local Value     Master Value
    zlib.output_compression     Off     Off
    zlib.output_compression_level     -1     -1
    zlib.output_handler     no value     no value
    Additional Modules
    Module Name
    dbase
    sysvsem
    sysvshm
    Environment
    Variable     Value
    TERM      xterm
    LD_LIBRARY_PATH      /home/zubair/instantclient_11_1/
    PATH      /sbin:/usr/sbin:/bin:/usr/bin
    PWD      /
    LANG      C
    SHLVL      2
    ORACLE_HOME      /home/zubair/instantclient_11_1/
    _      /usr/sbin/httpd
    PHP Variables
    Variable     Value
    _REQUEST["PHPSESSID"]     he50pdhvtihu74lhmjnvggfr42
    _COOKIE["PHPSESSID"]     he50pdhvtihu74lhmjnvggfr42
    SERVER["LDLIBRARY_PATH"]     /home/zubair/instantclient_11_1
    _SERVER["HTTP_HOST"]     localhost
    _SERVER["HTTP_USER_AGENT"]     Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.0.4) Gecko/2008111217 Fedora/3.0.4-1.fc10 Firefox/3.0.4
    _SERVER["HTTP_ACCEPT"]     text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
    _SERVER["HTTP_ACCEPT_LANGUAGE"]     en-us,en;q=0.5
    _SERVER["HTTP_ACCEPT_ENCODING"]     gzip,deflate
    _SERVER["HTTP_ACCEPT_CHARSET"]     ISO-8859-1,utf-8;q=0.7,*;q=0.7
    _SERVER["HTTP_KEEP_ALIVE"]     300
    _SERVER["HTTP_CONNECTION"]     keep-alive
    _SERVER["HTTP_COOKIE"]     PHPSESSID=he50pdhvtihu74lhmjnvggfr42
    _SERVER["PATH"]     /sbin:/usr/sbin:/bin:/usr/bin
    _SERVER["SERVER_SIGNATURE"]     <address>Apache/2.2.11 (Fedora) Server at localhost Port 80</address>
    _SERVER["SERVER_SOFTWARE"]     Apache/2.2.11 (Fedora)
    _SERVER["SERVER_NAME"]     localhost
    _SERVER["SERVER_ADDR"]     127.0.0.1
    _SERVER["SERVER_PORT"]     80
    _SERVER["REMOTE_ADDR"]     127.0.0.1
    _SERVER["DOCUMENT_ROOT"]     /var/www/html
    _SERVER["SERVER_ADMIN"]     root@localhost
    _SERVER["SCRIPT_FILENAME"]     /var/www/html/waseem.php
    _SERVER["REMOTE_PORT"]     39529
    _SERVER["GATEWAY_INTERFACE"]     CGI/1.1
    _SERVER["SERVER_PROTOCOL"]     HTTP/1.1
    _SERVER["REQUEST_METHOD"]     GET
    _SERVER["QUERY_STRING"]     no value
    _SERVER["REQUEST_URI"]     /waseem.php
    _SERVER["SCRIPT_NAME"]     /waseem.php
    _SERVER["PHP_SELF"]     /waseem.php
    _SERVER["REQUEST_TIME"]     1253301146
    _ENV["TERM"]     xterm
    _ENV["LD_LIBRARY_PATH"]     /home/zubair/instantclient_11_1/
    _ENV["PATH"]     /sbin:/usr/sbin:/bin:/usr/bin
    _ENV["PWD"]     /
    _ENV["LANG"]     C
    _ENV["SHLVL"]     2
    _ENV["ORACLE_HOME"]     /home/zubair/instantclient_11_1/
    _ENV["_"]     /usr/sbin/httpd
    PHP License
    This program is free software; you can redistribute it and/or modify it under the terms of the PHP License as published by the PHP Group and included in the distribution in the file: LICENSE
    This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
    If you did not receive a copy of the PHP license, or have any questions about PHP licensing, please contact [email protected].
    Have a nice day!
    Fatal error: Call to undefined function odbc_connect() in /var/www/html/waseem.php on line 20
    ------------------------------------------------------------------------------------------

    Is the problem with oci_connect or odbc_connect?
    The phpinfo() output shows '--without-unixODBC' which may be a root cause. There is no 'odbc' section shown in the phpinfo() output so I wouldn't expect odbc calls to work.
    But if the issue is with OCI8, then make sure that Oracle environment variables and LD_LIBRARY_PATH are set BEFORE starting Apache.
    More information on OCI8 and PHP is in http://www.oracle.com/technology/tech/php/underground-php-oracle-manual.html
    Also see http://wiki.oracle.com/page/PHP+Oracle+FAQ
    The PHP forum on OTN is http://www.oracle.com/technology/forums/php.html

  • OpenSUSE 11.1 (x86_64) Apache2 PHP Oracle !oci_connect

    Hi all,
    can't connect to an oracle instance oci_connect()
    Warning: oci_connect(): OCIEnvNlsCreate() failed. There is something wrong with your system - please check that ORACLE_HOME and LD_LIBRARY_PATH are set and point to the right directories in /srv/www/htdocs/ora/index.php on line 3
    System:
    openSUSE 11.1 (x86_64)
    PHP Version 5.2.11
    OCI 1.4.0 Alpha $Revision: 1.269.2.16.2.38.2.32 $
    Compile-time ORACLE_HOME: opt/oracle/product/10.2.0/db_1
    Libraries Used: -Wl,-rpath,/opt/oracle/product/10.2.0/db_1/lib -L/opt/oracle/product/10.2.0/db_1/lib -lclntsh
    set | grep ora
    ORACLE_BASE=/opt/oracle
    ORACLE_HOME=/opt/oracle/product/10.2.0/db_1
    ORA_ASM_HOME=/opt/oracle/product/10gR2/asm
    ORA_CRS_HOME=/opt/oracle/product/10gR2/crs
    PATH=/home/user/bin:/usr/local/bin:/usr/bin:/sbin:/usr/sbin:/bin:/usr/bin/X11:/usr/X11R6/bin:/usr/games:/opt/kde3/bin:/usr/lib64/jvm/jre/bin:/usr/lib/mit/bin:/usr/lib/mit/sbin:/opt/novell/ncl/bin:/opt/oracle/product/10.2.0/db_1/bin
                   decorate diff-filter=
    Does anyone has an ideer why the connection can't established.
    Best regards
    Till

    sorry....
    Workaround: add the apache user to the oracle group. This only occurs
    in 5.2.1. Previous versions of PHP which I've tried (5.0.3 and 5.1.0)
    did not have this problem. Obviously this is a security issue as the
    apache user now has a lot more things it can use to wreak havoc.

  • Linux CentOS 4.4 + Oracle Database 10.2.0.1 + Apache 2.0.59 + PHP 5.2.0

    Hi.
    I get this error:
    Warning: ocilogon() [function.ocilogon]: OCIEnvNlsCreate() failed. There is something wrong with your system - please check that ORACLE_HOME is set and points to the right directory in /usr/local/apache/htdocs/oci8test.php on line 3
    Can you help me?

    Marcello, i've already read that documentation:
    "[...] Note: If you are using Oracle 10.2 but not the Express Edition, you must give the "nobody" user access to the Oracle directory. With Oracle 10.2.0.2 there is a script $ORACLE_HOME/install/changePerm.sh to do this."
    With Oracle 10.2.0.2... but with 10.2.0.1?
    I made "nobody" user member of the "oinstall" group (bad idea, i know), but still it doesn't works...

  • Solaris PHP 5.2.12 Oracle Instant Client Error

    We are testing a Oracle Solaris Express 11 Server with the standard Apache and PHP installation. But we need the Oracle Instant client and the oci8 module enabled for our company applications.
    We did this by using ./pecl install oci8 in /usr/php/5.2/bin. We set the LD_LIBRARY_PATH in /etc/apache2/2.2/envvars
    a 32bits solaris (x86) version of the Oracle Instant Client 11.2 is installed in /opt/oracle/instantclient_11_2 with the symbolic link made.
    envvars:
    LD_LIBRARY_PATH=/opt/oracle/instantclient_11_2
    ORACLE_HOME=/opt/oracle/instantclient_11_2
    ORACLE_BASE=/opt/oracle/instantclient_11_2
    he oci8 module installed and php loads it.
    phpinfo(); output:
    oci8
    OCI8 Support enabled
    Version 1.4.6
    Revision $Revision: 313688 $
    Active Persistent Connections 0
    Active Connections 0
    Oracle Run-time Client Library Version 11.2.0.2.0
    Oracle Instant Client Version 11.2
    Temporary Lob support enabled
    When we first view a site there is no problem but very randomly we get the following error:
    OCIEnvNlsCreate() failed. There is something wrong with your system - please check that LD_LIBRARY_PATH includes the directory with Oracle Instant Client libraries*
    but when we use echo getenv("LD_LIBRARY_PATH"); in php the output is "/opt/oracle/instantclient_11_2"
    now the strange this is as randomly as it appears it disappears we can load the web-page without problems and after a couple of clicks the error is back. if we wait a coupe of seconds you can reload the page and it loads normaly.
    The error appears to be random and we get it over and over agian, it comes and goes after a cpl of pages are viewed. It seems to appear more when there are multiple users browsing on the website.
    Is there a fix for this? is this an known bug? It seems strange the instant client works some times and fails a second later without a change in the system.
    Hope someone can help us.
    Edited by: user10978378 on Sep 3, 2011 4:20 AM

    Solved it by compiling apache 2.2.20 into 64bits using:
    CFLAGS="-m64" CXXFLAGS="-m64" LDFLAGS="-m64" ./configure enable-so enable-cgi enable-info enable-rewrite enable-deflate enable-ssl
    and compiling php 5.3.8 into 64bits:
    CFLAGS="-m64" CXXFLAGS="-m64" LDFLAGS="-m64" ./configure with-apxs2=/usr/local/apache2/bin/apxs with-gd with-zlib disable-ipv6 with-jpeg-dir=/usr/ with-png-dir=/usr/ with-freetype-dir=/usr/ with-pear with-openssl with-oci8=instantclient,/opt/oracle/instantclient_10_2
    and using the 10.2.0.4 instant client.
    there might be a bug in the 11.x ones, they dont seem to work on Oracle Solaris 11.

  • Linux: Preferred method to link / locate libclnt(sh)?

    I am working with a lot of cross-platform software (Linux + Windows). Part of the software uses OCI, but up to now only on Windows. Now I complied for Linux, and after not much work, it is operating. But I am not sure whether I am on the right trail with linking to $ORACLE_HOME/lib/libclntsh.so.
    My doubts:
    • My database tool is 0.6 MB, libclntsh.so.12.1 is 57.4 MB. Oooops???
    • I linked to $ORACLE_HOME/lib/libclntsh.so (that is a link to libclntsh.so.12.1). Now my program searches for libclntsh.so.12.1 at run-time. That isn't portable!
    • If I link to the static library, the manuals say, I have to rebuild the static library with each version, and I have to re-link with each db version. So I get m x n versions of my software.
    • After the standard installation, each and every user using the tool must have an environment set, at least ORACLE_HOME. If not, my tool seems to find the .so (maybe from /etc/ld.so.cache?), but the first call OCIEnvNlsCreate() fails, and since there is no handle for error description, it tells me that there is no chance to get the error description. With ORACLE_HOME, it works fine.
    • The client installation didn't leave libclntsh.so in /lib, /lib64 or /usr/lib64 or any such directory. This seems to match the concept "You may install different clients at the same time."
    • My $ORACLE_HOME/lib/libclntst12.a is of size zero. Why???
    I have a plan I am about to try, but before I try the hard way, I would like to ask for your experience. Here is my plan:
    • Check the environment for $ORACLE_HOME, and throw an error, if it isn't defined.
    • Use using dlopen() to load $ORACLE_HOME/lib/libclntsh.so at run-time (instead of load-time!).
    • Retrieve addresses of the functions by dlsym().
    • Call OCI functions indirectly.
    Is this plan OK?
    Which other options are there, and which approach is the "commonly used"?
    Would it be good to use the oldest/newest static library, can it be used with any ORACLE_HOME? Surely not...
    I have tried to google information about it, but I only found an overwhelming lot of installation issues. Everybody is installing products which don't find the correct .so file — this is exactly what I am trying to avoid.
    Thank you very much in advance for a short notice.

    First of all: Thank you very much. I have investigated more.
    About ORACLE_HOME: You are right, it isn't necessary.
    In a Windows environment, I have never had any need to set ORACLE_HOME. This is probably due to the fact that I use Windows as TNS client only, and I cannot connect to the linux server using IPC. So I don't use Windows in a wide variety...
    I have been mislead by some strange output from oracle tools on the linux server when ORACLE_HOME is not set. My tool does not need an ORACLE_HOME.
    About linking to libclntsh.so: You are wrong, this is restricting the tool to a Version 12 client (as long as I am developing with a V12 client).
    The client 12 installation is creating links "libclntsh.so.10.1" and "libclntsh.so.11.1" to support older software. But the client 10 installation does not create a link "libclntsh.so.12.1" to support newer software.
    Even if I rename libclntsh.so.12.1 to libclntsh.so and link with it, my linked software searches "libclntsh.so.12.1" — which is the wrong concept. Please have in mind: The link "libclntsh.so" is created by the installation to make sure the library can be found as "libclntsh.so". Hence, my software must search for "libclntsh.so", not for "libclntsh.so.12.1".
    I am not much an expert with shared objects on Linux, but I guess Oracle did the mistake to build a "libclntsh.so.12.1" directly — instead of building a "libclntsh.so" and renaming it to "libclntsh.so.12.1"?
    So my plan has changed:
    • Don't throw an error, if $ORACLE_HOME isn't defined.
    • If $ORACLE_HOME is set: Use dlopen() to load $ORACLE_HOME/lib/libclntsh.so at run-time.
    • If $ORACLE_HOME is not set: Use dlopen() to load libclntsh.so at run-time.
    • Retrieve addresses of the functions by dlsym().
    • Call OCI functions indirectly.
    This should be working well for Linux — and for Windows with $ORACLE_HOME/bin/oci.dll, respectively.

  • Instant Client not working on Windows Server 2003

    Hi everybody,
    I have installed the Instant Client libraries on a machine running Windows Server 2003 in order to connect to a remote Oracle server. I also installed the sqlplus package. I copied them in a local directory, updated the Environment variable PATH and restarted. When I try to execute sqlplus to test if everything works fine, I get the following errors:
    sqlplus user/[email protected]:1521/orcl
    SP2-1503: Unable to initialize Oracle call interface
    SP2-0152: ORACLE may not be functioning properly
    Also, when I try to use PHP OCI8 functions like oci_connect() I get an error like:
    PHP Warning: oci_connect() [function.oci-connect]: OCIEnvNlsCreate() failed. There is something wrong with your system - please check that PATH includes the directory with Oracle Instant Client libraries
    I checked it and the PATH variable points to the instant client libraries.
    Any ideas?
    Thanks in advance!

    I get the following errors: sqlplus user/[email protected]:1521/orcl SP2-1503: Unable to initialize Oracle call interface SP2-0152: ORACLE may not be functioning properly Also, when I try to use PHP OCI8 functions like oci_connect......Like the error suggested, the instant client libraries does not include the Network Service required by SQLPLUS.
    The connect string you are trying to use doesn't work for SQLPLUS. SQLPLUS will need proper TNS names configured.
    In another words, instanct client libraries installation is not enough to use sqlplus. Use Runtime installation or Customized installation.

  • Instant client on windows 2000, path problems

    I have successfully installed the client and all work fine. But from time to time for no apparent reason php script gives an error
    "Warning oci_connect (): OCIEnvNlsCreate () failed. There is something wrong with your system - please check that PATH includes the directory with Oracle Instant Client libraries."
    I checked the environment variables, they are correct.
    If you restart Apache, everything starts to work fine. What may be the problem?
    (sorry for my English, it's not my native language)

    I agree, but this is for the QA group and they generally test the app and access the DB using app only but now for some certain modules they want to check the data in the database but they dont know how to write SQL so they decided to use microsoft sql writer (I never used it :) ) and for that they want to setup odbc and for that they need client, so they are not going to use sqlplus and that why I just wanna install instant client on their desktops.
    Daljit Singh

Maybe you are looking for

  • Single Student home directory for Multiple users

    Hi all, I'm currently working in an education environment and we have 4x labs of mac's. Currently, when students log in, their login info/permissions are pulled from AD and OD. When they login for the first time, it creates a local home directory wit

  • Display only - losing data

    I am using apex 4 I have a page item that is display only. It gets populated dynamically as the user enters data.... works fine. However, during the validation process if there is a validation failure page returns it 'loses' its data. I have set the

  • How can I use two fonts in swing components?

    I want to implement a project. When a part of the JMenuBar, JButton or other swing components' text is English, I use Tahoma font, and other of these components' text is Chinese, I use SimSun font, just like the Chinese Windows OS. How can I implemen

  • Every second G-note is missed by Logic Express

    Hi, I have really strange problem: logic express misses every second G-note (two octaves down from middle-C) that I press from MIDI-keyboard. It also misses all G-notes if I press something before the G-note. This is not a keyboard problem: I have fo

  • Maximum number of rows export to excel from WebI

    Hello, I have a WebI Report in BO 4 SP6 which has 14 columns and 80,000 rows. I opened the report in WebI (Internet explorer) and clicked on the export icon but nothing happened. this report was being run for a month 201301. So I modified the same re