[mod_python] python web site not responding

Graham Dumpleton grahamd at dscpl.com.au
Wed Sep 6 18:10:30 EDT 2006


On 06/09/2006, at 12:46 PM, Trevis Rothwell wrote:

> On 9/5/06, Graham Dumpleton <grahamd at dscpl.com.au> wrote:
>
>> What version of mod_python/Apache are you using? If you use  
>> anything before
>> 3.2.8 you may have problems, especially if using Win32 or worker  
>> MPM on a
>> UNIXish system.  The latest version is actually 3.2.10, so use  
>> that if you can.
>
> I just upgraded to 3.2.10 tonight, but it doesn't seem to fix  
> anything.
>
>
>> Do you use sessions in your mod_python handlers or PSP pages?
>
> I am using sessions for my new project, which I did not for my
> personal website (which works).  I am not using PSP for this.

Sessions are often a source of hangs. When using sessions, you should  
only
create one instance of the Session object for any specific request.  
If you try
and create a second, the handler will deadlock on itself. How are you  
using
sessions in your code? Are you do non trivial stuff line using the  
function
req.internal_redirect()? Using this function can also cause session  
hangs if
the target of the sub request also uses sessions and the session in main
handler hasn't be unlocked.

>> Do you have the PythonAutoReload option set to Off?
>
> I don't have it set to anything in particular.
>
>
>> Do you have multiple distinct mod_python applications running
>> under the same Apache server?
>
> Yes, as "virtual servers" at Apache.
>
>
>> Have you isolated each application to run in a separate  
>> interpreter space using
>> PythonInterpreter?
>
> No.
>
>
>> Do you see any error messages in your Apache error logs?
>
> Nothing particularly interesting to me.  This kind of line is common:
>
> [Tue Sep 05 21:18:59 2006] [notice] mod_python: Creating 8 session
> mutexes based on 256 max processes and 0 max threads.
>
>
>> The above information and anything else you can think of that might
>> be pertinent would help.
>
> Thanks, you've already given me some things to explore that I hadn't
> before.  I naively assumed that since my previous Python-powered site
> worked without problems, I could just add a virtual server and make
> another one...  there might be more to it!  :-)
>
> -- Trevis Rothwell



More information about the Mod_python mailing list