[mod_python] Re: Apache/mod_python SSLMutex

David Fraser davidf at sjsoft.com
Thu Oct 28 01:33:00 EDT 2004


LeePatton at woh.rr.com wrote:

>Thanks a lot! I appreciate your time. I am not exactly sure what is happening either. If you're interested, here is when I'm seeing the problem:
>  
>
Sure. I think it would be better if you mailed the list as well rather 
than just me and Grisha :-)

>For a while I was attempting to write an accesshandler that was redirecting (util.redirect) to other scripts in the directory it was handling access for. The scripts that were getting the *new* request (it took me a while to realize they were new requests) would always hange when trying to get the session information. (i image because the *old* request wasn't unlocked?). Anyway, I would have to restart a number of times, sometimes getting the same error message your received about not being able to bind to 443. Finally, Apache wouldn't restart giving me the SSLMutex error.
>  
>
I don't know that much about session locking, maybe somebody on the list 
can help... but I do know that the ipcs aren't being freed. I'll feed 
back to the list if I make any progress on that...

Cheers
David

>Thanks again,
>  - Lee
>
>
>----- Original Message -----
>From: David Fraser <davidf at sjsoft.com>
>Date: Wednesday, October 27, 2004 10:15 am
>Subject: Re: Apache/mod_python SSLMutex
>
>  
>
>>LeePatton at woh.rr.com wrote:
>>
>>    
>>
>>>I found your post on the mod_python mailing list about  trouble w/ 
>>>      
>>>
>>apache not releasing the mutexes on restart:
>>    
>>
>>>http://www.modpython.org/pipermail/mod_python/2004-May/015619.html
>>>
>>>I am having that exact same problem. You mentioned adding some 
>>>      
>>>
>>code to your init script to get around it. I would greatly 
>>appreiciate it if you would post it or send it to me.
>>    
>>
>>>Thanks for your time,
>>> - Lee
>>> 
>>>
>>>      
>>>
>>Hi Lee
>>
>>Sorry, my code actually went to python-dev at httpd.apache.org for 
>>which I 
>>think there aren't easy public archives...
>>Anyway here is my patch:
>>
>>--- httpd.rpmsave       2004-05-28 16:43:58.000000000 +0200
>>+++ httpd       2004-06-29 18:20:47.000000000 +0200
>>@@ -66,6 +66,15 @@
>>       echo -n $"Stopping $prog: "
>>       killproc $httpd
>>       RETVAL=$?
>>+       removeipcs=`ipcs -s -c | grep apache | cut -d ' ' -f 1`
>>+       numipcs=`echo $removeipcs | wc -w`
>>+       if [ $numipcs != 0 ]
>>+       then
>>+               echo
>>+               echo -n $"and removing $numipcs ipcs: "
>>+               echo $removeipcs | xargs -n 1 ipcrm -s
>>+               sleep 2
>>+       fi
>>       echo
>>       [ $RETVAL = 0 ] && rm -f ${lockfile} ${pidfile}
>>}
>>
>>Note: I've just done this on a machine which has Apache 2 and 
>>Apache 1.3 
>>running concurrently. In this situation it gets a bit more tricky 
>>because the ipcrm command inadvertently kills the Apache 1.3 
>>process 
>>which has some ipcs open. So I have to restart it manually.
>>
>>I still haven't managed to debug exactly why this happens...
>>
>>David
>>
>>
>>
>>    
>>
>
>  
>



More information about the Mod_python mailing list