ID: 43199 Comment by: jfrisby at adknowledge dot com Reported By: eugene dot pikalov at gmail dot com Status: No Feedback Bug Type: PDO related Operating System: Linux Fedora 2.6.22.5-76.fc7 PHP Version: 5.2.4 New Comment:
We're seeing an almost identical stack trace from a php commandline program. Basically, if we connect to a DB using PDO_mysql, we get an exit code of 1 after all our code has successfully executed without error -- but only if we use persistent connections. This is on PHP 5.2.4 under Ubuntu Hardy. Per suggestions on #php.pecl, will try SQLite driver, and if possible, 5.3. ---snip--- <?php error_reporting(E_ALL|E_STRICT); try { $obj = new PDO("mysql:host=localhost;dbname=ls_dev_jfrisby","root","" ,array(PDO::ATTR_PERSISTENT => true)); $stmt = $obj->prepare("select count(1) cnt from channel_map_bids"); $stmt->execute(); var_dump($stmt->fetchAll()); $obj = null; } catch (Exception $e) { print "exception: " . (string)$e . "\n"; } exit(0); ?> Previous Comments: ------------------------------------------------------------------------ [2007-11-13 01:00:01] php-bugs at lists dot php dot net No feedback was provided for this bug for over a week, so it is being suspended automatically. If you are able to provide the information that was originally requested, please do so and change the status of the bug back to "Open". ------------------------------------------------------------------------ [2007-11-09 08:38:05] serban dot ghita at verasys dot com i can confirm this on slackware after upgrading. Linux www 2.6.21.5-smp #1 SMP Sat Nov 3 15:51:44 Local time zone must be set--see zic m i686 Intel(R) Xeon(R) CPU E5335 @ 2.00GHz GenuineIntel GNU/Linux i was running httpd-2.2.6 with PHP 5.2.4 i tried compiling both apache and php with less options, nothing worked. temporary workaround: installed httpd-2.0.58 + PHP 5.2.4 and everithing worked. i cannot generate a backtrace at the moment because i'm on a production server ------------------------------------------------------------------------ [2007-11-05 23:46:17] [EMAIL PROTECTED] Thank you for this bug report. To properly diagnose the problem, we need a backtrace to see what is happening behind the scenes. To find out how to generate a backtrace, please read http://bugs.php.net/bugs-generating-backtrace.php for *NIX and http://bugs.php.net/bugs-generating-backtrace-win32.php for Win32 Once you have generated a backtrace, please submit it to this bug report and change the status back to "Open". Thank you for helping us make PHP better. ------------------------------------------------------------------------ [2007-11-05 14:17:41] eugene dot pikalov at gmail dot com Description: ------------ On 5.2.3 everything allright, after update i have many segfaults in httpd logs. Apache/2.2.4 Reproduce code: --------------- [Fri Nov 02 17:30:01 2007] [notice] child pid 30265 exit signal Segmentation fault (11) [Fri Nov 02 17:32:21 2007] [notice] child pid 30840 exit signal Segmentation fault (11) [Fri Nov 02 17:35:17 2007] [notice] child pid 31093 exit signal Segmentation fault (11) [Fri Nov 02 17:39:06 2007] [notice] child pid 551 exit signal Segmentation fault (11) [Fri Nov 02 17:39:58 2007] [notice] child pid 419 exit signal Segmentation fault (11) [Fri Nov 02 17:43:56 2007] [notice] child pid 2439 exit signal Segmentation fault (11) *** glibc detected *** /usr/sbin/httpd: munmap_chunk(): invalid pointer: 0x80e90b60 *** ======= Backtrace: ========= /lib/libc.so.6(cfree+0x1bb)[0x42255b] /etc/httpd/modules/libphp5.so(zend_hash_destroy+0x4e)[0xcc607e] /etc/httpd/modules/libphp5.so[0xb42227] /etc/httpd/modules/libphp5.so(php_pdo_pdbh_dtor+0x15)[0xb422e5] /etc/httpd/modules/libphp5.so(plist_entry_destructor+0x82)[0xcc8822] /etc/httpd/modules/libphp5.so[0xcc5d68] /etc/httpd/modules/libphp5.so(zend_hash_graceful_reverse_destroy+0x18)[0xcc5fa8] /etc/httpd/modules/libphp5.so(zend_shutdown+0x12)[0xcbc892] /etc/httpd/modules/libphp5.so(php_module_shutdown+0x2f)[0xc7ba6f] /etc/httpd/modules/libphp5.so(php_module_shutdown_wrapper+0xb)[0xc7bb1b] /etc/httpd/modules/libphp5.so[0xd344e3] /usr/lib/libapr-1.so.0[0x385d1d] /usr/lib/libapr-1.so.0(apr_pool_destroy+0x3d)[0x38648d] /usr/sbin/httpd[0x800386c5] /usr/sbin/httpd[0x80038c30] /usr/sbin/httpd[0x80038e41] /usr/sbin/httpd(ap_mpm_run+0x913)[0x80039843] /usr/sbin/httpd(main+0x8b7)[0x80010217] /lib/libc.so.6(__libc_start_main+0xe0)[0x3ccf70] /usr/sbin/httpd[0x8000f2f1] ======= Memory map: ======== [Fri Nov 02 17:46:00 2007] [notice] child pid 2773 exit signal Aborted (6) [Fri Nov 02 17:50:37 2007] [notice] child pid 4359 exit signal Segmentation fault (11) [Fri Nov 02 17:53:55 2007] [notice] child pid 5519 exit signal Segmentation fault (11) [Fri Nov 02 17:54:38 2007] [notice] child pid 5622 exit signal Segmentation fault (11) [Fri Nov 02 17:55:51 2007] [notice] child pid 4738 exit signal Segmentation fault (11) [Fri Nov 02 17:57:45 2007] [notice] child pid 6674 exit signal Segmentation fault (11) ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=43199&edit=1