You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@apr.apache.org by Joe Orton <jo...@redhat.com> on 2004/08/11 16:17:42 UTC
Re: shared memory and unclean shutdown
On Fri, Jul 30, 2004 at 02:52:18AM +0200, Graham Leggett wrote:
> Justin Erenkrantz wrote:
>
> >We probably need some more info. What shmem method is it using? What
> >'file' is it using for shmem (if it's using non-anonymous shmem)? If
> >you are on Linux, is it out of shmem segments and do they need to be
> >cleaned up?
>
> The problem that prompted my question is reported in
> http://issues.apache.org/bugzilla/show_bug.cgi?id=29567
The best solution is to use an anonymous shm segment where possible, and
fall back on a named segment if apr_shm_create returns ENOTIMPL. APR
HEAD has apr_shm_remove() which will try to remove an existing named shm
segment.
>
> My problems with shared memory and mod_ssl (same problem as with
> mod_ldap - httpd refuses to start until the shared memory file is
> deleted first by hand) happens on RHEL3 with the following config set:
>
> SSLSessionCache shm:/var/cache/ssl_gcache_data(524288)
>
> If httpd dies uncleanly for any reason, I need to delete the file
> /var/cache/ssl_gcache_data by hand before httpd will start. A bit of a
> pain after a power failure.
mostly fixed by:
http://cvs.apache.org/viewcvs.cgi/httpd-2.0/modules/ssl/ssl_scache_shmcb.c?r1=1.23&r2=1.24
but you also need to configure "SSLMutex default" to prevent the same
mess with the mutex.
joe