Bug #74420 [Asn->Fbk]: oci_pconnect over tls problems

From: Date: Sat, 08 Dec 2018 10:31:26 +0000
Subject: Bug #74420 [Asn->Fbk]: oci_pconnect over tls problems
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-218335@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=74420&edit=1 ID: 74420 Updated by: sixd@php.net Reported by: sega234 at mail dot ru Summary: oci_pconnect over tls problems -Status: Assigned +Status: Feedback Type: Bug Package: OCI8 related Operating System: Ubuntu 16.04/CentOS 6 PHP Version: 7.* Assigned To: sixd Block user comment: N Private report: N New Comment: Try the fix merged for #76804 Previous Comments: ------------------------------------------------------------------------ [2018-09-04 17:40:00] php at koenigskind dot net Possibly related to Bug #76804 and might also be fixed with the pull request: https://github.com/php/php-src/pull/3491 ------------------------------------------------------------------------ [2017-12-06 08:41:21] sega234 at mail dot ru Reproduced on PHP Version 7.2.0 ------------------------------------------------------------------------ [2017-06-15 18:49:47] kalle@php.net Assigning to Oracle ------------------------------------------------------------------------ [2017-06-15 04:11:27] sega234 at mail dot ru Problem also found on PHP 7.0.18 and CentOS 6 ------------------------------------------------------------------------ [2017-04-12 11:13:20] sega234 at mail dot ru Description: ------------ I try to use persistent connection to database with tls protocol. Also i use nginx and php-fpm. During first 6 requests connections to db are established. In next request I receive php Warning: Errno: 2 Errstr: oci_parse(): supplied resource is not a valid oci8 connection resource Errline: 16 If I restart php-fpm, then i can do 6 requests more, and in 7th I will recive warning. If in php-fpm I set pm.start_servers = 10 and restart php-fpm, then i can do 11 requests, and in 12th I will recive warning. Requests without error correlates with pm.start_servers parameter. Also, in cloned vm with php version 5.6.22 problem does not exists. Also, oci_pconnect() with php7.1.3 works without tls protocol. OCI8 Version 2.1.3 Oracle Run-time Client Library Version 12.2.0.1.0 Oracle Compile-time Instant Client Version 12.2 php.ini default settings php.fpm settings: pm.max_children = 250 pm.start_servers = 5 pm.min_spare_servers = 5 pm.max_spare_servers = 25 Test script: --------------- <?php ini_set('error_reporting', E_ALL); ini_set('display_errors', 1); function errorsHandler($errno , $errstr, $errfile, $errline) { echo "Errno: " . $errno . "\n"; echo "Errstr: " . $errstr . "\n"; echo "Errline: " . $errline . "\n"; die(); } set_error_handler('errorsHandler'); $conn = oci_pconnect('/', '', 'SECUREDCONNECTION','AL32UTF8',OCI_CRED_EXT); if (!$conn) { die("Connection problems: " . oci_error()); } $stid = oci_parse($conn, 'select * from accounts where number = :number'); $value = '4080************2622'; oci_bind_by_name($stid, ':number', $value, -1, SQLT_CHR); oci_execute($stid); echo "Sql executed" . PHP_EOL; oci_free_statement($stid); Expected result: ---------------- Sql executed Actual result: -------------- Errno: 2 Errstr: oci_parse(): supplied resource is not a valid oci8 connection resource Errline: 16 ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=74420&edit=1

« previous php.bugs (#218335) next »