473,796 Members | 2,583 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

PHP + OCI8 not working(error ": OCIEnvNlsCreate () failed + ORACLE_HOME not right")

2 New Member
Hi All,

I am new to this world of php. I tried getting oci8 work with php but to no avail. The error i recieve is "Warning: ocilogon() [function.ocilog on]: OCIEnvNlsCreate () failed. There is something wrong with your system - please check that ORACLE_HOME is set and points to the right directory". My Oracle version is 10.2.0 and php version is 5.1.6

I have set the following environment variables:
ORACLE_HOME, TNS_ADMIN, NLS_LANG,LD_LIB RARY_PATH
in the following places
a)/etc/sysconfig/httpd
b)/etc/httpd/conf/httpd.conf
c)in the script itself
I have tried adding oinstall group to apache user but it didn't wotk either.

I am able to connect to oracle with sqlplus and I am also able to get phpinfo() working. I don't know where the problem lies.
I suspect that php is not able to ceate n oracle environment in order to run different oracle based commands in php. As last measure, I also added the above 4 variables in /etc/profile(which is available to all the users) but still it didn't work.

Can anyone please guide me in order to resolve this error.
Thanks
Ravinder
Apr 25 '07 #1
0 3127

Sign in to post your reply or Sign up for a free account.

Similar topics

0
1936
by: sztonix | last post by:
Hi all, I encountered a crystal report deployment problem. I make reports with Crystal Report for Visual Studio .NET 2003. It works fine in the development machine. And then make setup package. Installed on a windows server 2003 system (without visual studio .net 2003), the report gives error about "Logon Failed". The data source is specified to OLE DB SQL Server, and the LogOnInfo is specified by
4
396
by: Jerry Higgins | last post by:
I added a SqlDataAdapter to a web form, created a data connection, and generated a dataset. I then connected it to a DataGrid control. When I do this using the SqlServer database on my machine everything works fine. When I do it using a SqlServer database on another machine I get the "Login failed for user sa" error. However, when I right click on the SqlDataAdapter and click "Preview Data" it brings back the data OK. Why would it...
1
2285
by: John Dalberg | last post by:
Running Crystal Reports with the hotfixes and patches & VS 2003. I created a CR report on my development server which has SQL Server. The report runs fine inside Visual Studio. When I switched the source of the DB to the production server using the 'set location' option in CR and ran the app again, I get "Logon Failed" error message. The database wizard worked fine so this tells me CR was able to connect and retrieve the schema from the...
4
28129
by: cyrano | last post by:
I am having issues maintaining an oracle connection in my apache/php web application. I am able to succesfully connect to an Oracle 9i dbase using oci() and retrieve expected results for the first couple of attempts - then it dies with a msg in the apache error_log that looks like: PHP Warning: ocilogon() : OCIEnvNlsCreate() failed. There is something wrong with your system - please check that ORACLE_HOME is set and points to the...
0
2407
by: sreejith.ram | last post by:
I did google & search in this group , but couldnt find any thing related to this. This is my first attempt to connect GridView to a Oracle database via SqlDataSource. I am receving error message "OCIEnvNlsCreate failed with return code -1 but error message text was not available" Any one seen this or anything similar? Thank you in advance for all tips,suggestions,advices & helps
2
25826
by: JuliouZ | last post by:
Warning: ocilogon() : OCIEnvNlsCreate() failed. There is something wrong with your system - please check that ORACLE_HOME is set and points to the right directory in /web/htdocs/test.php on line 6 Oracle Connect Error my file test.php : <?php PutEnv("ORACLE_SID=TEST"); PutEnv("ORACLE_HOME=/oracle/ora102"); PutEnv("TNS_ADMIN=/oracle/ora102/network/admin");
0
1712
by: egyptian2007 | last post by:
dear all this is my first time in this fourm, i want your help urgently, when i made a connection to oracle 10g, php, ms4w i got that error (Warning: : msDrawMap(): Failed to draw layer named '....') i don\t know what is the problem while connecting to the oracle, my code in the map file is LAYER CONNECTIONTYPE oraclespatial CONNECTION "usr/pass@srv" NAME "xxx" TYPE POLYGON STATUS ON UNITS METERS
0
2195
by: sa6113 | last post by:
I am using this code to connect to a windows machine using paramiko, I have installed sshd on the machine and it works properly: sock.connect((hostname, port)) t = paramiko.Transport(sock) event = threading.Event() t.start_client(event) event.wait() if not t.is_active(): print 'SSH negotiation failed.'
1
2920
by: madan agarwal | last post by:
Hi all, My sql 2000 set up failed with the error SQL setup failed with the error "LoadLibrary failed on sqlsrs.rll" Please help .... Thanks in advavance
0
9680
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9528
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10455
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
10173
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9052
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
6788
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5441
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5573
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4116
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.