logo       

PHP4.22/OCI8/Netscape 3.63 tnsnames problem...: msg#00857

Subject: PHP4.22/OCI8/Netscape 3.63 tnsnames problem...
Hi there,

I've having some problems with ORACLE_SID under Solaris 8/PHP
4.22/Netscape 3.63.

If I specify the ORACLE_SID, and export it within my environment before
webserver startup, php/oracle do not look up the SID within
tnsnames.ora.  I verified this with truss:

Trace output:
Fatal NI connect error 12545, connecting to:
 
(DESCRIPTION=(ADDRESS=(PROTOCOL=beq)(PROGRAM=/data01/oracle/bin/oracle)(
ARGV0=orac
leblah)(ARGS='(DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq)))')(DETACH
=NO))(
CONNECT_DATA=(CID=(PROGRAM=)(HOST=foo)(USER=fish))))

[---- ORACLE_SID=blah, OciLogon ( "user", "pw", "" ); -----]
# ps -funs | awk '{print $2}' | xargs truss -f -topen,access -p
10186:  access("/data/oracle/network/admin/ldap.ora", 0) Err#2 ENOENT
10186:  open("/data/oracle/rdbms/mesg/ocius.msb", O_RDONLY) = 19
10186:  open("/data/netscape/testing/test.php", O_RDONLY) = 20
10186:  open("/data/netscape/testing/connecttest.php", O_RDONLY) = 20
10186:  open64("./../", O_RDONLY|O_NDELAY)              = 20
10186:  open64("./../../", O_RDONLY|O_NDELAY)           = 20
10186:  open64("./../../../", O_RDONLY|O_NDELAY)        = 20
10186:  open64("./../../../../", O_RDONLY|O_NDELAY)     = 20
10186:  open("/etc/mnttab", O_RDONLY)                   = 21
10186:  access("/data/oracle/network/admin/ldap.ora", 0) Err#2 ENOENT
10186:  access("/data/oracle/network/admin/sqlnet.ora", 0) = 0
10186:  open("/data/oracle/network/admin/sqlnet.ora", O_RDONLY) = 20
10186:  access("/.sqlnet.ora", 0)                       Err#2 ENOENT
10186:  access("/data/oracle/network/admin/intchg.ora", 0) Err#2 ENOENT
10186:  access("/var/opt/oracle/intchg.ora", 0)         Err#2 ENOENT
10186:  access("/data/oracle/network/admin/intchg.ora", 0) Err#2 ENOENT
10186:  access("/data/oracle/network/admin/tnsnav.ora", 0) Err#2 ENOENT
10186:  access("/var/opt/oracle/tnsnav.ora", 0)         Err#2 ENOENT
10186:  access("/data/oracle/network/admin/tnsnav.ora", 0) Err#2 ENOENT
10186:  open("/data/netscape/https-testing/config/sqlnet.log",
O_WRONLY|O_APPEND|
O_CREAT, 0666) = 20
10186:  open("/data/oracle/network/mesg/tnsus.msb", O_RDONLY) = 21
10186:  open("/data/oracle/rdbms/mesg/oraus.msb", O_RDONLY) = 22
[---- ORACLE_SID=blah, OciLogon ( "user", "pw", "" ); -----]

If I specify the same SID in the db field of OciLogon it succeeds to
look up tnsnames.ora for the sid and connects properly:

