php-db | 2000121
Date: 12/13/00
- Next message: Miles Thompson: "Re: [PHP-DB] Update problems"
- Previous message: Richard Allsebrook: "RE: [PHP-DB] Update problems"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Hi,
I've got a machine running Solaris 2.7. On this machine I have installed Apache 1.3.14 (with mod_ssl), Oracle 8.1.6 (complete server) and PHP 4.0.3pl1. Installation went perfect and everything seems to be working. I can connect to the local Oracle-database using OCILogin.
Now I need to connect to an Oracle-database which is located on an other machine. I have added a section for that database to my tnsnames.ora but when trying to connect from PHP I only get 'Warning: _oci_open_server: ORA-12154: TNS:could not resolve service name'. I've tried calling OCILogon with a third argument specifying the database to use and I've tried without it, assuming it will default to what I have set $ORACLE_SID to prior to startup.
I can connect to the database when I use sqlplus on my machine, but connection from PHP fails. I've added Oracle-environment variables to my startup-script for Apache and when I run phpinfo() I can see that they are set:
LD_LIBRARY_PATH=/usr/local/lib:/opt/oracle/8.1.6/lib:/usr/local/mysql/0/lib/mysql:$LD_LIBRARY_PATH
ORACLE_HOME=/opt/oracle/8.1.6
ORA_NLS33=/opt/oracle/8.1.6/ocommon/nls/admin/data
ORA_NLS32=/opt/oracle/8.1.6/ocommon/nls/admin/data
ORA_NLS=/opt/oracle/8.1.6/ocommon/nls/admin/data
NLS_TERRITORY=AMERICA
NLS_LANGUAGE=AMERICAN
NLS_CHARACTERSET=WE8ISO8859P1
LANGUAGE=AMERICAN
PATH=/bin:/usr/bin:/usr/sbin:/usr/ccs/bin:/usr/bin/X11:/usr/local/bin:/opt/local/bin:/usr/ucb:/edt/pgm/bin:/edt/pgm/scriptx:/opt/oracle/8.1.6/bin
ORACLE_BASE=/opt/oracle
ORACLE_SID=EPDB
TNS_ADMIN=/opt/oracle/8.1.6/network/admin
NLS_LANG=AMERICAN_AMERICA.WE8ISO8859P1
export NLS_CHARACTERSET NLS_LANGUAGE NLS_TERRITORY NLS_LANG ORA_NLS
export PATH LANGUAGE TNS_ADMIN NLS_LANG ORA_NLS32 ORA_NLS33 ORACLE_HOME ORACLE_SID
export LD_LIBRARY_PATH
I'm not very good at Oracle-admin so I guess that's where my problem lies. I've tried to add a section to listener.ora as well but that didn't help.
Suggestions?
Regards,
Peter
-- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: php-db-unsubscribe <email protected> For additional commands, e-mail: php-db-help <email protected> To contact the list administrators, e-mail: php-list-admin <email protected>
- Next message: Miles Thompson: "Re: [PHP-DB] Update problems"
- Previous message: Richard Allsebrook: "RE: [PHP-DB] Update problems"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]

