You are viewing a plain text version of this content. The canonical link for it is here.
Posted to bugs@apr.apache.org by bu...@apache.org on 2011/01/15 23:37:37 UTC

DO NOT REPLY [Bug 50594] New: apr_palloc Segmentation Fault

https://issues.apache.org/bugzilla/show_bug.cgi?id=50594

           Summary: apr_palloc Segmentation Fault
           Product: APR
           Version: 1.4.2
          Platform: PC
        OS/Version: FreeBSD
            Status: NEW
          Severity: normal
          Priority: P2
         Component: APR
        AssignedTo: bugs@apr.apache.org
        ReportedBy: marcelo@tpn.com.br


I'm using an experimental mpm called peruser (http://www.peruser.org/).

My server is segfaulting, but I believe that there is some problem with
apr_palloc, because the last 5 frames in backtrace are from original Apache
source.

I'm using Apache 2.2.16 version, but this problem also happened with Apache
2.2.17 and APR 1.4.2.

Here is the backtrace:

# gdb httpd /tmp/httpd.core
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"...
Core was generated by `httpd'.
Program terminated with signal 11, Segmentation fault.
Reading symbols from /lib/libm.so.5...done.
Loaded symbols for /lib/libm.so.5
Reading symbols from /usr/local/lib/libpcre.so.0...done.
Loaded symbols for /usr/local/lib/libpcre.so.0
Reading symbols from /usr/local/lib/libaprutil-1.so.3...done.
Loaded symbols for /usr/local/lib/libaprutil-1.so.3
Reading symbols from /usr/local/lib/libdb-4.2.so.2...done.
Loaded symbols for /usr/local/lib/libdb-4.2.so.2
Reading symbols from /usr/local/lib/libgdbm.so.3...done.
Loaded symbols for /usr/local/lib/libgdbm.so.3
Reading symbols from /usr/local/lib/libexpat.so.6...done.
Loaded symbols for /usr/local/lib/libexpat.so.6
Reading symbols from /usr/local/lib/libiconv.so.3...done.
Loaded symbols for /usr/local/lib/libiconv.so.3
Reading symbols from /usr/local/lib/libapr-1.so.4...done.
Loaded symbols for /usr/local/lib/libapr-1.so.4
Reading symbols from /lib/libcrypt.so.5...done.
Loaded symbols for /lib/libcrypt.so.5
Reading symbols from /lib/libthr.so.3...done.
Loaded symbols for /lib/libthr.so.3
Reading symbols from /lib/libc.so.7...done.
Loaded symbols for /lib/libc.so.7
Reading symbols from /usr/local/libexec/apache22/mod_authn_file.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_authn_file.so
Reading symbols from /usr/local/libexec/apache22/mod_authn_dbm.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_authn_dbm.so
Reading symbols from /usr/local/libexec/apache22/mod_authn_anon.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_authn_anon.so
Reading symbols from /usr/local/libexec/apache22/mod_authn_default.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_authn_default.so
Reading symbols from /usr/local/libexec/apache22/mod_authn_alias.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_authn_alias.so
Reading symbols from /usr/local/libexec/apache22/mod_authz_host.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_authz_host.so
Reading symbols from /usr/local/libexec/apache22/mod_authz_groupfile.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_authz_groupfile.so
Reading symbols from /usr/local/libexec/apache22/mod_authz_user.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_authz_user.so
Reading symbols from /usr/local/libexec/apache22/mod_authz_dbm.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_authz_dbm.so
Reading symbols from /usr/local/libexec/apache22/mod_authz_owner.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_authz_owner.so
Reading symbols from /usr/local/libexec/apache22/mod_authz_default.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_authz_default.so
Reading symbols from /usr/local/libexec/apache22/mod_auth_basic.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_auth_basic.so
Reading symbols from /usr/local/libexec/apache22/mod_auth_digest.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_auth_digest.so
Reading symbols from /usr/local/libexec/apache22/mod_file_cache.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_file_cache.so
Reading symbols from /usr/local/libexec/apache22/mod_include.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_include.so
Reading symbols from /usr/local/libexec/apache22/mod_filter.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_filter.so
Reading symbols from /usr/local/libexec/apache22/mod_charset_lite.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_charset_lite.so
Reading symbols from /usr/local/libexec/apache22/mod_deflate.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_deflate.so
Reading symbols from /lib/libz.so.5...done.
Loaded symbols for /lib/libz.so.5
Reading symbols from /usr/local/libexec/apache22/mod_log_config.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_log_config.so
Reading symbols from /usr/local/libexec/apache22/mod_logio.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_logio.so
Reading symbols from /usr/local/libexec/apache22/mod_env.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_env.so
Reading symbols from /usr/local/libexec/apache22/mod_mime_magic.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_mime_magic.so
Reading symbols from /usr/local/libexec/apache22/mod_expires.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_expires.so
Reading symbols from /usr/local/libexec/apache22/mod_headers.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_headers.so
Reading symbols from /usr/local/libexec/apache22/mod_setenvif.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_setenvif.so
Reading symbols from /usr/local/libexec/apache22/mod_version.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_version.so
Reading symbols from /usr/local/libexec/apache22/mod_mime.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_mime.so
Reading symbols from /usr/local/libexec/apache22/mod_status.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_status.so
Reading symbols from /usr/local/libexec/apache22/mod_autoindex.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_autoindex.so
Reading symbols from /usr/local/libexec/apache22/mod_asis.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_asis.so
Reading symbols from /usr/local/libexec/apache22/mod_cgi.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_cgi.so
Reading symbols from /usr/local/libexec/apache22/mod_vhost_alias.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_vhost_alias.so
Reading symbols from /usr/local/libexec/apache22/mod_negotiation.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_negotiation.so
Reading symbols from /usr/local/libexec/apache22/mod_dir.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_dir.so
Reading symbols from /usr/local/libexec/apache22/mod_actions.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_actions.so
Reading symbols from /usr/local/libexec/apache22/mod_alias.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_alias.so
Reading symbols from /usr/local/libexec/apache22/mod_rewrite.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_rewrite.so
Reading symbols from /usr/local/libexec/apache22/libphp5.so...done.
Loaded symbols for /usr/local/libexec/apache22/libphp5.so
Reading symbols from /usr/local/lib/libxml2.so.5...done.
Loaded symbols for /usr/local/lib/libxml2.so.5
Reading symbols from /usr/local/libexec/apache22/mod_rpaf-2.0.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_rpaf-2.0.so
Reading symbols from /usr/local/libexec/apache22/mod_log_rotate.so...done.
Loaded symbols for /usr/local/libexec/apache22/mod_log_rotate.so
Reading symbols from /usr/local/lib/php/20090626/eaccelerator.so...done.
Loaded symbols for /usr/local/lib/php/20090626/eaccelerator.so
Reading symbols from
/usr/local/lib/php/20090626/ioncube/ioncube_loader.so...done.
Loaded symbols for /usr/local/lib/php/20090626/ioncube/ioncube_loader.so
Reading symbols from /usr/local/lib/php/20090626/ixed.5.3.fre...done.
Loaded symbols for /usr/local/lib/php/20090626/ixed.5.3.fre
Reading symbols from /usr/local/lib/php/20090626/bcmath.so...done.
Loaded symbols for /usr/local/lib/php/20090626/bcmath.so
Reading symbols from /usr/local/lib/php/20090626/bz2.so...done.
Loaded symbols for /usr/local/lib/php/20090626/bz2.so
Reading symbols from /usr/lib/libbz2.so.4...done.
Loaded symbols for /usr/lib/libbz2.so.4
Reading symbols from /usr/local/lib/php/20090626/calendar.so...done.
Loaded symbols for /usr/local/lib/php/20090626/calendar.so
Reading symbols from /usr/local/lib/php/20090626/ctype.so...done.
Loaded symbols for /usr/local/lib/php/20090626/ctype.so
Reading symbols from /usr/local/lib/php/20090626/curl.so...done.
Loaded symbols for /usr/local/lib/php/20090626/curl.so
Reading symbols from /usr/local/lib/libcurl.so.6...done.
Loaded symbols for /usr/local/lib/libcurl.so.6
Reading symbols from /usr/lib/libssl.so.6...done.
Loaded symbols for /usr/lib/libssl.so.6
Reading symbols from /lib/libcrypto.so.6...done.
Loaded symbols for /lib/libcrypto.so.6
Reading symbols from /usr/local/lib/php/20090626/dba.so...done.
Loaded symbols for /usr/local/lib/php/20090626/dba.so
Reading symbols from /usr/local/lib/php/20090626/dom.so...done.
Loaded symbols for /usr/local/lib/php/20090626/dom.so
Reading symbols from /usr/local/lib/php/20090626/exif.so...done.
Loaded symbols for /usr/local/lib/php/20090626/exif.so
Reading symbols from /usr/local/lib/php/20090626/filter.so...done.
Loaded symbols for /usr/local/lib/php/20090626/filter.so
Reading symbols from /usr/local/lib/php/20090626/ftp.so...done.
Loaded symbols for /usr/local/lib/php/20090626/ftp.so
Reading symbols from /usr/local/lib/php/20090626/gd.so...done.
Loaded symbols for /usr/local/lib/php/20090626/gd.so
Reading symbols from /usr/local/lib/libt1.so.5...done.
Loaded symbols for /usr/local/lib/libt1.so.5
Reading symbols from /usr/local/lib/libfreetype.so.9...done.
Loaded symbols for /usr/local/lib/libfreetype.so.9
Reading symbols from /usr/local/lib/libX11.so.6...done.
Loaded symbols for /usr/local/lib/libX11.so.6
Reading symbols from /usr/local/lib/libXpm.so.4...done.
Loaded symbols for /usr/local/lib/libXpm.so.4
Reading symbols from /usr/local/lib/libpng.so.6...done.
Loaded symbols for /usr/local/lib/libpng.so.6
Reading symbols from /usr/local/lib/libjpeg.so.11...done.
Loaded symbols for /usr/local/lib/libjpeg.so.11
Reading symbols from /usr/local/lib/libxcb.so.2...done.
Loaded symbols for /usr/local/lib/libxcb.so.2
Reading symbols from /usr/local/lib/libXau.so.6...done.
Loaded symbols for /usr/local/lib/libXau.so.6
Reading symbols from /usr/local/lib/libXdmcp.so.6...done.
Loaded symbols for /usr/local/lib/libXdmcp.so.6
Reading symbols from /usr/local/lib/libpthread-stubs.so.0...done.
Loaded symbols for /usr/local/lib/libpthread-stubs.so.0
Reading symbols from /usr/lib/librpcsvc.so.5...done.
Loaded symbols for /usr/lib/librpcsvc.so.5
Reading symbols from /usr/local/lib/php/20090626/gettext.so...done.
Loaded symbols for /usr/local/lib/php/20090626/gettext.so
Reading symbols from /usr/local/lib/libintl.so.9...done.
Loaded symbols for /usr/local/lib/libintl.so.9
Reading symbols from /usr/local/lib/php/20090626/gmp.so...done.
Loaded symbols for /usr/local/lib/php/20090626/gmp.so
Reading symbols from /usr/local/lib/libgmp.so.10...done.
Loaded symbols for /usr/local/lib/libgmp.so.10
Reading symbols from /usr/local/lib/php/20090626/hash.so...done.
Loaded symbols for /usr/local/lib/php/20090626/hash.so
Reading symbols from /usr/local/lib/php/20090626/iconv.so...done.
Loaded symbols for /usr/local/lib/php/20090626/iconv.so
Reading symbols from /usr/local/lib/php/20090626/imagick.so...done.
Loaded symbols for /usr/local/lib/php/20090626/imagick.so
Reading symbols from /usr/local/lib/libMagickWand.so.4...done.
Loaded symbols for /usr/local/lib/libMagickWand.so.4
Reading symbols from /usr/local/lib/libMagickCore.so.4...done.
Loaded symbols for /usr/local/lib/libMagickCore.so.4
Reading symbols from /usr/local/lib/libjbig.so.1...done.
Loaded symbols for /usr/local/lib/libjbig.so.1
Reading symbols from /usr/local/lib/liblcms.so.1...done.
Loaded symbols for /usr/local/lib/liblcms.so.1
Reading symbols from /usr/local/lib/libtiff.so.4...done.
Loaded symbols for /usr/local/lib/libtiff.so.4
Reading symbols from /usr/local/lib/libjasper.so.4...done.
Loaded symbols for /usr/local/lib/libjasper.so.4
Reading symbols from /usr/local/lib/liblqr-1.so.3...done.
Loaded symbols for /usr/local/lib/liblqr-1.so.3
Reading symbols from /usr/local/lib/libglib-2.0.so.0...done.
Loaded symbols for /usr/local/lib/libglib-2.0.so.0
Reading symbols from /usr/local/lib/libfftw3.so.5...done.
Loaded symbols for /usr/local/lib/libfftw3.so.5
Reading symbols from /usr/local/lib/libfpx.so.2...done.
Loaded symbols for /usr/local/lib/libfpx.so.2
Reading symbols from /usr/local/lib/libfontconfig.so.1...done.
Loaded symbols for /usr/local/lib/libfontconfig.so.1
Reading symbols from /usr/local/lib/libXext.so.6...done.
Loaded symbols for /usr/local/lib/libXext.so.6
Reading symbols from /usr/local/lib/libXt.so.6...done.
Loaded symbols for /usr/local/lib/libXt.so.6
Reading symbols from /usr/local/lib/libSM.so.6...done.
Loaded symbols for /usr/local/lib/libSM.so.6
Reading symbols from /usr/local/lib/libICE.so.6...done.
Loaded symbols for /usr/local/lib/libICE.so.6
Reading symbols from /usr/local/lib/libltdl.so.7...done.
Loaded symbols for /usr/local/lib/libltdl.so.7
Reading symbols from /usr/lib/libstdc++.so.6...done.
Loaded symbols for /usr/lib/libstdc++.so.6
Reading symbols from /lib/libgcc_s.so.1...done.
Loaded symbols for /lib/libgcc_s.so.1
Reading symbols from /usr/local/lib/php/20090626/json.so...done.
Loaded symbols for /usr/local/lib/php/20090626/json.so
Reading symbols from /usr/local/lib/php/20090626/ldap.so...done.
Loaded symbols for /usr/local/lib/php/20090626/ldap.so
Reading symbols from /usr/local/lib/libldap-2.4.so.7...done.
Loaded symbols for /usr/local/lib/libldap-2.4.so.7
Reading symbols from /usr/local/lib/liblber-2.4.so.7...done.
Loaded symbols for /usr/local/lib/liblber-2.4.so.7
Reading symbols from /usr/local/lib/php/20090626/mbstring.so...done.
Loaded symbols for /usr/local/lib/php/20090626/mbstring.so
Reading symbols from /usr/local/lib/libonig.so.1...done.
Loaded symbols for /usr/local/lib/libonig.so.1
Reading symbols from /usr/local/lib/php/20090626/mcrypt.so...done.
Loaded symbols for /usr/local/lib/php/20090626/mcrypt.so
Reading symbols from /usr/local/lib/libmcrypt.so.8...done.
Loaded symbols for /usr/local/lib/libmcrypt.so.8
Reading symbols from /usr/local/lib/php/20090626/mysql.so...done.
Loaded symbols for /usr/local/lib/php/20090626/mysql.so
Reading symbols from /usr/local/lib/mysql/libmysqlclient.so.16...done.
Loaded symbols for /usr/local/lib/mysql/libmysqlclient.so.16
Reading symbols from /usr/local/lib/php/20090626/mysqli.so...done.
Loaded symbols for /usr/local/lib/php/20090626/mysqli.so
Reading symbols from /usr/local/lib/php/20090626/openssl.so...done.
Loaded symbols for /usr/local/lib/php/20090626/openssl.so
Reading symbols from /usr/local/lib/php/20090626/pdf.so...done.
Loaded symbols for /usr/local/lib/php/20090626/pdf.so
Reading symbols from /usr/local/lib/libpdf.so.8...done.
Loaded symbols for /usr/local/lib/libpdf.so.8
Reading symbols from /usr/local/lib/php/20090626/pdo.so...done.
Loaded symbols for /usr/local/lib/php/20090626/pdo.so
Reading symbols from /usr/local/lib/php/20090626/pdo_sqlite.so...done.
Loaded symbols for /usr/local/lib/php/20090626/pdo_sqlite.so
Reading symbols from /usr/local/lib/libsqlite3.so.8...done.
Loaded symbols for /usr/local/lib/libsqlite3.so.8
Reading symbols from /usr/local/lib/php/20090626/pdo_mysql.so...done.
Loaded symbols for /usr/local/lib/php/20090626/pdo_mysql.so
Reading symbols from /usr/local/lib/php/20090626/posix.so...done.
Loaded symbols for /usr/local/lib/php/20090626/posix.so
Reading symbols from /usr/local/lib/php/20090626/session.so...done.
Loaded symbols for /usr/local/lib/php/20090626/session.so
Reading symbols from /usr/local/lib/php/20090626/pspell.so...done.
Loaded symbols for /usr/local/lib/php/20090626/pspell.so
Reading symbols from /usr/local/lib/libaspell.so.16...done.
Loaded symbols for /usr/local/lib/libaspell.so.16
Reading symbols from /usr/local/lib/libpspell.so.16...done.
Loaded symbols for /usr/local/lib/libpspell.so.16
Reading symbols from /usr/local/lib/php/20090626/simplexml.so...done.
Loaded symbols for /usr/local/lib/php/20090626/simplexml.so
Reading symbols from /usr/local/lib/php/20090626/soap.so...done.
Loaded symbols for /usr/local/lib/php/20090626/soap.so
Reading symbols from /usr/local/lib/php/20090626/sockets.so...done.
Loaded symbols for /usr/local/lib/php/20090626/sockets.so
Reading symbols from /usr/local/lib/php/20090626/sqlite.so...done.
Loaded symbols for /usr/local/lib/php/20090626/sqlite.so
Reading symbols from /usr/local/lib/php/20090626/tidy.so...done.
Loaded symbols for /usr/local/lib/php/20090626/tidy.so
Reading symbols from /usr/local/lib/libtidy-0.99.so.0...done.
Loaded symbols for /usr/local/lib/libtidy-0.99.so.0
Reading symbols from /usr/local/lib/php/20090626/tokenizer.so...done.
Loaded symbols for /usr/local/lib/php/20090626/tokenizer.so
Reading symbols from /usr/local/lib/php/20090626/xml.so...done.
Loaded symbols for /usr/local/lib/php/20090626/xml.so
Reading symbols from /usr/local/lib/php/20090626/wddx.so...done.
Loaded symbols for /usr/local/lib/php/20090626/wddx.so
Reading symbols from /usr/local/lib/php/20090626/xmlreader.so...done.
Loaded symbols for /usr/local/lib/php/20090626/xmlreader.so
Reading symbols from /usr/local/lib/php/20090626/xmlrpc.so...done.
Loaded symbols for /usr/local/lib/php/20090626/xmlrpc.so
Reading symbols from /usr/local/lib/php/20090626/xmlwriter.so...done.
Loaded symbols for /usr/local/lib/php/20090626/xmlwriter.so
Reading symbols from /usr/local/lib/php/20090626/xsl.so...done.
Loaded symbols for /usr/local/lib/php/20090626/xsl.so
Reading symbols from /usr/local/lib/libexslt.so.8...done.
Loaded symbols for /usr/local/lib/libexslt.so.8
Reading symbols from /usr/local/lib/libxslt.so.2...done.
Loaded symbols for /usr/local/lib/libxslt.so.2
Reading symbols from /usr/local/lib/libgcrypt.so.17...done.
Loaded symbols for /usr/local/lib/libgcrypt.so.17
Reading symbols from /usr/local/lib/libgpg-error.so.0...done.
Loaded symbols for /usr/local/lib/libgpg-error.so.0
Reading symbols from /usr/local/lib/php/20090626/zip.so...done.
Loaded symbols for /usr/local/lib/php/20090626/zip.so
Reading symbols from /usr/local/lib/php/20090626/zlib.so...done.
Loaded symbols for /usr/local/lib/php/20090626/zlib.so
Reading symbols from /libexec/ld-elf.so.1...done.
Loaded symbols for /libexec/ld-elf.so.1
#0  apr_palloc (pool=0x80fd13028, in_size=Variable "in_size" is not available.
) at memory/unix/apr_pools.c:252
252                if ((*ref = node->next) == NULL && i >= max_index) {
[New Thread 8016041c0 (LWP 100225)]
(gdb) bt
#0  apr_palloc (pool=0x80fd13028, in_size=Variable "in_size" is not available.
) at memory/unix/apr_pools.c:252
#1  0x00000008010549f9 in apr_pstrmemdup (a=Variable "a" is not available.
) at strings/apr_strings.c:107
#2  0x000000000042c30b in ap_read_request (conn=0x80fd07298) at
/usr/ports/www/apache22/work/httpd-2.2.16/server/protocol.c:649
#3  0x0000000000444b43 in ap_process_http_connection (c=0x80fd07298) at
/usr/ports/www/apache22/work/httpd-2.2.16/modules/http/http_core.c:183
#4  0x0000000000440b02 in ap_run_process_connection (c=0x80fd07298) at
/usr/ports/www/apache22/work/httpd-2.2.16/server/connection.c:43
#5  0x0000000000450324 in process_socket (p=0x80fd07028, sock=0x80fd070a0,
conn_id=1108, bucket_alloc=0x80fd0b028, pool=0x80fd05028) at
/usr/ports/www/apache22/work/httpd-2.2.16/server/mpm/experimental/peruser/peruser.c:1363
#6  0x000000000045191f in child_main (child_num_arg=Variable "child_num_arg" is
not available.
) at
/usr/ports/www/apache22/work/httpd-2.2.16/server/mpm/experimental/peruser/peruser.c:2216
#7  0x00000000004520e5 in make_child (s=0x80161a868, slot=1108) at
/usr/ports/www/apache22/work/httpd-2.2.16/server/mpm/experimental/peruser/peruser.c:2534
#8  0x0000000000452cca in ap_mpm_run (_pconf=Variable "_pconf" is not
available.
) at
/usr/ports/www/apache22/work/httpd-2.2.16/server/mpm/experimental/peruser/peruser.c:2941
#9  0x0000000000423b1a in main (argc=3, argv=0x7fffffffecf8) at
/usr/ports/www/apache22/work/httpd-2.2.16/server/main.c:740
(gdb) bt full
#0  apr_palloc (pool=0x80fd13028, in_size=Variable "in_size" is not available.
) at memory/unix/apr_pools.c:252
    active = (apr_memnode_t *) 0x80fd13000
    node = (apr_memnode_t *) 0x8000019d1
    mem = Variable "mem" is not available.
(gdb) frame 0
#0  apr_palloc (pool=0x80fd13028, in_size=Variable "in_size" is not available.
) at memory/unix/apr_pools.c:252
252                if ((*ref = node->next) == NULL && i >= max_index) {
(gdb) list
247                /* If we have found a node and it doesn't have any
248                 * nodes waiting in line behind it _and_ we are on
249                 * the highest available index, find the new highest
250                 * available index
251                 */
252                if ((*ref = node->next) == NULL && i >= max_index) {
253                    do {
254                        ref--;
255                        max_index--;
256                    }
(gdb) print node
$1 = (apr_memnode_t *) 0x8000019d1
(gdb) print node->next
Cannot access memory at address 0x8000019d1
(gdb) frame 1
#1  0x00000008010549f9 in apr_pstrmemdup (a=Variable "a" is not available.
) at strings/apr_strings.c:107
107        res = apr_palloc(a, n + 1);
(gdb) list
102        char *res;
103    
104        if (s == NULL) {
105            return NULL;
106        }
107        res = apr_palloc(a, n + 1);
108        memcpy(res, s, n);
109        res[n] = '\0';
110        return res;
111    }
(gdb) frame 2
#2  0x000000000042c30b in ap_read_request (conn=0x80fd07298) at
/usr/ports/www/apache22/work/httpd-2.2.16/server/protocol.c:649
649        r->protocol = apr_pstrmemdup(r->pool, pro, len);
(gdb) list
644        } else {
645            r->assbackwards = 1;
646            pro = "HTTP/0.9";
647            len = 8;
648        }
649        r->protocol = apr_pstrmemdup(r->pool, pro, len);
650    
651        /* XXX ap_update_connection_status(conn->id, "Protocol",
r->protocol); */
652    
653        /* Avoid sscanf in the common case */
(gdb) print r
$2 = (request_rec *) 0x80fd130a0
(gdb) print r->pool
$3 = (apr_pool_t *) 0x80fd13028
(gdb) print r->pool->tag
$4 = 0x455d0b "request"
(gdb) print r->connection
$5 = (conn_rec *) 0x80fd07298
(gdb) print r->connection->pool
$6 = (apr_pool_t *) 0x80fd07028
(gdb) print r->connection->aborted
$7 = 0
(gdb) print r->protocol
$8 = 0x0
(gdb) frame 3
#3  0x0000000000444b43 in ap_process_http_connection (c=0x80fd07298) at
/usr/ports/www/apache22/work/httpd-2.2.16/modules/http/http_core.c:183
183        while ((r = ap_read_request(c)) != NULL) {
(gdb) list
178         * Read and process each request found on our connection
179         * until no requests are left or we decide to close.
180         */
181    
182        ap_update_child_status(c->sbh, SERVER_BUSY_READ, NULL);
183        while ((r = ap_read_request(c)) != NULL) {
184    
185            c->keepalive = AP_CONN_UNKNOWN;
186            /* process the request if it was read without error */
187    
(gdb) print c
$9 = (conn_rec *) 0x80fd07298
(gdb) print c->id
$10 = 1108
(gdb) quit

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@apr.apache.org
For additional commands, e-mail: bugs-help@apr.apache.org


DO NOT REPLY [Bug 50594] apr_palloc Segmentation Fault

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=50594

William A. Rowe Jr. <wr...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEEDINFO                    |RESOLVED
         Resolution|                            |INVALID

--- Comment #5 from William A. Rowe Jr. <wr...@apache.org> 2011-01-17 07:13:52 EST ---
This would be a flaw in peruser's management of the pool scopes.  The fact
that it crashes in apr_palloc() indicates that the pool has become corrupt
or is no longer valid, which is consistent with peruser's handling of it's
connection pool (the mpm controls pool lifetimes).  This could be due to
cross-threading (not managing the allocator of memory across different
threads, or failing to set up a lock for the allocator to handle concurrent
allocator accesses).

In any case, you will need to take this core to the maintainers of the
peruser mpm for further assistance, there is little we can do for you here.
If there is a resolution, it would be helpful to update this bug just in case
someone stumbles across it searching for the same issue.

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@apr.apache.org
For additional commands, e-mail: bugs-help@apr.apache.org


DO NOT REPLY [Bug 50594] apr_palloc Segmentation Fault

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=50594

--- Comment #4 from Marcelo Coelho <ma...@tpn.com.br> 2011-01-17 07:02:01 EST ---
> How often does it crash?

~200 crashes per day, in a server with more than 1,000 vhosts.

> Can you get it to crash without the third-party
modules (php/peruser)?

I can't disable php to test because it's a production server. But, as you can
see in core dump, the server crashes BEFORE request is processed.

> Does freebsd have any heap checking / debugging you can
enable?

This is happening in a production server, I'm afraid to enable debug and slow
down the server.

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@apr.apache.org
For additional commands, e-mail: bugs-help@apr.apache.org


DO NOT REPLY [Bug 50594] apr_palloc Segmentation Fault

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=50594

--- Comment #2 from Eric Covener <co...@gmail.com> 2011-01-16 10:07:23 EST ---
(In reply to comment #1)
> Bug #50596 "make test hangs on testprocmute" may be related.  I read this bug
> and saw similarities to the problem I've been encountering.  

I don't think there's any relation, your backtrace is during single-threaded
server startup and 50594 is during setup of a new connection.  They just both
happen to fail in APR memory allocation.

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@apr.apache.org
For additional commands, e-mail: bugs-help@apr.apache.org


DO NOT REPLY [Bug 50594] apr_palloc Segmentation Fault

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=50594

Eric Covener <co...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |NEEDINFO

--- Comment #3 from Eric Covener <co...@gmail.com> 2011-01-16 10:13:02 EST ---
How often does it crash?  Can you get it to crash without the third-party
modules (php/peruser)?  Does freebsd have any heap checking / debugging you can
enable?

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@apr.apache.org
For additional commands, e-mail: bugs-help@apr.apache.org


DO NOT REPLY [Bug 50594] apr_palloc Segmentation Fault

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=50594

--- Comment #1 from John Poole <jl...@gmail.com> 2011-01-16 09:44:39 EST ---
Bug #50596 "make test hangs on testprocmute" may be related.  I read this bug
and saw similarities to the problem I've been encountering.  I've been hampered
with Apache failing at the outset with a segment fault.  My back trace pointed
to the same function and hence I believe there may be a similarity between the
bugs:

plug bin # gdb httpd
GNU gdb (Gentoo 7.0.1 p1) 7.0.1
Copyright (C) 2009 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "armv5tel-softfloat-linux-gnueabi".
For bug reporting instructions, please see:
<http://bugs.gentoo.org/>...
Reading symbols from /var/tmp/apache/httpd/bin/httpd...done.
(gdb) run
Starting program: /var/tmp/apache/httpd/bin/httpd
[Thread debugging using libthread_db enabled]

Program received signal SIGSEGV, Segmentation fault.
0x402600e4 in apr_palloc () from /usr/lib/libapr-1.so.0
(gdb) bt
#0  0x402600e4 in apr_palloc () from /usr/lib/libapr-1.so.0
#1  0x4025a988 in apr_array_make () from /usr/lib/libapr-1.so.0
#2  0x400ddb54 in apr_hook_sort_register () from /usr/lib/libaprutil-1.so.0
#3  0x00051f74 in ap_hook_create_connection (pf=0x3f49c <core_create_conn>,
aszPre=0x0, aszSucc=0x0,
    nOrder=30) at connection.c:42
#4  0x0003f838 in register_hooks (p=0xc50a8) at core.c:3985
#5  0x000485e4 in ap_register_hooks (m=0xbaeec, p=0xc50a8) at config.c:431
#6  0x00048974 in ap_add_module (m=0xbaeec, p=0xc50a8) at config.c:556
#7  0x00048d64 in ap_setup_prelinked_modules (process=0xc3130) at config.c:701
#8  0x00028be0 in main (argc=1, argv=0xbecac314) at main.c:487
(gdb) info frame
Stack level 0, frame at 0xbecac098:
 pc = 0x402600e4 in apr_palloc; saved pc 0x4025a988
 called by frame at 0xbecac0b8
 Arglist at 0xbecac080, args:
 Locals at 0xbecac080, Previous frame's sp is 0xbecac098
 Saved registers:
  r4 at 0xbecac080, r5 at 0xbecac084, r6 at 0xbecac088, r7 at 0xbecac08c, r8 at
0xbecac090,
  lr at 0xbecac094
(gdb) info locals
No symbol table info available.
(gdb)

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@apr.apache.org
For additional commands, e-mail: bugs-help@apr.apache.org