[---- No ORACLE_SID, OciLogon ( "user", "pw", "blah" ); -----]
10210:  access("/data/oracle/network/admin/ldap.ora", 0) Err#2 ENOENT
10210:  open("/data/oracle/rdbms/mesg/ocius.msb", O_RDONLY) = 19
10210:  open("/data/netscape/testing/test.php", O_RDONLY) = 20
10210:  open("/data/netscape/testing/connecttest.php", O_RDONLY) = 20
10210:  open64("./../", O_RDONLY|O_NDELAY)              = 20
10210:  open64("./../../", O_RDONLY|O_NDELAY)           = 20
10210:  open64("./../../../", O_RDONLY|O_NDELAY)        = 20
10210:  open64("./../../../../", O_RDONLY|O_NDELAY)     = 20
10210:  open("/etc/mnttab", O_RDONLY)                   = 21
10210:  access("/data/oracle/network/admin/ldap.ora", 0) Err#2 ENOENT
10210:  access("/data/oracle/network/admin/sqlnet.ora", 0) = 0
10210:  open("/data/oracle/network/admin/sqlnet.ora", O_RDONLY) = 20
10210:  access("/.sqlnet.ora", 0)                       Err#2 ENOENT
10210:  access("/data/oracle/network/admin/intchg.ora", 0) Err#2 ENOENT
10210:  access("/var/data/oracle/intchg.ora", 0)         Err#2 ENOENT
10210:  access("/data/oracle/network/admin/intchg.ora", 0) Err#2 ENOENT
10210:  access("/data/oracle/network/admin/tnsnav.ora", 0) Err#2 ENOENT
10210:  access("/var/data/oracle/tnsnav.ora", 0)         Err#2 ENOENT
10210:  access("/data/oracle/network/admin/tnsnav.ora", 0) Err#2 ENOENT
10210:  access("/.tnsnames.ora", 0)                     Err#2 ENOENT
*** Why doesn't this happen with ORACLE_SID and a blank db in OciLogon??
10210:  access("/data/oracle/network/admin/tnsnames.ora", 0) = 0
10210:  open("/data/oracle/network/names/.sdns.ora", O_RDONLY) Err#2
ENOENT
10210:  open("/data/oracle/network/admin/tnsnames.ora", O_RDONLY) = 20
10210:  access("/.tnsnames.ora", 0)                     Err#2 ENOENT
10210:  access("/data/oracle/network/admin/tnsnames.ora", 0) = 0
10210:  open("/data/oracle/network/names/.sdns.ora", O_RDONLY) Err#2
ENOENT
10210:  open("/data/oracle/network/admin/tnsnames.ora", O_RDONLY) = 20
10210:  access("/data/oracle/network/admin/protocol.ora", 0) Err#2
ENOENT
10210:  access("/data/oracle/network/admin/protocol.ora", 0) Err#2
ENOENT
10210:  open("/etc/ttysrch", O_RDONLY)                  = 21
10210:  open("/proc/10210", O_RDONLY)                   = 21
10210:  open("/data/oracle/ocommon/nls/admin/data/lx1boot.nlb",
O_RDONLY) = 21
10210:  open("/etc/ttysrch", O_RDONLY)                  = 21
[---- No ORACLE_SID, OciLogon ( "user", "pw", "blah" ); -----]

Am I doing something stupid with the value in ORACLE_SID?  If I have
correctly specified ORACLE_SID then is PHP 4.22 working as designed or
is this a bug in php or oracle?

thanks in advance,

Dave.



--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

Recently Viewed:
science.linguis...    culture.sf.lite...    video.mplayer.c...    yellowdog.gener...    ietf.rfc822/199...    emacs.help/2002...    redhat.release....    kernel.speakup/...    java.openejb.de...    debian.devel.gt...    xfree86.newbie/...    bug-tracking.ma...    pam/2003-05/msg...    games.devel.ope...    user-groups.lin...    music.pancham/2...    network.mq.deve...    web.html.genera...    arklinux.bugs/2...    linux.ecasound/...    qnx.openqnx.dev...    org.user-groups...    file-systems.sf...    trustix.contrib...   
Home | blog view | USPTO Patent Archive | advertise | OSDir is an inevitable website. super tiny logo

Free Magazines

Cisco News
Receive a free quarterly e-newsletter with exclusive articles on how Cisco IT uses its own products and solutions to enable the business.
subscribe

Systems Management News, the newspaper for IT systems administration and data center managers! Each issue of Systems Management News is chock-full of news and analysis to help you understand what's happening in your field.
subscribe

The Enterprise Newsweekly eWeek is the essential technology information source for builders of e-business.
subscribe

Oracle Magazine Oracle Magazine contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more. Oracle (NASDAQ: ORCL) is the world's largest enterprise software company.
subscribe

Total Telecom Total Telecom is "The Economist of the communications industry".
subscribe