|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2003-06-26 06:36 UTC] thomas at fivemile dot net
Description:
------------
OCILogon and OCIPLogon either segfault or return spurious (changing by reloading the page) error messages of the type "Warning: ocilogon(): OCISessionBegin: ORA-00604: error occurred at recursive SQL level 1 ORA-00911: invalid character in /home/httpd/index.php3 on line 5"
Environment vars are set (verfied by phpinfo()), sqlplus from the webserver account works, older (9.0.1) client libs from another machine can access the db without problems.
PHP compiled with ./configure' '--with-db' '--with-apxs2=/usr/bin/apxs' '--with-gd=/usr/local' '--enable-gd-native-ttf' '--with-mysql=/usr' '--with-zlib' '--with-mcrypt' '--enable-track-vars=yes' '--with-jpeg-dir=/usr' '--with-oci8=/opt/oracle/product/9.2.0' '--with-tiff-dir=/usr' '--with-png-dir=/usr' '--with-xml' '--with-calendar' '--enable-sigchild' '--with-xpm-dir=/usr/X11R6' '--with-gettext' '--with-openssl=/usr' '--enable-calendar' '--enable-gd-imgstrttf' '--with-ttf=/usr/local' '--with-imap' '--with-kerberos' '--enable-xslt' '--with-xslt-sablot' '--enable-debug'
but a 'watered down' version including only the oracle libs yields the same problems, regardless of trying with apache 1 (both static and DSO) or 2
Reproduce code:
---------------
$ohnd = OCILogon("dvd","hidden","tns.domain");
Expected result:
----------------
Connection to Oracle 9.2.0 on the same machine
Actual result:
--------------
Spurious ORA-00604 error messages (see above) or coredump
[root@tesla apache2]# gdb bin/httpd
GNU gdb Red Hat Linux (5.2.1-4)
Copyright 2002 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for details.
This GDB was configured as "i386-redhat-linux"...(no debugging symbols found)...
(gdb) run -X
Starting program: /opt/apache2/bin/httpd -X
(no debugging symbols found)...(no debugging symbols found)...[New Thread 16384 (LWP 1468)]
[Thu Jun 26 13:20:22 2003] [warn] module php4_module is already loaded, skipping
Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 16384 (LWP 1468)]
0x40a94e0a in kpuhhaloc () from /opt/oracle/product/9.2.0/lib/libclntsh.so.9.0
(gdb) bt
#0 0x40a94e0a in kpuhhaloc () from /opt/oracle/product/9.2.0/lib/libclntsh.so.9.0
#1 0x40aa516f in kpughndl0 () from /opt/oracle/product/9.2.0/lib/libclntsh.so.9.0
#2 0x40aab553 in kpughndl () from /opt/oracle/product/9.2.0/lib/libclntsh.so.9.0
#3 0x40affde6 in OCIHandleAlloc () from /opt/oracle/product/9.2.0/lib/libclntsh.so.9.0
#4 0x4035974f in _oci_open_session (server=0x8229608, username=0x82439dc "dvd", password=0x82492fc "yami", persistent=0, exclusive=0, charset=0x404c6cd9 "")
at /root/build/php-4.3.2/ext/oci8/oci8.c:2253
#5 0x4035ada0 in oci_do_connect (ht=3, return_value=0x8243a4c, this_ptr=0x0, return_value_used=1, persistent=0, exclusive=0)
at /root/build/php-4.3.2/ext/oci8/oci8.c:2685
#6 0x4035f590 in zif_ocilogon (ht=3, return_value=0x8243a4c, this_ptr=0x0, return_value_used=1) at /root/build/php-4.3.2/ext/oci8/oci8.c:4307
#7 0x404582be in execute (op_array=0x823a31c) at /root/build/php-4.3.2/Zend/zend_execute.c:1606
#8 0x40446ee9 in zend_execute_scripts (type=8, retval=0x0, file_count=3) at /root/build/php-4.3.2/Zend/zend.c:869
#9 0x40410990 in php_execute_script (primary_file=0xbfffdc20) at /root/build/php-4.3.2/main/main.c:1671
#10 0x4045dfd1 in php_handler (r=0x8207968) at /root/build/php-4.3.2/sapi/apache2handler/sapi_apache2.c:525
#11 0x0809f7fe in ap_run_handler ()
#12 0x0809fd16 in ap_invoke_handler ()
#13 0x080822a3 in ap_process_request ()
#14 0x0807e4e1 in ssl_dh_GetParamFromFile ()
#15 0x080a87ee in ap_run_process_connection ()
#16 0x0809e3b4 in ap_graceful_stop_signalled ()
#17 0x0809e55e in ap_graceful_stop_signalled ()
#18 0x0809e5b7 in ap_graceful_stop_signalled ()
#19 0x0809eca9 in ap_mpm_run ()
#20 0x080a39c2 in main ()
#21 0x420158f7 in __libc_start_main () from /lib/i686/libc.so.6
(gdb) quit
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Thu Nov 06 20:00:02 2025 UTC |
Warning: ociplogon(): OCISessionBegin: ORA-00604: error occurred at recursive SQL level 1 ORA-00911: invalid character in /home/httpd/index.php3 on line 3 or Warning: ocilogon(): OCISessionBegin: ORA-00604: error occurred at recursive SQL level 1 ORA-00922: missing or invalid option in /home/httpd/index.php3 on line 3 'Line 3' is simply the OCILogon or OCIPLogon as follows: $ohnd = OCILogon("dvd","hidden","tns.domain");Hi sorry ment to add the script as well I have also tested connecting from sqlplus which i can do. <?php ociinternaldebug(1); if (OCILogon("<username>", "<password>", "pierceg")) { echo "Successfully connected to Oracle.\n"; } else { echo "Oracle Connect Error "; } ?>