php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #61010 Segfault (11) on oci_connect
Submitted: 2012-02-08 13:31 UTC Modified: 2012-02-09 19:41 UTC
Votes:2
Avg. Score:4.5 ± 0.5
Reproduced:2 of 2 (100.0%)
Same Version:2 (100.0%)
Same OS:0 (0.0%)
From: lars at larsdebruin dot net Assigned: sixd (profile)
Status: Not a bug Package: OCI8 related
PHP Version: 5.3.10 OS: Redhat Linux 6.2
Private report: No CVE-ID: None
 [2012-02-08 13:31 UTC] lars at larsdebruin dot net
Description:
------------
build:
./configure --with-libxml-dir --enable-bcmath --with-openssl --with-kerberos --
with-zlib --with-bz2 --with-libdir=lib64 --enable-calendar --with-curl --enable-
exif --enable-ftp --with-gd --with-ldap --with-ldap-sasl --enable-mbstring --
with-mcrypt --with-mysql --with-pdo-mysql --with-mysqli --with-
oci8=shared,instantclient,/root/oracle --enable-soap --enable-sockets --with-
gettext --enable-zip --with-mhash --with-pcre-regex --enable-shmop --enable-
sysvmsg --enable-mysqlnd --with-unixODBC --with-apxs2=/usr/sbin/apxs --disable-
cgi

PHPinfo: 
OCI8 Support	enabled
Version	1.4.7
Revision	$Revision: 321634 $
Active Persistent Connections	0
Active Connections	0
Oracle Instant Client Version	10.1
Temporary Lob support	enabled
Collections support	enabled

Test script:
---------------
<?php
$conn = oci_connect('user', 'password', 'bla.bla.com');
?>

Expected result:
----------------
<>: php oracleconnect.php
Segmentation fault (core dumped)

Core dump is NOT generated



Actual result:
--------------
Core dump is not generated by PHP?

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2012-02-08 17:04 UTC] sixd@php.net
-Assigned To: +Assigned To: sixd
 [2012-02-09 00:58 UTC] sixd@php.net
-Status: Assigned +Status: Not a bug
 [2012-02-09 00:58 UTC] sixd@php.net
Doesn't reproduce for me on Oracle Linux 6.2.  I spent some time
getting as close to your configuration as possible.  I saw no failures
with various scenarios including invalid passwords, invalid connection
strings and expired passwords (https://bugs.php.net/bug.php?id=58477)

$ php -r '$c = oci_connect("cj", "cj", "mymachine/abc");
var_dump($c);' resource(5) of type (oci8 connection)

Some comments:

1. Oracle Instant Client 10.1 is very old.  Unless you need it for a
reason reason, use at least 11.2.
http://www.oracle.com/technetwork/topics/linuxx86-64soft-092277.html

2. Oracle DB & client isn't certified on RHEL 6, so all bets about
behavior are off.

3. Why build only OCI8 shared?

4. The configure line has "--enable-mysqlnd" but none of the MySQL
extension options say to use mysqlnd, so the MySQL client libraries
are still being used.
 [2012-02-09 19:41 UTC] lars at larsdebruin dot net
1. used the new oracle client
2. nothing i can do about it :)
3. compiled into PHP, not as module
4. removed the option

Same error, i recompiled PHP without OCI.
it worked using: pecl install oci8
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Apr 19 20:01:29 2024 UTC