On 13/10/2013, at 1:02 AM, Sebastian Clemens <clemensba...@gmx.de> wrote:

> Hmm, I use the google groups web interface, I'll try to make it better :)
> 
> Now I use this:
> 
> ServerAlias metrickz.sebastian-clemens.de
> Alias /robots.txt /var/www/vhosts/metrickz.de/httpdocs/robots.txt
> Alias /favicon.ico /var/www/vhosts/metrickz.de/httpdocs/favicon.ico
> Alias /static/ /var/www/vhosts/metrickz.de/httpdocs/static/
> Alias /media/ /var/www/vhosts/metrickz.de/httpdocs/static/media/
> WSGIDaemonProcess metrickz.de processes=1 threads=5 display-name=%{GROUP}

You don't need 'processes=1'. That is the default. Using the 'processes' 
option, even with the value 1, has a side effect of setting wsgi.multiprocess 
in WSGI environ to be True, which can prevent some debugging tools which will 
not work in a multiprocess environment, from working.

> WSGIProcessGroup metrickz.de
> WSGIApplicationGroup metrickz.de

Use:

WSGIApplicationGroup %{GLOBAL}

If you have the one site being delegated to the daemon process group.

If all sites are in separate daemon process groups and none should be running 
in embedded mode, also set:

WSGIRestrictEmbedded On

That way if you screw up the configuration then you will get an error rather 
than Apache memory use then blowing out because things are running in embedded 
mode with a larger number of processes.

> WSGIImportScript /var/www/vhosts/metrickz.de/httpdocs/wsgi.py 
> process-group=metrickz.de application-group=metrickz.de
> WSGIScriptAlias / /var/www/vhosts/metrickz.de/httpdocs/wsgi.py
> 
> It will have ~1500 visitors and ~8000 page views, in the rush hour there 200 
> visitors per hour and ~ 1000 page views per hour.
> This makes 16,6 page views per minute. The webseite renders the website very 
> fast so I think (or hope) five threads are enough.
> 
> I'm very afraid because last time I killed my server with to many processes, 
> but now it should work. I'm very happy if you can confirm my thoughts.

Whenever you have a problem come up, if you never have any monitoring it is 
always harder to look back and guess why something occurred. It may be prudent 
therefore to consider using some sort of monitoring so you have historical 
information to debug what did actually happen.

Graham

> Am Freitag, 11. Oktober 2013 11:33:55 UTC+2 schrieb Graham Dumpleton:
> Why is it that when you reply it is never to the replies sent back to you? 
> Instead it comes back as a disconnected message stream against your own 
> original questions. This makes it impossible to follow the conversation as 
> the context has been lost. If this is simply how your mail reader works, then 
> get a new main reader.
> 
> Running with a single thread is dangerous as a single issue with a long 
> running request will cause requests to start back logging as I explained in 
> my PyCon videos (which I presume I referred you to, but can't tell since 
> message history not included). Increasing the number of threads will not 
> notably increase memory. What killed your memory usage before was adding 
> processes.
> 
> So my guess on the very little information provided is that no it will not 
> survive.  Without real monitoring of your application it is going to be 
> anyones guess though.
> 
> Graham
> 
> On 11/10/2013, at 8:26 PM, Sebastian Clemens <clemen...@gmx.de> wrote:
> 
>> Ok, my server deploys more than one django based websites and one of them 
>> have 2500 visiters (200 per hour, 3,3 per second) ... will this site survive 
>> with one process and one thread? :D
>> I'm very carefully since my RAM crahsed cause of full ram by to many 
>> processes and threads. I have 2GB and 52% are already in use.
>> 
>> Am Dienstag, 24. September 2013 13:16:20 UTC+2 schrieb Sebastian Clemens:
>> Hello,
>> 
>> I'm using mod wsgi for some simple websites with only one process and one 
>> thread. But now I'm going to host a big page with 1000 users/day.
>> Last time I hosted it i tried with 5 processes and 10 threads and the server 
>> crashed cause of full RAM.
>> 
>> Can anyone give an approach how many users one process and one thread can 
>> handle? And how can I calculate the amound of processes and threads?
>> 
>> 
>> Thanks very much,
>> Sebastian
>> 
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "modwsgi" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to modwsgi+u...@googlegroups.com.
>> To post to this group, send email to mod...@googlegroups.com.
>> Visit this group at http://groups.google.com/group/modwsgi.
>> For more options, visit https://groups.google.com/groups/opt_out.
> 
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "modwsgi" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to modwsgi+unsubscr...@googlegroups.com.
> To post to this group, send email to modwsgi@googlegroups.com.
> Visit this group at http://groups.google.com/group/modwsgi.
> For more options, visit https://groups.google.com/groups/opt_out.

-- 
You received this message because you are subscribed to the Google Groups 
"modwsgi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to modwsgi+unsubscr...@googlegroups.com.
To post to this group, send email to modwsgi@googlegroups.com.
Visit this group at http://groups.google.com/group/modwsgi.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to