From owner-freebsd-ports-bugs@FreeBSD.ORG Thu Jul 10 16:00:14 2008 Return-Path: Delivered-To: freebsd-ports-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1D5D5106567B for ; Thu, 10 Jul 2008 16:00:14 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id B4F448FC1C for ; Thu, 10 Jul 2008 16:00:12 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.14.2/8.14.2) with ESMTP id m6AG0CUk008363 for ; Thu, 10 Jul 2008 16:00:12 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.2/8.14.1/Submit) id m6AG0CgC008362; Thu, 10 Jul 2008 16:00:12 GMT (envelope-from gnats) Resent-Date: Thu, 10 Jul 2008 16:00:12 GMT Resent-Message-Id: <200807101600.m6AG0CgC008362@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-ports-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Nick Barkas Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A2B191065670 for ; Thu, 10 Jul 2008 15:51:10 +0000 (UTC) (envelope-from snb@smtp.earth.threerings.net) Received: from smtp.earth.threerings.net (smtp1.earth.threerings.net [64.127.109.108]) by mx1.freebsd.org (Postfix) with ESMTP id 9F26E8FC0A for ; Thu, 10 Jul 2008 15:51:10 +0000 (UTC) (envelope-from snb@smtp.earth.threerings.net) Received: by smtp.earth.threerings.net (Postfix, from userid 10038) id 5F19C61F00; Thu, 10 Jul 2008 08:51:09 -0700 (PDT) Message-Id: <20080710155109.5F19C61F00@smtp.earth.threerings.net> Date: Thu, 10 Jul 2008 08:51:09 -0700 (PDT) From: Nick Barkas To: FreeBSD-gnats-submit@FreeBSD.org X-Send-Pr-Version: 3.113 Cc: Subject: ports/125476: lang/php5 segmentation fault after running any command line php script X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Nick Barkas List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 10 Jul 2008 16:00:14 -0000 >Number: 125476 >Category: ports >Synopsis: lang/php5 segmentation fault after running any command line php script >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Thu Jul 10 16:00:12 UTC 2008 >Closed-Date: >Last-Modified: >Originator: Nick Barkas >Release: FreeBSD 6.3-RELEASE-p2 amd64 >Organization: Three Rings Design >Environment: System: FreeBSD wiki1.luna.threerings.net 6.3-RELEASE-p2 FreeBSD 6.3-RELEASE-p2 #0: Wed Jun 18 21:48:11 PDT 2008 root@wiki1.luna.threerings.net:/usr/obj/usr/src/sys/SMP amd64 PHP packages installed: php5 php5-dom php5-iconv php5-ldap php5-mbstring php5-mysql php5-pcre php5-readline php5-session php5-simplexml php5-spl php5-xml php5-zlib /var/db/ports/php5/options: # This file is auto-generated by 'make config'. # No user-servicable parts inside! # Options for php5-5.2.6 _OPTIONS_READ=php5-5.2.6 WITH_CLI=true WITHOUT_CGI=true WITH_APACHE=true WITHOUT_DEBUG=true WITH_SUHOSIN=true WITHOUT_MULTIBYTE=true WITH_IPV6=true WITHOUT_MAILHEAD=true WITHOUT_REDIRECT=true WITHOUT_DISCARD=true WITHOUT_FASTCGI=true WITHOUT_PATHINFO=true >Description: PHP seg faults whenever I run a command line script, no matter what the script is. It seems to properly execute everything in the script and just crashes when it finishes up. I'm also using mod_php with Apache to serve MediaWiki on this same machine, and that seems to work just fine as well. It's just the PHP CLI that appears to have trouble. Here is a backtrace from gdb of the core file created: snb@wiki1> gdb -c /var/cores/10038-6112-php.core /usr/local/bin/php GNU gdb 6.1.1 [FreeBSD] Copyright 2004 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 "amd64-marcel-freebsd"...(no debugging symbols found)... Core was generated by `php'. Program terminated with signal 11, Segmentation fault. Reading symbols from /lib/libcrypt.so.3...(no debugging symbols found)...done. Loaded symbols for /lib/libcrypt.so.3 Reading symbols from /lib/libm.so.4...(no debugging symbols found)...done. Loaded symbols for /lib/libm.so.4 Reading symbols from /usr/local/lib/libxml2.so.5...(no debugging symbols found)...done. Loaded symbols for /usr/local/lib/libxml2.so.5 Reading symbols from /lib/libz.so.3...(no debugging symbols found)...done. Loaded symbols for /lib/libz.so.3 Reading symbols from /usr/local/lib/libiconv.so.3...(no debugging symbols found)...done. Loaded symbols for /usr/local/lib/libiconv.so.3 Reading symbols from /lib/libc.so.6...(no debugging symbols found)...done. Loaded symbols for /lib/libc.so.6 Reading symbols from /usr/local/lib/libsasl2.so.2...(no debugging symbols found)...done. Loaded symbols for /usr/local/lib/libsasl2.so.2 Reading symbols from /usr/local/lib/libldap-2.3.so.2...(no debugging symbols found)...done. Loaded symbols for /usr/local/lib/libldap-2.3.so.2 Reading symbols from /usr/local/lib/liblber-2.3.so.2...(no debugging symbols found)...done. Loaded symbols for /usr/local/lib/liblber-2.3.so.2 Reading symbols from /usr/lib/libssl.so.4...(no debugging symbols found)...done. Loaded symbols for /usr/lib/libssl.so.4 Reading symbols from /lib/libcrypto.so.4...(no debugging symbols found)...done. Loaded symbols for /lib/libcrypto.so.4 Reading symbols from /usr/local/lib/php/20060613/session.so...(no debugging symbols found)...done. Loaded symbols for /usr/local/lib/php/20060613/session.so Reading symbols from /usr/local/lib/nss_ldap.so.1...(no debugging symbols found)...done. Loaded symbols for /usr/local/lib/nss_ldap.so.1 Reading symbols from /libexec/ld-elf.so.1...(no debugging symbols found)...done. Loaded symbols for /libexec/ld-elf.so.1 #0 0x0000000000000000 in ?? () (gdb) bt #0 0x0000000000000000 in ?? () #1 0x0000000804343ba7 in __do_global_dtors_aux () from /usr/local/lib/php/20060613/session.so #2 0x000000080434a861 in _fini () from /usr/local/lib/php/20060613/session.so #3 0x000000000076c8c0 in zval_used_for_init () #4 0x000000080071b3d4 in elf_hash () from /libexec/ld-elf.so.1 #5 0x000000080071e2d7 in dlclose () from /libexec/ld-elf.so.1 #6 0x0000000000518406 in zend_hash_apply_deleter () #7 0x000000000051849e in zend_hash_graceful_reverse_destroy () #8 0x000000000050c037 in zend_shutdown () #9 0x00000000004c950a in php_module_shutdown () #10 0x000000000059f001 in main () I don't know how useful this will be since PHP was not built with debugging symbols. If I reinstall the port with WITH_DEBUG=true, strangely enough the problem goes away--the PHP CLI no longer crashes. >How-To-Repeat: Even a very simple script can trigger this. For example: snb@wiki1> cat foo.php snb@wiki1> php foo.php hello world zsh: segmentation fault (core dumped) php foo.php >Fix: >Release-Note: >Audit-Trail: >Unformatted: