shibboleth-dev - Re: shibd 1.3 linux memory usage
Subject: Shibboleth Developers
List archive
- From: André Cruz <>
- To:
- Subject: Re: shibd 1.3 linux memory usage
- Date: Thu, 3 Jan 2008 18:13:18 +0000
On 2008/01/03, at 17:50, Scott Cantor wrote:
The plot thickens... The RPC code on the GNU libc has that exact code
also. Calling svc_unregister and/or svc_destroy before the run() ends
has no effect.
I'm surprised at that, I would have expected a crash. I'm fairly certain I
tried that a long time ago and that's what I got. That's why I traced all
that code to begin with. If it doesn't crash, something is really wrong,
because that should be a double-free. If it's not, then it isn't freeing the
memory inside svc.c like it appears to be.
The memory checker complains, but the program lives on:
==2431== Invalid free() / delete / delete[]
==2431== at 0x4A1B96E: free (vg_replace_malloc.c:323)
==2431== by 0x62AAE35: svctcp_destroy (in /lib/libc-2.3.6.so)
==2431== by 0x4057C0: SharChild::svc_clean(SVCXPRT*) (shar- utils.cpp:179)
==2431== by 0x405E8D: SharChild::run() (shar-utils.cpp:162)
==2431== by 0x406220: shar_client_thread(void*) (shar-utils.cpp:89)
==2431== by 0x60ACF19: start_thread (in /lib/libpthread-2.3.6.so)
==2431== by 0x62855D1: clone (in /lib/libc-2.3.6.so)
==2431== Address 0x9038700 is 0 bytes inside a block of size 464 free'd
==2431== at 0x4A1B96E: free (vg_replace_malloc.c:323)
==2431== by 0x62AAE35: svctcp_destroy (in /lib/libc-2.3.6.so)
==2431== by 0x62AA1C5: svc_getreq_common (in /lib/libc-2.3.6.so)
==2431== by 0x62A9AA9: svc_getreqset (in /lib/libc-2.3.6.so)
==2431== by 0x405E75: SharChild::run() (shar-utils.cpp:157)
==2431== by 0x406220: shar_client_thread(void*) (shar-utils.cpp:89)
==2431== by 0x60ACF19: start_thread (in /lib/libpthread-2.3.6.so)
==2431== by 0x62855D1: clone (in /lib/libc-2.3.6.so)
But Unix servers that are also threaded. I don't really understand the need
to use prefork in 2008. If you have a PHP extension that's still not
thread-safe, it's time to cut bait. Or use somebody else's SAML
implementation for that matter, maybe that simplePHP code.
The application in question here is a mod_perl webapp on apache 1.3. Perl applications tend not to return the memory they use so apache processes have to be recycled every 1000 requests or so since mod_perl is builtin.
That's the price you pay for using The Best Language In The World. Kidding. :)
André
- Re: shibd 1.3 linux memory usage, (continued)
- Re: shibd 1.3 linux memory usage, André Cruz, 01/02/2008
- RE: shibd 1.3 linux memory usage, Scott Cantor, 01/02/2008
- Re: shibd 1.3 linux memory usage, André Cruz, 01/02/2008
- RE: shibd 1.3 linux memory usage, Scott Cantor, 01/02/2008
- Re: shibd 1.3 linux memory usage, André Cruz, 01/02/2008
- RE: shibd 1.3 linux memory usage, Scott Cantor, 01/02/2008
- Message not available
- RE: shibd 1.3 linux memory usage, Scott Cantor, 01/02/2008
- Re: shibd 1.3 linux memory usage, André Cruz, 01/03/2008
- Re: shibd 1.3 linux memory usage, Ian Young, 01/03/2008
- RE: shibd 1.3 linux memory usage, Scott Cantor, 01/03/2008
- Re: shibd 1.3 linux memory usage, André Cruz, 01/03/2008
- RE: shibd 1.3 linux memory usage, Scott Cantor, 01/03/2008
- Re: shibd 1.3 linux memory usage, André Cruz, 01/03/2008
- RE: shibd 1.3 linux memory usage, Scott Cantor, 01/03/2008
- Re: shibd 1.3 linux memory usage, André Cruz, 01/04/2008
- RE: shibd 1.3 linux memory usage, Scott Cantor, 01/04/2008
- Re: shibd 1.3 linux memory usage, André Cruz, 01/02/2008
- RE: shibd 1.3 linux memory usage, Scott Cantor, 01/02/2008
- Re: shibd 1.3 linux memory usage, André Cruz, 01/02/2008
- RE: shibd 1.3 linux memory usage, Scott Cantor, 01/02/2008
- Re: shibd 1.3 linux memory usage, André Cruz, 01/02/2008
Archive powered by MHonArc 2.6.16.