apr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joe Orton <jor...@redhat.com>
Subject Re: shared memory and unclean shutdown
Date Wed, 11 Aug 2004 14:17:42 GMT
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

Mime
View raw message