Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 12 Jun 2008 04:27:01 -0400
From:      "Philip M. Gollucci" <pgollucci@p6m7g8.com>
To:        Daniel O'Connor <doconnor@gsoft.com.au>
Cc:        freebsd-apache@freebsd.org
Subject:   Re: Apache w/ PHP crashes after upgrading to 7.0
Message-ID:  <4850DDD5.7090209@p6m7g8.com>
In-Reply-To: <200806121348.18205.doconnor@gsoft.com.au>
References:  <200806121348.18205.doconnor@gsoft.com.au>

next in thread | previous in thread | raw e-mail | index | archive | help
Daniel O'Connor wrote:
> Hi,
> I recently upgraded from FreeBSD 6.3 to 7.0 and now I am finding that it 
> crashes on start unless I disable both pgsql.so and mhash.so.
> 
> The stack trace is..
> #0  0x28f04d40 in ?? ()
> #1  0x281c6f2e in _pthread_main_np () from /lib/libc.so.7
> #2  0x2819fa0c in puts () from /lib/libc.so.7
> #3  0x281a0177 in gethostbyname () from /lib/libc.so.7
> #4  0x08069a12 in ap_get_local_host ()
> #5  0x08068b9c in ap_fini_vhost_config ()
> #6  0x0805639c in ap_read_config ()
> #7  0x0805f133 in standalone_main ()
> #8  0x08060c1f in main ()
That stack trace is bogus looks like memory/stack got corrupted.... 
gethostbyname does not call puts()

8-current code:
src/lib/libc/net/gethostnameadr.c:	
struct hostent *
gethostbyname(const char *name)
{
     struct hostdata *hd;
     struct hostent *rval;
     int ret_h_errno;

     if ((hd = __hostdata_init()) == NULL)
         return (NULL);
     if (gethostbyname_r(name, &hd->host, hd->data, sizeof(hd->data), &rval,
         &ret_h_errno) != 0)
         return (NULL);
     return (rval);
}

Rather than
gdb binary binary.core

trying doing
$ gdb /usr/local/sbin/httpd

http://httpd.apache.org/dev/debugging.html#gdb

see the url for the rest....





-- 
------------------------------------------------------------------------
Philip M. Gollucci (philip@ridecharge.com)
o:703.549.2050x206
Senior System Admin - Riderway, Inc.
http://riderway.com / http://ridecharge.com
1024D/DB9B8C1C B90B FBC3 A3A1 C71A 8E70  3F8C 75B8 8FFB DB9B 8C1C

Work like you don't need the money,
love like you'll never get hurt,
and dance like nobody's watching.




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4850DDD5.7090209>