On 13 December 2011 08:09, Rodrigo Campos <[email protected]> wrote:
> Thanks a lot for your quick answer =)
>
> No, static files should be served by nginx. We are using it as a proxy. Apache
> should serve only de Python App. Why ? :)
If there is no static files being served and only dynamic Python
stuff, can continue to use embedded/prefork. You would though just
want to setup Apache MPM settings to control better number of child
worker processes and pre start them and leave them running rather than
allowing Apache to dynamically adjust number of processes. Do this and
can use less processes than worker MPM and daemon mode.
What are the Apache MPM settings for:
<IfModule mpm_prefork_module>
StartServers 1
MinSpareServers 1
MaxSpareServers 10
MaxClients 150
MaxRequestsPerChild 0
</IfModule>
currently?
Graham
> On Tue, Dec 13, 2011 at 07:46:12AM +1100, Graham Dumpleton wrote:
>> A quick question, hopefully before you are off for the night.
>>
>> Are you hosting static files in same Apache, I can't remember?
>>
>> Graham
>>
>> On 13 December 2011 05:30, Rodrigo Campos <[email protected]> wrote:
>> > Hi,
>> >
>> > We are actually using apache with MPM prefork + mod_wsgi embedded mode as
>> > some
>> > libraries we use are not thread-safe. Work is underway to upgrade to newer
>> > versions of the libraries which are thread safe. But till that is over, I
>> > was
>> > reading [1] and thought that maybe I can use the worker MPM with mod_wsgi
>> > in
>> > daemon mode, as explained in the article, and avoid having lot of apache
>> > processes.
>> >
>> > But I wasn't sure if I wanted to do that in advance, since other problems
>> > may
>> > arise. For example, something similar to the listener backlog starvation
>> > recently commented in the mailing list [2]. And we still need to know if
>> > our
>> > application is thread-safe, and it won't be easy (any recommendations on
>> > how to
>> > do this ?), so I will have some time till the application is thread-safe.
>> >
>> > Have someone changed from MPM prefork to worker + mod_wsgi in daemon mode
>> > to run
>> > applications that are not thread safe ? Is there something in particular I
>> > should take into account (besides setting to use only one thread :D) ?
>> >
>> >
>> >
>> >
>> >
>> > Thanks a lot,
>> > Rodrigo
>> >
>> > [1]: http://code.google.com/p/modwsgi/wiki/IntegrationWithDjango
>> > [2]:
>> > https://groups.google.com/group/modwsgi/browse_thread/thread/db45c6deb04bb05c
>> >
>> > --
>> > You received this message because you are subscribed to the Google Groups
>> > "modwsgi" group.
>> > To post to this group, send email to [email protected].
>> > To unsubscribe from this group, send email to
>> > [email protected].
>> > For more options, visit this group at
>> > http://groups.google.com/group/modwsgi?hl=en.
>> >
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "modwsgi" group.
>> To post to this group, send email to [email protected].
>> To unsubscribe from this group, send email to
>> [email protected].
>> For more options, visit this group at
>> http://groups.google.com/group/modwsgi?hl=en.
>>
>
> --
> You received this message because you are subscribed to the Google Groups
> "modwsgi" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to
> [email protected].
> For more options, visit this group at
> http://groups.google.com/group/modwsgi?hl=en.
>
--
You received this message because you are subscribed to the Google Groups
"modwsgi" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/modwsgi?hl=en.