Hi,

> FastCGI works a little bit different than mod_python. FastCGI server is a
> separate process from web server. You can have multiple FastCGI servers and
> one web server that communicates to FastCGI servers. Use virtual hosts or
> whatever else settings in web server configuration to route traffic between
> various FastCGI servers for various sites.

Thanks for your reply. I do already run php under fcgi (as separated
server, as you point out). But the main difference is that this pool
of fcgi php processes (or thread, not sure)  are available to all the
sites I've configured to use php. I don't have to dedicate one
specific fcgi server for each different sites, they all talk to the
same backend.

with django config, it seems that it needs separate fcgi servers for
each site, and I was wondering if these separate servers aren't going
to use a lot of resources, or in general being harder to manage than a
single pool of fcgi processes shared between different sites.

However, I read on a blog from Graham
http://www.technobabble.dk/2008/aug/25/django-mod-wsgi-perfect-match/

That there is a lot of shared libs between the various fcgi processes/
servers, so it doesn't matter much to have unused processes/servers.

Is my understanding correct and does it apply both for wsgi and
fastcgi ?

> To keep number of idle FastCGI processes low for inactive sites use
> maxspare=NUMBER when setting up FastCGI server.

The issue being that, of course, I don't know in advance which site is
going to be inactive and that's likely to change from one day to the
other. Not to mention that changing the number of spare servers
manually isn't very high on the list of things I like to do on a daily
basis ;)

With php, I set a few dozen spare processes, and on average, sites
aren't busy at the same time, so it spreads out nicely between these
processes.

> Take a look at the output of "./manage.py help runfcgi" for additional
> information.

Thanks for the pointer.

> To avoid running out of server resources in case of slashdotting use caching
> and any other optimization tools :)

Memcache was on my list indeed, and I'll try various other options

X+

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" 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/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to